From 05c309da67c354a1022ddae532e400f90a27b11b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fredrik=20H=C3=B6glund?= Date: Tue, 1 Apr 2014 18:07:47 +0200 Subject: [PATCH] Add a ModelViewProjectionMatrix uniform --- libkwineffects/kwinglutils.cpp | 11 ++++++----- libkwineffects/kwinglutils.h | 1 + 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/libkwineffects/kwinglutils.cpp b/libkwineffects/kwinglutils.cpp index 750def5f04..fa91758e3b 100644 --- a/libkwineffects/kwinglutils.cpp +++ b/libkwineffects/kwinglutils.cpp @@ -418,11 +418,12 @@ void GLShader::resolveLocations() if (mLocationsResolved) return; - mMatrixLocation[TextureMatrix] = uniformLocation("textureMatrix"); - mMatrixLocation[ProjectionMatrix] = uniformLocation("projection"); - mMatrixLocation[ModelViewMatrix] = uniformLocation("modelview"); - mMatrixLocation[WindowTransformation] = uniformLocation("windowTransformation"); - mMatrixLocation[ScreenTransformation] = uniformLocation("screenTransformation"); + mMatrixLocation[TextureMatrix] = uniformLocation("textureMatrix"); + mMatrixLocation[ProjectionMatrix] = uniformLocation("projection"); + mMatrixLocation[ModelViewMatrix] = uniformLocation("modelview"); + mMatrixLocation[ModelViewProjectionMatrix] = uniformLocation("modelViewProjectionMatrix"); + mMatrixLocation[WindowTransformation] = uniformLocation("windowTransformation"); + mMatrixLocation[ScreenTransformation] = uniformLocation("screenTransformation"); mVec2Location[Offset] = uniformLocation("offset"); diff --git a/libkwineffects/kwinglutils.h b/libkwineffects/kwinglutils.h index 0bceb10089..75f1e956b9 100644 --- a/libkwineffects/kwinglutils.h +++ b/libkwineffects/kwinglutils.h @@ -133,6 +133,7 @@ public: TextureMatrix = 0, ProjectionMatrix, ModelViewMatrix, + ModelViewProjectionMatrix, WindowTransformation, ScreenTransformation, MatrixCount