opengl texture

i enabled gl_texture_2d in my opengl program.
i used a bitmap(256 * 256) picture,it works correctly, but the texture didn’t affect when the pictue’s size was changed (not
256 * 256).
where is probably the problem? thanks.

In opengl, you can use only textures with a size of a power of 2… If your new size is not a power of 2, it’s normal that you see nothing !

You can use the NV_texture_rectangle extension to handle non power of two textures.
If you want to work with power of two texture on the base of a rectangular image use the glScaleImage func