View Full Version : Problems with WGL_TYPE_RGBA_FLOAT_ARB
05-02-2005, 04:32 AM
I have problems initalizing a color buffer with ChoosePixelFormatARB and WGL_TYPE_RGBA_FLOAT_ARB value. The ChoosePixel mehtod succeeds, but when I check the state with
glGetBooleanv( GL_RGBA_FLOAT_MODE_ARB, &state );
it says GL_FALSE ( float mode not enabled ).
Can somebody post a link or a snippet for initalizing the context with wglChoosePixelARB?
Java Cool Dude
05-02-2005, 06:05 AM
</font><blockquote><font size="1" face="Verdana, Arial">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;">#define PBUFFER_USE_DOUBLE_BUFFER 0x00000001
#define PBUFFER_RENDER_TO_TEXTURE 0x00000002
#define PBUFFER_TEXTURE_CUBE_MAP 0x00000004
#define PBUFFER_FORMAT_FLOAT 0x00000008
#define PBUFFER_RGBA 0x00000010
#define PER_CHANNEL_COLOR_BITS_16 0x00000020
#define PER_CHANNEL_COLOR_BITS_24 0x00000040
#define PER_CHANNEL_COLOR_BITS_32 0x00000080
bool GLPBuffer::initialize(int newWidth, int newHeight,
int newDepthBits, int newStencilBits,
//Check for pbuffer support
Java Cool Dude
05-02-2005, 06:14 AM
This is truly bothering me: how come every now and then this board classifies me as an unregistred user even though it clearly spells out that I'm LOGGED when I type my messages?
Anyway, here's a link (http://www.realityflux.com/abba/C++/Sample/) to my GLPBuffer set of classes.
Now to create a float 2D RGBA pBuffer, you need to initialize it this way:
if(!pixelBuffer.initialize(TCMSize,TCMSize, 24, 0,
05-02-2005, 10:54 AM
hi, do i have to have a pbuffer to work with float buffers? Because in the spec of this extension, nothing is mentionend.
05-03-2005, 11:01 AM
how come every now and then this board classifies me as an unregistred user even though it clearly spells out that I'm LOGGED when I type my messages?jcd, try getting rid of the cpp logical or operators in your code block...
05-03-2005, 03:33 PM
olmeca - you can work with float-textures without using pbuffers. If you want a floating-point rendertarget, you need to use either frame-buffer-objects or pbuffers.
abzap - your pbuffer-class doesn't work for texture-rectangles, does it?
Is there a way to use pbuffer floatingpoint texture-rectangles that work on both ati/nv, or do I (still) need to check extensions? Specifically I'm looking to replace the current nvidia-specific:
iAttribs[niAttribs++] = WGL_TEXTURE_FORMAT_ARB;
iAttribs[niAttribs++] = (isFloat) ? WGL_TEXTURE_FLOAT_RGBA_NV : WGL_TEXTURE_RGBA_ARB;
iAttribs[niAttribs++] = WGL_TEXTURE_TARGET_ARB;
iAttribs[niAttribs++] = WGL_TEXTURE_RECTANGLE_NV;\\hornet
PS. yeah I know, fbo...
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.