changeset 626:e4138c12fa8c openvg

Call mbe_vg_win_surface_create() in X_supp.c when with OpenVG
author Thinker K.F. Li <thinker@branda.to>
date Fri, 16 Jul 2010 16:39:53 +0800
parents 39bd74da7f92
children 97bf0ff7a038
files configure.ac src/X_supp.c
diffstat 2 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/configure.ac	Fri Jul 09 11:50:48 2010 +0800
+++ b/configure.ac	Fri Jul 16 16:39:53 2010 +0800
@@ -126,7 +126,7 @@
 # Define AM and AC variable for X_supp
 AM_CONDITIONAL([X_SUPP],
 	 [test x$X_supp = xtrue -a x$cairo = xtrue])
-[if [ x"${X_supp}" = xtrue -a x"${cairo}" = xtrue ]; then]
+[if [ x"${X_supp}" = xtrue -a \( x"${cairo}" = xtrue -o x"${openvg}" = xtrue \) ]; then]
 AC_DEFINE([X_SUPP])
 [fi]
 
--- a/src/X_supp.c	Fri Jul 09 11:50:48 2010 +0800
+++ b/src/X_supp.c	Fri Jul 16 16:39:53 2010 +0800
@@ -475,11 +475,19 @@
     xmb_rt->surface_ptn =
 	mbe_pattern_create_for_surface(xmb_rt->surface);
     
+#ifdef OPENVG_GRAPH_ENGINE
+    xmb_rt->backend_surface =
+	mbe_vg_win_surface_create(xmb_rt->display,
+				  xmb_rt->win,
+				  xmb_rt->visual,
+				  w, h);
+#else
     xmb_rt->backend_surface =
 	mbe_xlib_surface_create(xmb_rt->display,
 				  xmb_rt->win,
 				  xmb_rt->visual,
 				  w, h);
+#endif
 
     xmb_rt->cr = mbe_create(xmb_rt->surface);
     xmb_rt->backend_cr = mbe_create(xmb_rt->backend_surface);