Resizing an image with antialias

Hello, Im new in this forum (also in JoGL). Im developing a graphical component which represents a World Map… It basically consists in a large image (JPEG, about 2000 * 1800 pixs) that can be scrolled and zoomed. Im using JoGL because it will have some animations on it.

Im now loading the image into a byte-array (3 bytes per pixel) and displaying it using glDrawPixels to draw the pixel in the frame buffer. Thats ok.
The problem is, when I try to zoom in or out. I use currently the glPixelZoom function, but it just resizes the image without any anti-aliasing…
The question is: how do I resize with anti-alias? Am I using the rigth way to make what I want?
Thanks!!!

Uh, anti-aliasing deals with the edges of geometry, and so won’t help the pixelation of the image you’ll be seeing.

You’re probably after some kind of texture filtering though, in which case chop your huge image into nice manageable chunks and draw it as textured quads. glGetInteger will tell you the max size of a texture, and if you need several quads then you’ll have to tinker with the clamping mode to hide the seams.

So, the solution is using textures… I never worked with them… will try to learn…

thanks!

Theres a texture loader class burried in past posts in this forum, it might be in the wiki as well somewhere. Might be a good idea to use to save yourself some time.

Oh thanks, that will save me some time, I will search for it!