User-agent: Mozilla Thunderbird 0.8 (Macintosh/20040913)
I have some more information that might solve my problem (with your help
if I am lucky):
I am using Glut.
I have created a pbuffer.
I can write to the pbuffer and from the pbuffer to the screen using the
fixed pipeline.
I can also write to the screen using a pixel shader (ARB)
However, I cannot write to the pbuffer using the shader. For example,
the following code, that
writes to the pbuffer, clears the pbuffer screen and fills it with red
(which eventually appears on the screen).
However, the shader, which changes the color from red to yellow, has no
effect. Yet, when I simply change
the current context from pbuffer to screen, the shader works as it
should and the background red color is
overwritten.
This suggests to me that somehow, the pbuffer context must be active
when certain aspects of the shader
are defined, although I have not seen this documented anywhere. Any
thoughts on the matter? Thanks.
--------
//----------------------------------------------------------------------
float4 initExp(float2 tc : TEXCOORD0) // [N,N] on nvidia
: COLOR
{
float x = 0.5; //float4 color = float4(1.,x,1.,1.0);
float4 color = float4(.7,1.,0.,1);
return color;
}
//----------------------------------------------------------------------
float4 rewireExp(float2 tc : TEXCOORD0,
uniform sampler2D acc_noise) : COLOR
{
float4 acc = tex2D(acc_noise, tc); // orig
float3 color = acc.xyz / 1.0;
//color = float3(0.,1.,.2) / 1.0;
return float4(color,1.);
}
//----------------------------------------------------------------------
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Mac-opengl mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/mac-opengl/email@hidden