Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

_walrus

strange value with WGL_ARB_pixel_format

This topic is 5458 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hi i threw togheter a simple ogl app using WGL_ARB_pixel_format. It just goes through all the pixel formats of the machine and dumps out their attributes. it looks something like this:

int iAttributes[] = { WGL_PIXEL_TYPE_ARB, WGL_COLOR_BITS_ARB, WGL_RED_BITS_ARB, WGL_GREEN_BITS_ARB, WGL_BLUE_BITS_ARB,...};


for (int i=1; i<formats+1;i++)
{
 fprintf(fp, "PF #%d  ", i);
 if ( wglGetPixelFormatAttribivARB(hDC, i, 0, size, iAttributes, iResults) )
 { 
  fprintf(fp, "WGL_PIXEL_TYPE_ARB = %d", iResults[0]);
  fprintf(fp, "\tWGL_COLOR_BITS_ARB = %d", iResults[1]);	
  fprintf(fp, "\tWGL_RED_BITS_ARB   = %d", iResults[2]);
  fprintf(fp, "\tWGL_GREEN_BITS_ARB = %d", iResults[3]);
  ...
  ... 
  ...
 }
}

     
the stuff this simple app logs generally look right...expect for one value: WGL_SUPPORT_GDI_ARB. Now this should result in a one or zero value. but i think the wglGetPixelFormatAttribivARB method isn't assigning anything to this. The following lines should illustrate my problem:
PF #1  WGL_PIXEL_TYPE_ARB = 8235	WGL_COLOR_BITS_ARB = 32		WGL_ALPHA_BITS_ARB = 8	WGL_DEPTH_BITS_ARB      = 24		WGL_NEED_PALETTE_ARB         = 8231	WGL_NEED_SYSTEM_PALETTE_ARB  = 0	WGL_SWAP_LAYER_BUFFERS_ARB   = 0		WGL_NUMBER_UNDERLAYS_ARB   = 0	WGL_TRANSPARENT_ARB        = 0	WGL_SUPPORT_GDI_ARB        = -858993460	WGL_SUPPORT_OPENGL_ARB     = 0	GL_ACCUM_BITS_ARB       = 1	GL_ACCUM_RED_BITS_ARB   = 0		GL_ACCUM_BLUE_BITS_ARB  = 0	 GL_ACCUM_ALPHA_BITS_ARB = 0
PF #2  WGL_PIXEL_TYPE_ARB = 8235	WGL_COLOR_BITS_ARB = 32		WGL_ALPHA_BITS_ARB = 0	WGL_DEPTH_BITS_ARB      = 24		WGL_NEED_PALETTE_ARB         = 8231	WGL_NEED_SYSTEM_PALETTE_ARB  = 0	WGL_SWAP_LAYER_BUFFERS_ARB   = 0		WGL_NUMBER_UNDERLAYS_ARB   = 0	WGL_TRANSPARENT_ARB        = 0	WGL_SUPPORT_GDI_ARB        = -858993460	WGL_SUPPORT_OPENGL_ARB     = 0	GL_ACCUM_BITS_ARB       = 1	GL_ACCUM_RED_BITS_ARB   = 0		GL_ACCUM_BLUE_BITS_ARB  = 0	 GL_ACCUM_ALPHA_BITS_ARB = 0
PF #3  WGL_PIXEL_TYPE_ARB = 8235	WGL_COLOR_BITS_ARB = 32		WGL_ALPHA_BITS_ARB = 8	WGL_DEPTH_BITS_ARB      = 24		WGL_NEED_PALETTE_ARB         = 8231	WGL_NEED_SYSTEM_PALETTE_ARB  = 0	WGL_SWAP_LAYER_BUFFERS_ARB   = 0		WGL_NUMBER_UNDERLAYS_ARB   = 0	WGL_TRANSPARENT_ARB        = 0	WGL_SUPPORT_GDI_ARB        = -858993460	WGL_SUPPORT_OPENGL_ARB     = 0	GL_ACCUM_BITS_ARB       = 1	GL_ACCUM_RED_BITS_ARB   = 64	GL_ACCUM_BLUE_BITS_ARB  = 16 GL_ACCUM_ALPHA_BITS_ARB = 16
PF #4  WGL_PIXEL_TYPE_ARB = 8235	WGL_COLOR_BITS_ARB = 32		WGL_ALPHA_BITS_ARB = 0	WGL_DEPTH_BITS_ARB      = 24		WGL_NEED_PALETTE_ARB         = 8231	WGL_NEED_SYSTEM_PALETTE_ARB  = 0	WGL_SWAP_LAYER_BUFFERS_ARB   = 0		WGL_NUMBER_UNDERLAYS_ARB   = 0	WGL_TRANSPARENT_ARB        = 0	WGL_SUPPORT_GDI_ARB        = -858993460	WGL_SUPPORT_OPENGL_ARB     = 0	GL_ACCUM_BITS_ARB       = 1	GL_ACCUM_RED_BITS_ARB   = 64	GL_ACCUM_BLUE_BITS_ARB  = 16 GL_ACCUM_ALPHA_BITS_ARB = 16

   
Do you think this could be a bug or something? I get the same thing when i look in the debugger(so i'm not printing out the wrong type). I'm running ATI 9600 with the latest Cat drivers and Win98. Thanks for ur responce. [edited by - _walrus on August 10, 2003 7:28:33 PM]

Share this post


Link to post
Share on other sites
Advertisement

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!