1

Is there a way to render a scene to normal resolution then the other part of the screen to a lower resolution in OpenGL ES 2.0 on Android?

If I use GLES20.glViewPort() and change the resolution, it won't scale to full screen size, but I'm getting the desired result, only smaller.

I would like a solution without having to render to a texture than render the quad on the screen.

4

1 回答 1

2

如果您想要实现的是将较低分辨率的场景渲染到更高分辨率的视口中(从而获得某种“像素化”效果),那么 OpenGL 就不能轻易做到这一点。在这里寻找类似的问题。

基本上,您不会绕过将整个事物渲染为低分辨率纹理(最好使用FBO完成)并在高分辨率视口中显示屏幕大小的四边形,使用最近过滤从低分辨率纹理中采样。OpenGL 不能只是放大你的像素,单个片段会产生一个(或没有)像素。

但也许这不是你所追求的,我误解了你的问题。

于 2012-08-21T15:01:48.830 回答