|Feb 23, 2006, 08:17 AM||#1|
OpenGL non-power-of-2 textures - extension missing?
I have a Mobility Radeon chipset and OS X v10.4.5. "About This Mac"->"More Info..." reveals that Quartz Extreme is supported by my machine. The internet literature including the Mac Guide on this site states that my card must therefore support arbitrary size textures.
However, in my OpenGL code the GL_EXTENSIONS string* does not include GL_ARB_texture_non_power_of_two and I cannot successfully upload arbitrary sized textures.
So, my question is - why do I not seem to have arbitrary texture size support? Is this feature not supported by my hardware or is it obstructed by software for some reason? Are Apple weirdly using some extension other than the ARB standard?
* which is, in full:
GL_ARB_transpose_matrix GL_ARB_vertex_program GL_ARB_vertex_blend GL_ARB_window_pos GL_ARB_shader_objects GL_ARB_vertex_shader GL_EXT_multi_draw_arrays GL_EXT_clip_volume_hint GL_EXT_rescale_normal GL_EXT_draw_range_elements GL_EXT_fog_coord GL_APPLE_client_storage GL_APPLE_specular_vector GL_APPLE_transform_hint GL_APPLE_packed_pixels GL_APPLE_fence GL_APPLE_vertex_array_object GL_APPLE_vertex_program_evaluators GL_APPLE_element_array GL_APPLE_flush_render GL_NV_texgen_reflection GL_NV_light_max_exponent GL_IBM_rasterpos_clip GL_SGIS_generate_mipmap GL_ARB_shading_language_100 GL_ARB_texture_env_crossbar GL_ARB_texture_border_clamp GL_ARB_multitexture GL_ARB_texture_env_add GL_ARB_texture_cube_map GL_ARB_texture_env_dot3 GL_ARB_multisample GL_ARB_texture_env_combine GL_ARB_texture_compression GL_ARB_texture_mirrored_repeat GL_ARB_occlusion_query GL_EXT_compiled_vertex_array GL_EXT_texture_rectangle GL_ARB_texture_rectangle GL_EXT_texture_env_add GL_EXT_texture_lod_bias GL_EXT_abgr GL_EXT_bgra GL_EXT_texture_filter_anisotropic GL_EXT_separate_specular_color GL_EXT_secondary_color GL_EXT_texture_compression_s3tc GL_EXT_texture_compression_dxt1 GL_APPLE_ycbcr_422 GL_APPLE_texture_range GL_APPLE_pixel_buffer GL_NV_fog_distance GL_ATI_texture_mirror_once GL_ATI_texture_env_combine3 GL_SGIS_texture_edge_clamp GL_SGIS_texture_lod GL_SGI_color_matrix
|Feb 23, 2006, 08:52 AM||#2|
For non-power-of-two textures, I use the following code to determine my texture target.
So it'll automagically determine which extension to use. Notice the one you mentioned isn't even on the list Hope this helps! And don't forget....I dunno if you've used non-power-of-two textures before, but texture coordinates will go from 0-pixel size of the textures, rather than 0-1.
The other thing you could do is use the gluBuildMipmaps function (or something similar, I forget the exact name) which will automagically convert your texture to power-of-two. Good luck!
Ken "I <3 OpenGL programming" Kopecky
|Feb 23, 2006, 09:56 AM||#3|
Ahhh, I hadn't spotted the GL_ARB/EXT_texture_rectangle extension that seems to provide a more limited capacity for arbitrary texture sizes than GL_ARB_texture_non_power_of_two. Whereas the latter gives you a non-power-of-two texture that otherwise operates exactly like a power of two texture with mip mapping and the availability of GL_REPEAT as a wrap mode the former actually does everything I need as I'm really just using the graphics card for bitmap scaling and could do with saving the VRAM.
|Thread Tools||Search this Thread|
|thread||Thread Starter||Forum||Replies||Last Post|
|Missing GPU power from a second PCIe slot?||TzunamiOSX||Mac Pro||4||Apr 3, 2014 01:34 AM|
|Missing file extension||spb3||Mac Basics and Help||4||Apr 2, 2014 11:30 PM|
|Power Nap missing Retina Macbook Pro||Beck4164||OS X 10.8 Mountain Lion||1||Jul 25, 2012 02:35 PM|
|iOS 5 Background Textures||d0vr||iPhone/iPad Programming||7||Jul 13, 2012 02:29 AM|
All times are GMT -5. The time now is 12:26 PM.