Dynamic Cube Mapping


I’ve just got some based cube mapping working. I’d really like to render to the cube map texture dynamically and can’t work out how to do it. I’m not sure if ofFBO can be used for this - does anyone have any code examples for doing this?



If I understand you correctly you probably want a shader to generate the texture for the cube map textures? In that case you just create the cubemap texture and then have a fragment shader that includes something like the following:

uniform samplerCube tex;  
varying vec3 texCoords;  
void main()  
	gl_FragColor = textureCube(tex, texCoords);