它代码渲染渲染我的游戏,他没有工作深度缓冲区(我制作视频)https://vk.com/videos183630146?z=video183630146_456239060%2Fpl_183630146_-2 我的代码渲染和加载模型=>
private void LoadingComplete() { // load model
UBJsonReader reader = new UBJsonReader();
ModelLoader loader = new G3dModelLoader(reader);
modelInstance = new ModelInstance(loader.loadModel(Gdx.files.internal("models/mapv2/mapCompl.g3db");
}
@Override
public void render(float delta) {
Gdx.gl20.glClearColor(0, 0, 1, 1);
Gdx.gl20.glClear(GL20.GL_COLOR_BUFFER_BIT | GL20.GL_DEPTH_BUFFER_BIT);
camController.update();
camera.update();
modelBatch.begin(camera);
modelBatch.render(modelInstance);
modelBatch.end();
}
答案 0 :(得分:0)
您可能遗漏了Gdx.gl.glEnable(GL20.GL_DEPTH_TEST);