Render face of cube map to a quad

假如想象 提交于 2019-12-11 01:54:07

问题


I have a cube map texture in OpenGL, and I'd like to render one face of the cube to a single quad. What texture coordinates should I use? To be concrete, what coordinates should I pick to render the "GL_TEXTURE_CUBE_MAP_POSITIVE_X" face? Or if I shouldn't explicitly define coordinates, how should I use texture coordinate generation in this instance?


回答1:


The texture coordinates you want are (1, +/-1, +/-1)



来源:https://stackoverflow.com/questions/8565093/render-face-of-cube-map-to-a-quad

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!