Jump to content

  • Log In with Google      Sign In   
  • Create Account


#Actualradioteeth

Posted 26 June 2013 - 03:01 PM

Well, according to the documentation, gl_Layer is actually for designating which face of a cubemap to use - which is different.

 

Somehow I confused gl_Layer with sampler2D/3D lod parameter, which allows a fragment shader to specify which texture mipmap to sample from.

 

Can I ask what it is you are trying to achieve through the use of gl_Layer ?

 

http://www.opengl.org/sdk/docs/manglsl/xhtml/gl_Layer.xml

 

You are using glFrameBufferTexture, when there is a glFrameBufferTexture3D. EDIT: apparently the 3D variant is deprecated in favor of the function you are using, but it is still unclear to me what you are trying to accomplish.


#1radioteeth

Posted 26 June 2013 - 02:58 PM

Well, according to the documentation, gl_Layer is actually for designating which face of a cubemap to use - which is different.

 

Somehow I confused gl_Layer with sampler2D/3D lod parameter, which allows a fragment shader to specify which texture mipmap to sample from.

 

Can I ask what it is you are trying to achieve through the use of gl_Layer ?

 

http://www.opengl.org/sdk/docs/manglsl/xhtml/gl_Layer.xml

 

You are using glFrameBufferTexture, when there is a glFrameBufferTexture3D.


PARTNERS