It's frustrating. Hitting "bicubic filter" into Google returns tons of related conversation, even a link to these very forums, where, as usual, everyone agrees that bicubic is a great -- if not the best practical -- approach to magnification. But I can't find any straight information, just lots of talk.
I've found a link to an NVIDIA demo that does some mutated variant in a pixel shader.
I've found discussions about HP printers.
I've found millions of discussions about image manipulation software.
What I'm looking for is a method, or an algorithm if you will, that can scale a source image to quadruple its original size, and fits the description "bicubic magnification filter".
This is about textures, so the source images will always have power-of-two dimensions, and let's assume texture repeats (=>unconstrained coords), if that helps.
I'm not asking for code donations
It would be perfectly enough if someone could just describe the process for, say, a single component image. Something along these lines maybe:
Bilinear 2x2 upsampling - crummy conjecture by me, that would help me tremendously if it were for bicubic
Please
I've found a link to an NVIDIA demo that does some mutated variant in a pixel shader.
I've found discussions about HP printers.
I've found millions of discussions about image manipulation software.
What I'm looking for is a method, or an algorithm if you will, that can scale a source image to quadruple its original size, and fits the description "bicubic magnification filter".
This is about textures, so the source images will always have power-of-two dimensions, and let's assume texture repeats (=>unconstrained coords), if that helps.
I'm not asking for code donations
It would be perfectly enough if someone could just describe the process for, say, a single component image. Something along these lines maybe:
Bilinear 2x2 upsampling - crummy conjecture by me, that would help me tremendously if it were for bicubic
Code:
dest(0;0):= 0.75*(0.75*src(0;0)+0.25*src(0;1))+
0.25*(0.75*src(-1;0)+0.25*src(-1;1));
dest(1;0):= 0.75*(0.75*src(0;0)+0.25*(src(0;1))+
0.25*(0.75*src(1;0)+0.25*src(1;1));
dest(1;-1):= 0.75*(0.75*src(0;0)+0.25*(src(0;-1))+
0.25*(0.75*src(1;0)+0.25*src(1;-1));
dest(0;-1):= 0.75*(0.75*src(0;0)+0.25*(src(0;-1))+
0.25*(0.75*src(-1;0)+0.25*src(-1;-1);
Please