Showing the changes to interface/src/VoxelSystem.cpp (1 of 28 files). Show all
Unified · Split
| @@ -496,16 +496,15 @@ void VoxelSystem::initVoxelMemory() { · 495 unmodified lines | |||
| 496 | 496 | ||
| 497 | // create our simple fragment shader if we're the first system to init | 497 | // create our simple fragment shader if we're the first system to init |
| 498 | if (!_perlinModulateProgram.isLinked()) { | 498 | if (!_perlinModulateProgram.isLinked()) { |
| 499 | switchToResourcesParentIfRequired(); | 499 | _perlinModulateProgram.addShaderFromSourceFile(QGLShader::Vertex, ":/shaders/perlin_modulate.vert"); |
| 500 | _perlinModulateProgram.addShaderFromSourceFile(QGLShader::Vertex, "resources/shaders/perlin_modulate.vert"); | 500 | _perlinModulateProgram.addShaderFromSourceFile(QGLShader::Fragment, ":/shaders/perlin_modulate.frag"); |
| 501 | _perlinModulateProgram.addShaderFromSourceFile(QGLShader::Fragment, "resources/shaders/perlin_modulate.frag"); | ||
| 502 | _perlinModulateProgram.link(); | 501 | _perlinModulateProgram.link(); |
| 503 | 502 | ||
| 504 | _perlinModulateProgram.bind(); | 503 | _perlinModulateProgram.bind(); |
| 505 | _perlinModulateProgram.setUniformValue("permutationNormalTexture", 0); | 504 | _perlinModulateProgram.setUniformValue("permutationNormalTexture", 0); |
| 506 | _perlinModulateProgram.release(); | 505 | _perlinModulateProgram.release(); |
| 507 | 506 | ||
| 508 | _shadowMapProgram.addShaderFromSourceFile(QGLShader::Fragment, "resources/shaders/shadow_map.frag"); | 507 | _shadowMapProgram.addShaderFromSourceFile(QGLShader::Fragment, ":/shaders/shadow_map.frag"); |
| 509 | _shadowMapProgram.link(); | 508 | _shadowMapProgram.link(); |
| 510 | 509 | ||
| 511 | _shadowMapProgram.bind(); | 510 | _shadowMapProgram.bind(); |