summaryrefslogtreecommitdiff
path: root/src/qcam/viewfinder_gl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/qcam/viewfinder_gl.cpp')
-rw-r--r--src/qcam/viewfinder_gl.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/qcam/viewfinder_gl.cpp b/src/qcam/viewfinder_gl.cpp
index 5d9b442e..ff719418 100644
--- a/src/qcam/viewfinder_gl.cpp
+++ b/src/qcam/viewfinder_gl.cpp
@@ -289,7 +289,7 @@ bool ViewFinderGL::createFragmentShader()
textureUniformY_ = shaderProgram_.uniformLocation("tex_y");
textureUniformU_ = shaderProgram_.uniformLocation("tex_u");
textureUniformV_ = shaderProgram_.uniformLocation("tex_v");
- textureUniformStepX_ = shaderProgram_.uniformLocation("tex_stepx");
+ textureUniformStep_ = shaderProgram_.uniformLocation("tex_step");
/* Create the textures. */
for (std::unique_ptr<QOpenGLTexture> &texture : textures_) {
@@ -508,8 +508,9 @@ void ViewFinderGL::doRender()
* ([0, 1]). There are exactly width - 1 steps between the
* leftmost and rightmost texels.
*/
- shaderProgram_.setUniformValue(textureUniformStepX_,
- 1.0f / (size_.width() / 2 - 1));
+ shaderProgram_.setUniformValue(textureUniformStep_,
+ 1.0f / (size_.width() / 2 - 1),
+ 1.0f /* not used */);
break;
case libcamera::formats::ABGR8888: