summaryrefslogtreecommitdiff
path: root/legacy/evas/m4
diff options
context:
space:
mode:
authorJiyoun Park <jy0703.park@samsung.com>2011-05-04 06:15:00 +0000
committerCarsten Haitzler <raster@rasterman.com>2011-05-04 06:15:00 +0000
commit56111d2b6903abca742bdd0877232ef4c4b3225f (patch)
treee4a66042a2cab330c74276a12875390ad9f466e5 /legacy/evas/m4
parentcc9bc35e59c1d32c90ef9d37e105aeefa4a45d7a (diff)
From: Jiyoun Park <jy0703.park@samsung.com>
Subject: [E-devel] [Patch] Evas gl shader use binary shader I make patch related with evas gl binary shader. The concept of binary shader is compile shader only once. Some people want to use binary shader because of performance issue. In current evas gl engine, every application have to compile shader each time. But I modify code , so only first running application need compile shader. Other application use already compiled shader(binary shader) The binary shader is made under HOME/.evas/gl_common_shaders directory. Binary shader is created according to GL vendor,GL renderer, GL version and Module_arch. The basic flow is 1. First running application which use gl engine check binary shader directory, but it can't find binary shader. 2. After compiling shader, It saves compiled shaders.. 3. Other application checks shader directory, it can use binary shaders. In mobile target, using binary shader, I can save 150ms. (that time, there is 11 shaders). If there is more shaders and more applications, this flow maybe save more total time. (the above is now in, changelog coming, with change to using ~/.cache, some formatting fixes, make ity do the desktop gl one right with the retrievable hint parameter ont he program etc. - doesn't break desktop gl at least. yay. a,so fixes to mke it compile at all). SVN revision: 59167
Diffstat (limited to 'legacy/evas/m4')
-rw-r--r--legacy/evas/m4/evas_check_engine.m434
1 files changed, 20 insertions, 14 deletions
diff --git a/legacy/evas/m4/evas_check_engine.m4 b/legacy/evas/m4/evas_check_engine.m4
index b1f60c7..b968602 100644
--- a/legacy/evas/m4/evas_check_engine.m4
+++ b/legacy/evas/m4/evas_check_engine.m4
@@ -113,16 +113,19 @@ if test "x$gl_flavor_gles" = "xyes" ; then
113fi 113fi
114 114
115if test "x${have_dep}" = "xyes" ; then 115if test "x${have_dep}" = "xyes" ; then
116 if test "x$2" = "xyes" ; then 116 PKG_CHECK_MODULES([GL_EET], [eet >= 1.4.0], [have_dep="yes"], [have_dep="no"])
117 x_libs="${x_libs} -lX11 -lXext -lXrender" 117 if test "x${have_dep}" = "xyes" ; then
118 else 118 if test "x$2" = "xyes" ; then
119 x_dir=${x_dir:-/usr/X11R6} 119 x_libs="${x_libs} -lX11 -lXext -lXrender"
120 x_cflags=${x_cflags:--I${x_includes:-$x_dir/include}} 120 else
121 x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11 -lXext -lXrender" 121 x_dir=${x_dir:-/usr/X11R6}
122 fi 122 x_cflags=${x_cflags:--I${x_includes:-$x_dir/include}}
123 x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11 -lXext -lXrender"
124 fi
123 evas_engine_[]$1[]_cflags="-I/usr/include ${x_cflags}" 125 evas_engine_[]$1[]_cflags="-I/usr/include ${x_cflags}"
124 evas_engine_[]$1[]_libs="${x_libs} -lGL $gl_pt_lib" 126 evas_engine_[]$1[]_libs="${x_libs} -lGL $gl_pt_lib"
125 evas_engine_gl_common_libs="-lGL $gl_pt_lib" 127 evas_engine_gl_common_libs="-lGL $gl_pt_lib"
128 fi
126else 129else
127 if test "x$2" = "xyes" ; then 130 if test "x$2" = "xyes" ; then
128 x_libs="${x_libs} -lX11 -lXext -lXrender" 131 x_libs="${x_libs} -lX11 -lXext -lXrender"
@@ -147,13 +150,16 @@ else
147 if test "x${have_egl}" = "xyes" ; then 150 if test "x${have_egl}" = "xyes" ; then
148 AC_CHECK_LIB(GLESv2, glTexImage2D, [have_glesv2="yes"], , -lEGL ${x_libs} -lm $gl_pt_lib) 151 AC_CHECK_LIB(GLESv2, glTexImage2D, [have_glesv2="yes"], , -lEGL ${x_libs} -lm $gl_pt_lib)
149 if test "x${have_glesv2}" = "xyes" ; then 152 if test "x${have_glesv2}" = "xyes" ; then
150 evas_engine_[]$1[]_cflags="${x_cflags}" 153 PKG_CHECK_MODULES([GL_EET], [eet >= 1.4.0], [have_dep="yes"], [have_dep="no"])
151 evas_engine_[]$1[]_libs="${x_libs} -lGLESv2 -lEGL -lm $gl_pt_lib" 154 if test "x${have_dep}" = "xyes" ; then
152 evas_engine_gl_common_libs="-lGLESv2 -lm $gl_pt_lib" 155 evas_engine_[]$1[]_cflags="${x_cflags}"
153 have_dep="yes" 156 evas_engine_[]$1[]_libs="${x_libs} -lGLESv2 -lEGL -lm $gl_pt_lib"
154 gl_flavor_gles="no" 157 evas_engine_gl_common_libs="-lGLESv2 -lm $gl_pt_lib"
155 AC_DEFINE(GLES_VARIETY_SGX, 1, [Imagination SGX GLES2 support]) 158 have_dep="yes"
156 gles_variety_sgx="yes" 159 gl_flavor_gles="no"
160 AC_DEFINE(GLES_VARIETY_SGX, 1, [Imagination SGX GLES2 support])
161 gles_variety_sgx="yes"
162 fi
157 fi 163 fi
158 fi 164 fi
159fi 165fi