【发布时间】:2013-12-18 08:49:24
【问题描述】:
我有一个 libgdx 应用程序,我在其中创建了一个由立方体组成的迷宫。 当我渲染底部 blue 和顶部 red 面时,底部的一个渲染在顶面的前面。两张脸的法线向量相同。
我可以切换远近剪裁平面吗?
这是我设置相机的方法:
public PerspectiveCamera updateCamera() {
if (camera == null) {
float aspectRatio = Gdx.graphics.getWidth() / Gdx.graphics.getHeight();
camera = new PerspectiveCamera(67f, aspectRatio, 1);
this.setActive(true);
}
return camera;
}
【问题讨论】: