Does anybody have a code snippet to generate Cubemaps in Ogre?
I'm interested in it.
generate cubemaps in Ogre
- FrameFever
- Platinum Sponsor

- Posts: 414
- Joined: Fri Apr 27, 2007 10:05 am
- sinbad
- OGRE Retired Team Member

- Posts: 19269
- Joined: Sun Oct 06, 2002 11:19 pm
- Location: Guernsey, Channel Islands
- x 67
- Contact:
Just create a cube texture with the TU_RENDERTARGET option, then get each of the 6 buffers (tex->getBuffer(n)) and from there the RenderTarget (getRenderTarget()), and create viewports on them like any other surface. Render to them using 6 different cameras each facing in a different direction. You can even do it in realtime for reflections if you want.
