@Override
public void begin(Camera camera, RenderContext context) {
program.begin();
viewProjTrans.set(camera.combined);
program.setUniformf(u_cameraPosition, camera.position.x, camera.position.y,
camera.position.z, 1);
program.setUniformf(u_worldLightDir, lightDirection.x, lightDirection.y, lightDirection.z, 0);
context.setDepthTest(GL20.GL_LEQUAL);
context.setCullFace(GL20.GL_BACK);
context.setBlending(shouldFadeEnds ? true : false, GL20.GL_SRC_ALPHA, GL20.GL_ONE_MINUS_SRC_ALPHA);
texture.bind(0);
program.setUniformi(u_texture, 0);
specLUT.getTexture().bind(1);
program.setUniformi(u_specularPowerLUTTexture, 1);
}
SubsurfaceScatteringShader.java 文件源码
java
阅读 26
收藏 0
点赞 0
评论 0
项目:DoubleHelix
作者:
评论列表
文章目录