Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Erwin <significant.bit@gmail.com>2016-09-21 21:24:02 +0300
committerMike Erwin <significant.bit@gmail.com>2016-09-21 21:24:02 +0300
commit825150605e36547a6216228deabf79153ae2ae00 (patch)
tree62bd7dc51288b4253f7c2f1b7a792c06c61ee42a
parent9047717b3f51ca23735e5f291a8773053895dc36 (diff)
GPU_basic_shader uses GLSL by default
switch back to old mode at runtime: blender --enable-legacy-basic-shader
-rw-r--r--source/blender/gpu/intern/gpu_basic_shader.c2
-rw-r--r--source/creator/creator_args.c12
2 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/gpu/intern/gpu_basic_shader.c b/source/blender/gpu/intern/gpu_basic_shader.c
index c1b9d9acc65..9d1e84cd44e 100644
--- a/source/blender/gpu/intern/gpu_basic_shader.c
+++ b/source/blender/gpu/intern/gpu_basic_shader.c
@@ -269,7 +269,7 @@ const GLubyte stipple_hexagon[128] = {
/* GLSL State */
-static bool USE_GLSL = false;
+static bool USE_GLSL = true;
/**
* \note this isn't part of the basic shader API,
diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c
index c3c76a0d1d3..21586d162e5 100644
--- a/source/creator/creator_args.c
+++ b/source/creator/creator_args.c
@@ -1186,13 +1186,13 @@ static int arg_handle_depsgraph_use_new(int UNUSED(argc), const char **UNUSED(ar
return 0;
}
-static const char arg_handle_basic_shader_glsl_use_new_doc[] =
-"\n\tUse new GLSL basic shader"
+static const char arg_handle_basic_shader_use_legacy_doc[] =
+"\n\tUse legacy (non-GLSL) basic shader"
;
-static int arg_handle_basic_shader_glsl_use_new(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data))
+static int arg_handle_basic_shader_use_legacy(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data))
{
- printf("Using new GLSL basic shader.\n");
- GPU_basic_shader_use_glsl_set(true);
+ printf("Using legacy (non-GLSL) basic shader.\n");
+ GPU_basic_shader_use_glsl_set(false);
return 0;
}
@@ -1830,7 +1830,7 @@ void main_args_setup(bContext *C, bArgs *ba, SYS_SystemHandle *syshandle)
CB_EX(arg_handle_debug_mode_generic_set, gpumem), (void *)G_DEBUG_GPU_MEM);
BLI_argsAdd(ba, 1, NULL, "--enable-new-depsgraph", CB(arg_handle_depsgraph_use_new), NULL);
- BLI_argsAdd(ba, 1, NULL, "--enable-new-basic-shader-glsl", CB(arg_handle_basic_shader_glsl_use_new), NULL);
+ BLI_argsAdd(ba, 1, NULL, "--enable-legacy-basic-shader", CB(arg_handle_basic_shader_use_legacy), NULL);
BLI_argsAdd(ba, 1, NULL, "--verbose", CB(arg_handle_verbosity_set), NULL);