Evas GL: Implement runtime generation and load of shaders
authorJean-Philippe Andre <jp.andre@samsung.com>
Thu, 5 Nov 2015 06:39:32 +0000 (15:39 +0900)
committerJean-Philippe Andre <jp.andre@samsung.com>
Tue, 10 Nov 2015 07:12:20 +0000 (16:12 +0900)
commit38ad8fda8ddb681707b42a17a23eba29b3bbd86e
treedcf22fb1ed0be42ae79acb4c75d08130a4171051
parent43ef6152eda0ac0e4ef3aee55b25264f12e4e64b
Evas GL: Implement runtime generation and load of shaders

Instead of generating the shaders at compile-time, do this at
runtime. Also load only the required shaders in memory.

This saves 25000 LOC, lots of strings inside the .so files
and save a non negligible amount of memory since those shader
binaries can weigh a few megabytes in total.

The current shader selection mechanism is a bit complex and
uses eina_hash_int32 but this can be optimized later if it's
deemed too slow.
12 files changed:
src/Makefile_Evas.am
src/modules/evas/engines/gl_common/evas_gl_common.h
src/modules/evas/engines/gl_common/evas_gl_context.c
src/modules/evas/engines/gl_common/evas_gl_shader.c
src/modules/evas/engines/gl_common/shader/evas_gl_enum.x [deleted file]
src/modules/evas/engines/gl_common/shader/evas_gl_shaders.x
src/modules/evas/engines/gl_common/shader/evas_gl_shaders_bigendian.x [deleted file]
src/modules/evas/engines/gl_common/shader/fragment.glsl
src/modules/evas/engines/gl_common/shader/gen_shaders.sh
src/modules/evas/engines/gl_common/shader/include.glsl [new file with mode: 0644]
src/modules/evas/engines/gl_common/shader/shaders.txt [deleted file]
src/modules/evas/engines/gl_common/shader/vertex.glsl