History

Simplification, window fix.

Andrzej Kapolka committed 11 years ago

Commit a3e65fc1 parent ba50bea2 files · +2 −5Browse files

Showing the changes to interface/src/MetavoxelSystem.cpp (1 of 2 files). Show all

Unified · Split

interface/src/MetavoxelSystem.cpp+1−4
@@ -2036,12 +2036,9 @@ void HeightfieldRenderer::render(bool cursor) { · 2035 unmodified lines
20362036 glColor4f(1.0f, 1.0f, 1.0f, 1.0f);
20372037
20382038 DefaultMetavoxelRendererImplementation::getBaseHeightfieldProgram().bind();
2039− float sDistance = 2.0f / (innerWidth - 1);
2040− float tDistance = 2.0f / (innerHeight - 1);
2041− float distanceProduct = -sDistance * tDistance;
20422039 DefaultMetavoxelRendererImplementation::getBaseHeightfieldProgram().setUniformValue(
20432040 DefaultMetavoxelRendererImplementation::getBaseHeightScaleLocation(), 1.0f / width, 1.0f / height,
2044− sDistance / distanceProduct, tDistance / distanceProduct);
2041+ (innerWidth - 1) / -2.0f, (innerHeight - 1) / -2.0f);
20452042 DefaultMetavoxelRendererImplementation::getBaseHeightfieldProgram().setUniformValue(
20462043 DefaultMetavoxelRendererImplementation::getBaseColorScaleLocation(), (float)width / innerWidth,
20472044 (float)height / innerHeight);