summaryrefslogtreecommitdiff
path: root/drivers/gles3/shader_gles3.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gles3/shader_gles3.cpp')
-rw-r--r--drivers/gles3/shader_gles3.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/gles3/shader_gles3.cpp b/drivers/gles3/shader_gles3.cpp
index 77e257dfc8..d4ef256a33 100644
--- a/drivers/gles3/shader_gles3.cpp
+++ b/drivers/gles3/shader_gles3.cpp
@@ -3,7 +3,7 @@
/*************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
-/* http://www.godotengine.org */
+/* https://godotengine.org */
/*************************************************************************/
/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */
/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */
@@ -102,11 +102,11 @@ void ShaderGLES3::bind_uniforms() {
uniforms_dirty = false;
}
-GLint ShaderGLES3::get_uniform_location(int p_idx) const {
+GLint ShaderGLES3::get_uniform_location(int p_index) const {
ERR_FAIL_COND_V(!version, -1);
- return version->uniform_location[p_idx];
+ return version->uniform_location[p_index];
}
bool ShaderGLES3::bind() {
@@ -273,9 +273,11 @@ ShaderGLES3::Version *ShaderGLES3::get_current_version() {
//vertex precision is high
strings.push_back("precision highp float;\n");
strings.push_back("precision highp int;\n");
+#ifndef GLES_OVER_GL
strings.push_back("precision highp sampler2D;\n");
strings.push_back("precision highp samplerCube;\n");
strings.push_back("precision highp sampler2DArray;\n");
+#endif
#if 0
if (cc) {
@@ -374,9 +376,11 @@ ShaderGLES3::Version *ShaderGLES3::get_current_version() {
//fragment precision is medium
strings.push_back("precision highp float;\n");
strings.push_back("precision highp int;\n");
+#ifndef GLES_OVER_GL
strings.push_back("precision highp sampler2D;\n");
strings.push_back("precision highp samplerCube;\n");
strings.push_back("precision highp sampler2DArray;\n");
+#endif
#if 0
if (cc) {