use new Martix4 function which use temporary array

- avoid 'undefined behaviour' which did work for most cases...
This commit is contained in:
Hannes Janetzek
2013-05-11 22:53:24 +02:00
parent b463ca7e3b
commit 477548c5f7
5 changed files with 9 additions and 11 deletions

View File

@@ -100,7 +100,7 @@ public abstract class RenderLayer {
matrices.mvp.setTransScale((float) (x * tileScale), (float) (y * tileScale),
(float) ((position.scale / oPos.scale) / GLRenderer.COORD_SCALE));
matrices.mvp.multiplyMM(project ? matrices.viewproj : matrices.view, matrices.mvp);
matrices.mvp.multiplyLhs(project ? matrices.viewproj : matrices.view);
}
/**

View File

@@ -111,10 +111,7 @@ public class CustomRenderLayer extends RenderLayer {
float ratio = 1f / mMapView.getWidth();
m.mvp.setScale(ratio, ratio, 1);
m.mvp.multiplyMM(m.proj, m.mvp);
// setMatrix(pos, m);
m.mvp.multiplyLhs(m.proj);
m.mvp.setAsUniform(hMatrixPosition);
// Draw the triangle

View File

@@ -333,7 +333,7 @@ public class ExtrusionRenderLayer extends RenderLayer {
// scale height
m.mvp.setValue(10, scale / 10);
m.mvp.multiplyMM(m.viewproj, m.mvp);
m.mvp.multiplyLhs(m.viewproj);
m.mvp.addDepthOffset(delta);
}