From 5bb87f0f3a3876b8cc9331e881155467a7474a2a Mon Sep 17 00:00:00 2001 From: Kunal Agarwal Date: Wed, 29 Jun 2022 00:42:38 +0530 Subject: qcam: assets: shader: bayer_8.frag: Add precision The OpenGL ES shading language has no default precision declared implicitly for floats in fragment shaders. The lack of an explicit default precision results in shader compilation errors. Specify a default precision of mediump for floats. This matches the other fragment shaders, and is guaranteed by the OpenGL ES shader language specification to be supported by all devices, while the higher precision highp is optional. Signed-off-by: Kunal Agarwal Reviewed-by: Laurent Pinchart Signed-off-by: Laurent Pinchart --- src/qcam/assets/shader/bayer_8.frag | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/qcam') diff --git a/src/qcam/assets/shader/bayer_8.frag b/src/qcam/assets/shader/bayer_8.frag index 4ece44ab..7e35ca88 100644 --- a/src/qcam/assets/shader/bayer_8.frag +++ b/src/qcam/assets/shader/bayer_8.frag @@ -15,6 +15,9 @@ Copyright (C) 2021, Linaro */ //Pixel Shader +#ifdef GL_ES +precision mediump float; +#endif /** Monochrome RGBA or GL_LUMINANCE Bayer encoded texture.*/ uniform sampler2D tex_y; -- cgit v1.2.1