The Rasterman (Carsten Haitzler) <raster@rasterman.com>
-
+Tim Horton <hortont424@gmail.com>
+Saumsung Electronics <tbd>
+Samsung SAIT <tbd>
+Bruno Tarquini <btarquini@gmail.com>
+ChunEon Park (Hermet) <hermet@hermet.pe.kr>
-Copyright (C) 2000 Carsten Haitzler and various contributors (see AUTHORS)
+Copyright notice for Expedite:
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to
-deal in the Software without restriction, including without limitation the
-rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
-sell copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
+Copyright (C) 2007-2011 Carsten Haitzler and various contributors (see AUTHORS)
-The above copyright notice and this permission notice shall be included in
-all copies of the Software and its Copyright notices. In addition publicly
-documented acknowledgment must be given that this software has been used if no
-source code of this software is made available publicly. This includes
-acknowledgments in either Copyright notices, Manuals, Publicity and Marketing
-documents or any documentation provided with any product containing this
-software. This License does not apply to any software that links to the
-libraries provided by this software (statically or dynamically), but only to
-the software provided.
+All rights reserved.
-Please see the COPYING.PLAIN for a plain-english explanation of this notice
-and it's intent.
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
-THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
-IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ 1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
+INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+2011-12-02 Carsten Haitzler (The Rasterman)
+
+ 1.1.0 release
+
+2012-04-26 Carsten Haitzler (The Rasterman)
+
+ 1.2.0 release
+
+2012-05-02 Cedric Bail
+
+ * Do not allocate more than once Evas_Map.
+
+2012-08-30 Carsten Haitzler (The Rasterman)
+
+ 1.7.0 release
+Expedite 1.7.0
+
+Changes since Expedite 1.2.0:
+-----------------------------
+
+Improvements:
+
+ * Don't over allocate Evas_Map.
+
+Expedite 1.2.0
+
+Changes since Expedite 1.1.0:
+-----------------------------
+
+Removals:
+
+ * Evas SDL 16bpp engine suport
+ * Software_SDL engine (nos just use buffer engine)
-Expedite 0.6.0
+Expedite 1.7.99
+
+******************************************************************************
+
+ FOR ANY ISSUES PLEASE EMAIL:
+ enlightenment-devel@lists.sourceforge.net
+
+******************************************************************************
+
+Requirements:
+-------------
+Must have:
+ libc
+ libm
+ evas (at least 1.1.0)
This is meant to be a detailed and comprehensive benchmark suite for Evas.
+
+The images can be interchanged for demonstration purposes. Logo.png should
+have some areas of alpha to demonstrate transparency.
+
+------------------------------------------------------------------------------
+COMPILING AND INSTALLING:
+
+ ./configure
+ make
+(as root unless you are installing in your users directories):
+ make install
+
--- /dev/null
+dnl Process this file with autoconf to produce a configure script.
+
+# get rid of that stupid cache mechanism
+rm -f config.cache
+
+AC_INIT([expedite], [1.7.99], [enlightenment-devel@lists.sourceforge.net])
+AC_PREREQ([2.52])
+AC_CONFIG_SRCDIR([configure.ac])
+AC_CONFIG_HEADERS([config.h])
+AC_CANONICAL_BUILD
+AC_CANONICAL_HOST
+
+AM_INIT_AUTOMAKE([1.6 dist-bzip2])
+m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
+
+PKG_PROG_PKG_CONFIG
+
+
+### Additional options to configure
+
+## Simple X11 build/link
+
+## Evas engines
+
+AC_ARG_ENABLE(simple-x11,
+ [AC_HELP_STRING([--enable-simple-x11], [enable simple x11 linking])],
+ [want_evas_simple_x11=$enableval]
+)
+
+# Software X11
+have_software_xlib="no"
+have_software_xcb="no"
+EXPEDITE_CHECK_ENGINE([software-x11], [Software X11], "yes")
+
+if test "x${have_software_x11}" = "xyes" ; then
+ have_software_xlib=`${PKG_CONFIG} --variable=Xlib evas-software-x11`
+ if test "x${have_software_xlib}" = "xstatic" ; then
+ have_software_xlib="yes"
+ fi
+ if test "x${have_software_xlib}" = "xyes" ; then
+ AC_DEFINE(HAVE_EVAS_SOFTWARE_XLIB, 1, [Evas Software Xlib Engine Support])
+ fi
+ have_software_xcb=`${PKG_CONFIG} --variable=XCB evas-software-x11`
+ if test "x${have_software_xcb}" = "xstatic" ; then
+ have_software_xcb="yes"
+ fi
+ if test "x${have_software_xcb}" = "xyes" ; then
+ AC_DEFINE(HAVE_EVAS_SOFTWARE_XCB, 1, [Evas Software XCB Engine Support])
+ fi
+fi
+
+AM_CONDITIONAL([BUILD_SOFTWARE_XLIB], [test "x${have_software_xlib}" = "xyes"])
+AM_CONDITIONAL([BUILD_SOFTWARE_XCB], [test "x${have_software_xcb}" = "xyes"])
+
+# XRender X11
+EXPEDITE_CHECK_ENGINE([xrender-x11], [XRender X11], "yes")
+
+# OpenGL X11
+EXPEDITE_CHECK_ENGINE([opengl-x11], [OpenGL X11], "yes")
+
+# XRender XCB
+EXPEDITE_CHECK_ENGINE([xrender-xcb], [XRender XCB], "yes")
+
+# GDI
+EXPEDITE_CHECK_ENGINE([software-gdi], [Software GDI], "yes", [gdi_libs="-lgdi32"])
+AC_SUBST(gdi_libs)
+
+# DirectDraw
+EXPEDITE_CHECK_ENGINE([software-ddraw], [Software DirectDraw], "yes", [ddraw_libs="-lddraw -ldxguid -lgdi32"])
+AC_SUBST(ddraw_libs)
+
+# Direct3D
+EXPEDITE_CHECK_ENGINE([direct3d], [Direct3D], "yes", [d3d_libs="-ld3d9 -ld3dx9d -lgdi32"])
+AC_SUBST(d3d_libs)
+
+# PSL1GHT
+EXPEDITE_CHECK_ENGINE([psl1ght], [PSL1GHT], "yes")
+
+# GL SDL
+EXPEDITE_CHECK_ENGINE([opengl-sdl], [OpenGL SDL], "yes")
+
+# FB
+EXPEDITE_CHECK_ENGINE([fb], [Framebuffer], "yes")
+
+# DIRECTFB
+EXPEDITE_CHECK_ENGINE([directfb], [DirectFB], "yes")
+
+# GL Cocoa
+EXPEDITE_CHECK_ENGINE([opengl-cocoa], [OpenGL Cocoa], "yes", [gl_cocoa_libs="-framework Cocoa"])
+AC_SUBST(gl_cocoa_libs)
+
+# Software 16bit X11
+EXPEDITE_CHECK_ENGINE([software-16-x11], [Software 16 bits X11], "yes")
+
+# 16bit WinCE
+EXPEDITE_CHECK_ENGINE([software-16-wince], [Software 16 bits WinCE], "yes", [wince_16_libs="-laygshell"])
+AC_SUBST(wince_16_libs)
+
+### Checks for programs
+
+AC_ISC_POSIX
+m4_ifdef([AC_PROG_OBJC],
+ [
+ AC_PROG_OBJC
+ _AM_DEPENDENCIES(OBJC)
+ ],
+ [
+ AC_CHECK_TOOL([OBJC], [gcc])
+ AC_SUBST([OBJC])
+ AC_SUBST([OBJCFLAGS])
+ ]
+)
+AC_PROG_CXX
+AC_PROG_CC
+
+LT_PROG_RC
+
+
+
+### Checks for libraries
+
+# Evil library for compilation on Windows
+
+case "$host_os" in
+ mingw32*)
+ PKG_CHECK_MODULES([EVIL], [evil >= 1.6.99])
+ AC_DEFINE(HAVE_EVIL, 1, [Set to 1 if Evil library is installed])
+ ;;
+esac
+
+# Eina
+
+PKG_CHECK_MODULES([EINA], eina >= 1.6.99)
+
+# Evas
+
+PKG_CHECK_MODULES([EVAS], evas >= 1.6.99 eet >= 1.6.99)
+
+# Xlib
+
+if test "x$have_software_xlib" = "xyes" -o "x$have_software_16_x11" = "xyes" -o "x$have_xrender_x11" = "xyes" -o "x$have_opengl_x11" = "xyes"; then
+ AC_PATH_XTRA
+ AC_CHECK_HEADERS([X11/Xlib.h X11/Xutil.h],
+ [have_xlib="yes"],
+ [have_xlib="no"])
+ if test "x$want_evas_simple_x11" = "xyes"; then
+ x_libs="${x_libs} -lX11"
+ else
+ x_dir=${x_dir:-/usr/X11R6}
+ x_cflags=${x_cflags:--I${x_includes:-$x_dir/include}}
+ x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11"
+ fi
+fi
+AM_CONDITIONAL(BUILD_X11, [test "x$have_xlib" = "xyes"])
+
+AC_SUBST(x_cflags)
+AC_SUBST(x_libs)
+
+# XCB
+
+if test "x$have_software_xcb" = "xyes"; then
+ PKG_CHECK_MODULES([XCB], [xcb xcb-keysyms], [have_xcb="yes"], [have_xcb="no"])
+fi
+AM_CONDITIONAL(BUILD_XCB, test "x$have_xcb" = "xyes")
+if test "x$have_xcb" = "xyes"; then
+ AC_DEFINE(BUILD_XCB, 1, [build xcb support])
+fi
+
+# SDL
+
+PKG_CHECK_MODULES([SDL], [sdl], [have_sdl="yes"], [have_sdl="no"])
+AM_CONDITIONAL(BUILD_SDL, test "x$have_sdl" = "xyes")
+if test "x$have_sdl" = "xyes"; then
+ AC_DEFINE(BUILD_SDL, 1, [build sdl support])
+fi
+
+# PSL1GHT
+AM_CONDITIONAL(BUILD_PSL1GHT, test "x$have_psl1ght" = "xyes")
+
+# DirectFB
+
+if test "x$have_directfb" = "xyes"; then
+ PKG_CHECK_MODULES([DIRECTFB], [directfb], [have_directfb="yes"], [have_directfb="no"])
+fi
+AM_CONDITIONAL(BUILD_DIRECTFB, test "x$have_directfb" = "xyes")
+
+
+### Checks for header files
+
+
+### Checks for types
+
+
+### Checks for structures
+
+
+### Checks for compiler characteristics
+
+AM_PROG_CC_STDC
+AC_HEADER_STDC
+AC_C_CONST
+AM_PROG_CC_C_O
+AC_C___ATTRIBUTE__
+
+WIN32_CFLAGS=""
+case "$host_os" in
+ cegcc*)
+ WIN32_CFLAGS="-mwin32"
+ ;;
+esac
+AC_SUBST(WIN32_CFLAGS)
+
+EXPEDITE_CXXFLAGS=""
+AC_LANG_PUSH([C++])
+CXXFLAGS_save="${CXXFLAGS}"
+CXXFLAGS="${CXXFLAGS} -fno-rtti -fno-exceptions"
+AC_LINK_IFELSE(
+ [AC_LANG_PROGRAM([[]])],
+ [have_cxx_flags="yes"],
+ [have_cxx_flags="no"])
+AC_MSG_CHECKING([whether the compiler supports -fno-rtti -fno-exceptions])
+AC_MSG_RESULT([${have_cxx_flags}])
+CXXFLAGS="${CXXFLAGS_save}"
+if test "x${have_cxx_flags}" = "xyes" ; then
+ EXPEDITE_CXXFLAGS="-fno-rtti -fno-exceptions"
+fi
+AC_LANG_POP([C++])
+AC_SUBST(EXPEDITE_CXXFLAGS)
+
+
+### Checks for linker characteristics
+
+lt_enable_auto_import=""
+case "$host_os" in
+ mingw* | cegcc*)
+ lt_enable_auto_import="-Wl,--enable-auto-import"
+ ;;
+esac
+AC_SUBST(lt_enable_auto_import)
+
+
+### Checks for library functions
+
+AC_CHECK_FUNCS([sync])
+
+
+AC_OUTPUT([
+Makefile
+expedite.spec
+src/Makefile
+src/bin/Makefile
+data/Makefile
+])
+
+echo
+echo " $PACKAGE $VERSION"
+echo
+echo " Engines:"
+echo " Software X11.................: ${have_software_x11} (Xlib: ${have_software_xlib}) (XCB: ${have_software_xcb})"
+echo " X Render X11.................: ${have_xrender_x11}"
+echo " Open GL X11..................: ${have_opengl_x11}"
+echo " X Render XCB.................: ${have_xrender_xcb}"
+echo " Software GDI.................: ${have_software_gdi}"
+echo " Software DirectDraw..........: ${have_software_ddraw}"
+echo " Direct3D.....................: ${have_direct3d}"
+echo " Software SDL.................: ${have_software_sdl}"
+echo " Open GL SDL..................: ${have_opengl_sdl}"
+echo " Open GL Cocoa................: ${have_opengl_cocoa}"
+echo " FB...........................: ${have_fb}"
+echo " DirectFB.....................: ${have_directfb}"
+echo " PSL1GHT......................: ${have_psl1ght}"
+echo " Software X11 16 bits.........: ${have_software_16_x11}"
+echo " Software WinCE 16 bits.......: ${have_software_16_wince}"
+echo
+echo " Installation:"
+echo " prefix.......................: ${prefix}"
+echo
VeraSeBd.ttf \
fonts.alias \
fonts.dir \
-bg.png \
logo.png \
+e-logo.png \
e.png \
image.png \
bar.png \
tp.png \
tp.yuv \
icon_sel.png \
-icon_sel2.png \
text_sel.png \
exit.png \
watch.png \
typewriter.png \
warning.png \
im1.png \
-im2.png
+im2.png \
+cube1.png \
+cube2.png \
+cube3.png \
+cube4.png \
+cube5.png \
+cube6.png \
+text.png \
+rect.png \
+blend.png \
+map.png \
+3d.png \
+data.png \
+widgets.png \
+e-logo-2.png \
+e-logo-mask.png \
+texture.png
EXTRA_DIST = $(files_DATA)
--- /dev/null
+K 25
+svn:wc:ra_dav:version-url
+V 43
+/svn/e/!svn/ver/40544/trunk/expedite/debian
+END
+control
+K 25
+svn:wc:ra_dav:version-url
+V 51
+/svn/e/!svn/ver/40544/trunk/expedite/debian/control
+END
+compat
+K 25
+svn:wc:ra_dav:version-url
+V 50
+/svn/e/!svn/ver/38399/trunk/expedite/debian/compat
+END
+changelog
+K 25
+svn:wc:ra_dav:version-url
+V 53
+/svn/e/!svn/ver/40270/trunk/expedite/debian/changelog
+END
+copyright
+K 25
+svn:wc:ra_dav:version-url
+V 53
+/svn/e/!svn/ver/38399/trunk/expedite/debian/copyright
+END
+rules
+K 25
+svn:wc:ra_dav:version-url
+V 49
+/svn/e/!svn/ver/39695/trunk/expedite/debian/rules
+END
--- /dev/null
+10
+
+dir
+46864
+https://svn.enlightenment.org/svn/e/trunk/expedite/debian
+https://svn.enlightenment.org/svn/e
+
+
+
+2009-05-08T05:20:44.706134Z
+40544
+barbieri
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+7cbeb6ba-43b4-40fd-8cce-4c39aea84d33
+\f
+control
+file
+
+
+
+
+2010-03-04T12:30:52.000000Z
+59e5940467768cd8df9da012d44eefd7
+2009-05-08T05:20:44.706134Z
+40544
+barbieri
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+477
+\f
+compat
+file
+
+
+
+
+2010-03-04T12:30:52.000000Z
+9ae0ea9e3c9c6e1b9b6252c8395efdc1
+2009-01-01T11:35:17.282485Z
+38399
+quaker
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2
+\f
+changelog
+file
+
+
+
+
+2010-03-04T12:30:52.000000Z
+37edcdd83dacfb5c6f66b91c4cbdcff9
+2009-04-21T17:39:20.596180Z
+40270
+quaker
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+139
+\f
+copyright
+file
+
+
+
+
+2010-03-04T12:30:52.000000Z
+7ef9c1cdfd248847a5ae32f0093054bd
+2009-01-01T11:35:17.282485Z
+38399
+quaker
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+233
+\f
+rules
+file
+
+
+
+
+2010-03-04T12:30:52.000000Z
+61bcf010ab933a886927aefe3e40c456
+2009-03-24T19:56:43.554016Z
+39695
+quaker
+has-props
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+274
+\f
--- /dev/null
+K 14
+svn:executable
+V 1
+*
+END
--- /dev/null
+expedite (0.6.0+svnYYYYMMDD-1) unstable; urgency=low
+
+ * a SVN release.
+
+ -- quaker <quaker66@gmail.com> Sat, 27 Dec 2008 14:48:46 +0100
--- /dev/null
+Source: expedite
+Section: x11
+Priority: optional
+Maintainer: quaker <quaker66@gmail.com>
+Build-Depends: cdbs, debhelper (>= 6), libevas-dev, pkg-config, libtool, libxext-dev
+Standards-Version: 3.8.1
+Homepage: http://www.enlightenment.org
+
+Package: expedite
+Architecture: any
+Depends: ${shlibs:Depends}, libevas-svn-01, libevas-engines, libevas-engines-extras
+Description: Benchmarking suite for Evas
+ This is meant to be a detailed and comprehensive benchmark suite for Evas.
+
--- /dev/null
+This package was debianized by quaker <quaker66@gmail.com> on
+Sat, 27 Dec 2008 14:48:46 +0100.
+
+Author(s):
+ The Rasterman (Carsten Haitzler) <raster@rasterman.com>
+ Tim Horton <hortont424@gmail.com>
+
+License:
+ See the COPYING file
+
--- /dev/null
+#!/usr/bin/make -f
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/autotools.mk
+
+DEB_CONFIGURE_SCRIPT := ./autogen.sh
+DEB_MAKE_CLEAN_TARGET := distclean
+DEB_CONFIGURE_EXTRA_FLAGS := --disable-rpath
+
+clean::
+ [ ! -f Makefile ] || make distclean
--- /dev/null
+Revision 51480
+Last Changed Rev 51381
--- /dev/null
+expedite (0.6.0+svnYYYYMMDD-1) unstable; urgency=low
+
+ * a SVN release.
+
+ -- quaker <quaker66@gmail.com> Sat, 27 Dec 2008 14:48:46 +0100
--- /dev/null
+Source: expedite
+Section: x11
+Priority: optional
+Maintainer: quaker <quaker66@gmail.com>
+Build-Depends: cdbs, debhelper (>= 6), libevas-dev, pkg-config, libtool, libxext-dev
+Standards-Version: 3.8.1
+Homepage: http://www.enlightenment.org
+
+Package: expedite
+Architecture: any
+Depends: ${shlibs:Depends}, libevas-svn-01, libevas-engines, libevas-engines-extras
+Description: Benchmarking suite for Evas
+ This is meant to be a detailed and comprehensive benchmark suite for Evas.
+
--- /dev/null
+This package was debianized by quaker <quaker66@gmail.com> on
+Sat, 27 Dec 2008 14:48:46 +0100.
+
+Author(s):
+ The Rasterman (Carsten Haitzler) <raster@rasterman.com>
+ Tim Horton <hortont424@gmail.com>
+
+License:
+ See the COPYING file
+
--- /dev/null
+#!/usr/bin/make -f
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/autotools.mk
+
+DEB_CONFIGURE_SCRIPT := ./autogen.sh
+DEB_MAKE_CLEAN_TARGET := distclean
+DEB_CONFIGURE_EXTRA_FLAGS := --disable-rpath
+
+clean::
+ [ ! -f Makefile ] || make distclean
--- /dev/null
+expedite (1.2.0+svn.70375slp2+build02) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.2.0+svn.70375slp2+build02
+
+ -- Myungjae Lee <mjae.lee@samsung.com> Wed, 25 Apr 2012 17:30:18 +0900
+
+expedite (1.2.0+svn.70375slp2+build01) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.2.0+svn.70375slp2+build01
+
+ -- Myungjae Lee <mjae.lee@samsung.com> Wed, 25 Apr 2012 15:16:03 +0900
+
+expedite (1.2.0+svn.70214slp2+build01) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.2.0+svn.70214slp2+build01
+
+ -- Hyoyoung Chang <hyoyoung.chang@samsung.com> Wed, 18 Apr 2012 15:24:45 +0900
+
+expedite (1.2.0+svn.69899slp2+build01) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.2.0+svn.69899slp2+build01
+
+ -- Jeonghyun Yun <jh0506.yun@samsung.com> Fri, 06 Apr 2012 18:26:37 +0900
+
+expedite (1.0.0+svn.69595slp2+1) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.69595slp2+1
+
+ -- Jeonghyun Yun <jh0506.yun@samsung.com> Wed, 28 Mar 2012 14:31:44 +0900
+
+expedite (1.0.0+svn.68445slp2+1) unstable; urgency=low
+
+ * Package upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.68445slp2+1
+
+ -- Jeonghyun Yun <jh0506.yun@samsung.com> Fri, 02 Mar 2012 06:36:24 -0500
+
+expedite (1.0.0+svn.67184slp2+1) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.67184slp2+1
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Wed, 15 Feb 2012 19:03:56 +0900
+
+expedite (1.0.0+svn.66195slp2+1) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.66195slp2+1
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Mon, 16 Jan 2012 18:40:51 +0900
+
+expedite (1.0.0+svn.65860slp2+1) unstable; urgency=low
+
+ * Package Upload for migration
+ * Git: slp-scm.sec.samsung.net:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.65860slp2+1
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Thu, 08 Dec 2011 14:00:27 +0900
+
+expedite (1.0.0+svn.65336slp2+1) unstable; urgency=low
+
+ * Package Upload
+ * Git: slp-scm.sec.samsung.net:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.65336slp2+1
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Tue, 29 Nov 2011 14:17:22 +0900
+
+expedite (1.0.0+svn.60246slp2+3) unstable; urgency=low
+
+ * Upload Package for EFL core migration
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.60246slp2+3
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Fri, 02 Sep 2011 18:49:35 +0900
+
+expedite (1.0.0+svn.60246slp2+2) unstable; urgency=low
+
+ * Upload Package for EFL core migration
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.60246slp2+2
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Fri, 02 Sep 2011 18:48:38 +0900
+
+expedite (1.0.0+svn.60246slp2+1) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r60246
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.60246slp2+1
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Fri, 24 Jun 2011 18:10:47 +0900
+
+expedite (1.0.0+svn.57467slp2+8) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r57467
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+8
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Tue, 05 Apr 2011 15:55:43 +0900
+
+expedite (1.0.0+svn.57467slp2+7) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r57467
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+7
+
+ -- Shinwoo Kim <cinoo.kim@samsung.com> Tue, 29 Mar 2011 18:56:09 +0900
+
+expedite (1.0.0+svn.57467slp2+6) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r57467
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+6
+
+ -- Myungjae Lee <mjae.lee@samsung.com> Wed, 09 Mar 2011 11:30:19 +0900
+
+expedite (1.0.0+svn.57467slp2+5) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r57467
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+5
+
+ -- Myungjae Lee <mjae.lee@samsung.com> Wed, 09 Mar 2011 11:15:33 +0900
+
+expedite (1.0.0+svn.57467slp2+4) unstable; urgency=low
+
+ * Package Upload : Rollback
+ * Git: 165.213.180.234:/slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+4
+
+ -- WooHyun Jung <wh0705.jung@samsung.com> Tue, 08 Mar 2011 14:09:29 +0900
+
+expedite (1.0.0+svn.57467slp2+3) unstable; urgency=low
+
+ * Package Uplaod : Rollback
+ * Git: 165.213.180.234:/slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+3
+
+ -- WooHyun Jung <wh0705.jung@samsung.com> Tue, 08 Mar 2011 12:54:36 +0900
+
+expedite (1.0.0+svn.57467slp2+2) unstable; urgency=low
+
+ * Package Upload : rollback
+ * Git: 165.213.180.234:/slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+2
+
+ -- WooHyun Jung <wh0705.jung@samsung.com> Tue, 08 Mar 2011 11:23:45 +0900
+
+expedite (1.0.0+svn.57467slp2+1) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r57467
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.57467slp2+1
+
+ -- Myungjae Lee <mjae.lee@samsung.com> Mon, 07 Mar 2011 17:28:46 +0900
+
+expedite (1.0.0+svn.56235slp2+1) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r56235
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.56235slp2+1
+
+ -- WooHyun Jung <wh0705.jung@samsung.com> Thu, 27 Jan 2011 12:25:33 +0900
+
+expedite (1.0.0+svn.55982slp2+1) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r55982
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.55982slp2+1
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.55982slp2+1
+
+ -- WooHyun Jung <wh0705.jung@samsung.com> Wed, 19 Jan 2011 16:24:19 +0900
+
+expedite (1.0.0+svn.55243slp2+2) unstable; urgency=low
+
+ * [SVN EFL Migration] expedite in SLP is merged with SVN r55243
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.55243slp2+2
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Mon, 03 Jan 2011 21:25:58 +0900
+
+expedite (1.0.0+svn.55243slp2+1) unstable; urgency=low
+
+ * [SVN's EFL Migration] expedite in SLP is merged with SVN r55243.
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.55243slp2+1
+
+ -- Juyung Seo <juyung.seo@samsung.com> Tue, 14 Dec 2010 17:58:37 +0900
+
+expedite (1.0.0+svn.54990slp2+2) unstable; urgency=low
+
+ * [SVN's EFL Migration] expedite in SLP is merged with SVN r55243.
+ * Git: 165.213.180.234:slp/pkgs/e/expedite
+ * Tag: expedite_1.0.0+svn.54990slp2+2
+
+ -- Juyung Seo <juyung.seo@samsung.com> Tue, 14 Dec 2010 15:02:23 +0900
+
+expedite (1.0.0+svn.54990slp2+1) unstable; urgency=low
+
+ * [SVN 54990 Merge]
+ * Update to SVN Revision 54990.
+ * Git: 165.213.180.234:/git/slp/pkgs/expedite
+ * Tag: expedite_1.0.0+svn.54990slp2+1
+
+ -- Myoungwoon Kim <myoungwoon.kim@samsung.com> Thu, 02 Dec 2010 14:46:15 +0900
+
+expedite (1.0.0+svn.51480slp2+3) unstable; urgency=low
+
+ * [SVN 54593 Merge]
+ * Update to SVN Revision 54593.
+ * Git: 165.213.180.234:/git/slp/pkgs/expedite
+ * Tag: expedite_1.0.0+svn.51480slp2+3
+
+ -- Juyung Seo <juyung.seo@samsung.com> Fri, 26 Nov 2010 16:00:39 +0900
+
+expedite (1.0.0+svn.51480slp2+2) unstable; urgency=low
+
+ * add as-needed
+ * Git: 165.213.180.234:/git/slp/pkgs/expedite
+ * Tag: expedite_1.0.0+svn.51480slp2+2
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Wed, 15 Sep 2010 16:33:59 +0900
+
+expedite (1.0.0+svn.51480slp2+1) unstable; urgency=low
+
+ * EFL 1.0 alpha upgrade
+ * Git: 165.213.180.234:/git/slp/pkgs/expedite
+ * Tag: expedite_1.0.0+svn.51480slp2+1
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Thu, 02 Sep 2010 13:38:59 +0900
+
+expedite (0.6.0+svn.49170slp2+1) unstable; urgency=low
+
+ * Git initialized.
+ * Git: 165.213.180.234:/git/slp2.0/slp2.0-pkgs/EFL-pkgs/expedite
+ * Tag: expedite_0.6.0+svn.49170slp2+1
+
+ -- Daniel Juyung Seo <juyung.seo@samsung.com> Sat, 19 Jun 2010 14:20:01 +0900
+
+expedite (0.6.0-svn.49170slp2) unstable; urgency=low
+
+ * Version changes.
+
+ -- Daniel Juyung Seo <juyung.seo@samsung.com> Tue, 15 Jun 2010 19:02:52 +0900
+
+expedite (0.6.0+svn.49170slp2) unstable; urgency=low
+
+ * Version changes.
+
+ -- Daniel Juyung Seo <juyung.seo@samsung.com> Tue, 15 Jun 2010 14:11:49 +0900
+
+expedite (0.6.0+svn.49170slp2+3build01) unstable; urgency=low
+
+ * EFL Update. (Revision 49170)
+
+ -- Daniel Juyung Seo <juyung.seo@samsung.com> Tue, 15 Jun 2010 10:18:37 +0900
+
+expedite (0.6.0+svn20100304slp2) unstable; urgency=low
+
+ * change package version
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Thu, 25 Mar 2010 16:07:11 +0900
+
+expedite (0.6.0+svn20100304-1) unstable; urgency=low
+
+ * EFL_update_revision_46864
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Wed, 10 Mar 2010 16:06:41 +0900
+
+expedite (0.6.0+svn20100203-1) unstable; urgency=low
+
+ * Reversion for -1EFL+
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Thu, 04 Feb 2010 14:56:21 +0900
+
+expedite (0.6.0+svn20100203-1) unstable; urgency=low
+
+ * EFL_update_revision_45828
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Wed, 03 Feb 2010 16:39:26 +0900
+
+expedite (0.6.0+svn20100111-3) unstable; urgency=low
+
+ * reupload EFL i686
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Tue, 12 Jan 2010 17:36:06 +0900
+
+expedite (0.6.0+svn20100111-2) unstable; urgency=low
+
+ * reupload EFL
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Mon, 11 Jan 2010 22:17:37 +0900
+
+expedite (0.6.0+svn20100111-1) unstable; urgency=low
+
+ * update EFL revision 45026
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Mon, 11 Jan 2010 13:28:12 +0900
+
+expedite (0.6.0+svn20091229-1) unstable; urgency=low
+
+ * update EFL
+
+ -- Jaehwan Kim <jae.hwan.kim@samsung.com> Tue, 29 Dec 2009 14:27:08 +0900
+
+expedite (0.6.0+svn20091112-2) unstable; urgency=low
+
+ * svn stable version
+
+ -- sangho park <sangho.g.park@samsung.com> Thu, 19 Nov 2009 19:57:55 +0900
+
+expedite (0.6.0+svn20091112-1) unstable; urgency=low
+
+ * a SVN release.
+
+ -- sangho park <sangho.g.park@samsung.com> Fri, 13 Nov 2009 09:46:46 +0900
+
+expedite (0.6.0+svnYYYYMMDD-1) unstable; urgency=low
+
+ * a SVN release.
+
+ -- quaker <quaker66@gmail.com> Sat, 27 Dec 2008 14:48:46 +0100
--- /dev/null
+Source: expedite
+Section: x11
+Priority: optional
+Maintainer: Jaehwan Kim <jae.hwan.kim@samsung.com>, Juyung Seo <juyung.seo@samsung.com>, Myoungwoon Kim <myoungwoon.kim@samsung.com>, Jeonghyun Yun <jh0506.yun@samsung.com>
+Original-Maintainer: Debian Pkg-e Team <pkg-e-devel@lists.alioth.debian.org>
+Uploaders: quaker <quaker66@gmail.com>
+Build-Depends: cdbs, debhelper (>= 6), libevas-dev, pkg-config, libtool, libxext-dev, libxrender-dev
+Standards-Version: 3.8.1
+Homepage: http://www.enlightenment.org
+
+Package: expedite
+Architecture: any
+Depends: ${shlibs:Depends}, libevas, libevas-engines, libevas-engines-extras, libxrender1
+Description: Benchmarking suite for Evas
+ This is meant to be a detailed and comprehensive benchmark suite for Evas.
+
--- /dev/null
+This package was debianized by quaker <quaker66@gmail.com> on
+Sat, 27 Dec 2008 14:48:46 +0100.
+
+Author(s):
+ The Rasterman (Carsten Haitzler) <raster@rasterman.com>
+ Tim Horton <hortont424@gmail.com>
+
+License:
+ See the COPYING file
+
--- /dev/null
+#!/usr/bin/make -f
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/autotools.mk
+
+DEB_CONFIGURE_SCRIPT := ./autogen.sh
+DEB_MAKE_CLEAN_TARGET := distclean
+DEB_CONFIGURE_EXTRA_FLAGS := --with-eet-eet=eet --disable-xrender-x11 --disable-software-sdl
+
+CFLAGS += -fPIC
+LDFLAGS += -Wl,--hash-style=both -Wl,--as-needed
+
+clean::
+ [ ! -f Makefile ] || make distclean
--- /dev/null
+<manifest>
+ <request>
+ <domain name="_"/>
+ </request>
+</manifest>
--- /dev/null
+# Note that this is NOT a relocatable package
+%define _missing_doc_files_terminate_build 0
+%{!?_rel:%{expand:%%global _rel 0.enl%{?dist}}}
+
+%define ver @VERSION@
+%define rel %{_rel}
+%define prefix /usr
+
+Summary: expedite
+Name: expedite
+Version: %ver
+Release: %rel
+License: BSD
+Group: System Environment/Desktops
+Source: ftp://ftp.enlightenment.org/pub/enlightenment/expedite-%{ver}.tar.gz
+BuildRoot: /var/tmp/expedite-root
+Packager: The Rasterman <raster@rasterman.com>
+URL: http://www.enlightenment.org/
+BuildRequires: evas-devel
+Requires: evas
+
+%description
+
+Expedite Evas benchmark/test suite
+
+%prep
+rm -rf $RPM_BUILD_ROOT
+
+%setup -q
+
+%build
+./configure --prefix=%prefix
+
+if [ "$SMP" != "" ]; then
+ (make "MAKE=make -k -j $SMP"; exit 0)
+ make
+else
+ make
+fi
+###########################################################################
+
+%install
+make DESTDIR=$RPM_BUILD_ROOT install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post
+
+%postun
+
+%files
+%defattr(-,root,root)
+%attr(755,root,root) %{prefix}/bin/*
+%attr(755,root,root) %{prefix}/share/expedite
+%doc AUTHORS
+%doc COPYING
+%doc COPYING-PLAIN
+%doc README
+
+%changelog
+* Sat Jun 23 2001 The Rasterman <raster@rasterman.com>
+- Created spec file
--- /dev/null
+dnl Copyright (C) 2004-2008 Kim Woelders
+dnl Copyright (C) 2008 Vincent Torri <vtorri at univ-evry dot fr>
+dnl That code is public domain and can be freely used or copied.
+dnl Originally snatched from somewhere...
+
+dnl Macro for checking if the compiler supports __attribute__
+
+dnl Usage: AC_C___ATTRIBUTE__
+dnl call AC_DEFINE for HAVE___ATTRIBUTE__ and __UNUSED__
+dnl if the compiler supports __attribute__, HAVE___ATTRIBUTE__ is
+dnl defined to 1 and __UNUSED__ is defined to __attribute__((unused))
+dnl otherwise, HAVE___ATTRIBUTE__ is not defined and __UNUSED__ is
+dnl defined to nothing.
+
+AC_DEFUN([AC_C___ATTRIBUTE__],
+[
+
+AC_MSG_CHECKING([for __attribute__])
+
+AC_CACHE_VAL([ac_cv___attribute__],
+ [AC_TRY_COMPILE(
+ [
+#include <stdlib.h>
+
+int func(int x);
+int foo(int x __attribute__ ((unused)))
+{
+ exit(1);
+}
+ ],
+ [],
+ [ac_cv___attribute__="yes"],
+ [ac_cv___attribute__="no"]
+ )])
+
+AC_MSG_RESULT($ac_cv___attribute__)
+
+if test "x${ac_cv___attribute__}" = "xyes" ; then
+ AC_DEFINE([HAVE___ATTRIBUTE__], [1], [Define to 1 if your compiler has __attribute__])
+ AC_DEFINE([__UNUSED__], [__attribute__((unused))], [Macro declaring a function argument to be unused])
+ else
+ AC_DEFINE([__UNUSED__], [], [Macro declaring a function argument to be unused])
+fi
+
+])
+
+dnl End of ac_attribute.m4
AC_MSG_RESULT($want_[]DOWN)
if test "x$want_[]DOWN" = "xyes"; then
- PKG_CHECK_EXISTS([evas-$1],
+ PKG_CHECK_EXISTS([evas-$1 >= 1.0.0],
[
AC_DEFINE(HAVE_EVAS_[]UP, 1, [Evas $2 Engine Support])
have_[]DOWN="yes"
--- /dev/null
+Summary: expedite
+Name: expedite
+Version: 1.7.1+svn.76823slp2+build02
+Release: 1
+License: BSD
+Group: System Environment/Desktops
+Source: %{name}-%{version}.tar.gz
+Requires(post): /sbin/ldconfig
+Requires(postun): /sbin/ldconfig
+BuildRequires: eina-devel
+BuildRequires: evas-devel
+BuildRequires: libxrender-devel
+
+
+%description
+Expedite Evas benchmark/test suite
+
+
+%prep
+%setup -q
+
+
+%build
+%autogen --disable-static
+%configure --disable-static \
+ --with-eet-eet=eet --disable-xrender-x11 --disable-software-sdl
+make %{?jobs:-j%jobs}
+
+
+%install
+rm -rf %{buildroot}
+%make_install
+mkdir -p %{buildroot}/usr/share/license
+cp %{_builddir}/%{buildsubdir}/COPYING %{buildroot}/usr/share/license/%{name}
+
+
+%post -p /sbin/ldconfig
+
+
+%postun -p /sbin/ldconfig
+
+
+%files
+%defattr(-,root,root,-)
+/usr/bin/expedite*
+/usr/share/expedite
+%manifest %{name}.manifest
+/usr/share/license/%{name}
-DPACKAGE_BIN_DIR=\"$(bindir)\" \
-DPACKAGE_LIB_DIR=\"$(libdir)\" \
-DPACKAGE_DATA_DIR=\"$(datadir)/$(PACKAGE)\" \
+@EINA_CFLAGS@ \
@EVAS_CFLAGS@ \
@x_cflags@ \
@SDL_CFLAGS@ \
@DIRECTFB_CFLAGS@ \
-@XCB_CFLAGS@
+@XCB_CFLAGS@ \
+@EVIL_CFLAGS@
bin_PROGRAMS = expedite
+bin_SCRIPTS = expedite-cmp
expedite_SOURCES = \
main.c main.h \
ui.c ui.h \
about.c about.h \
tests.h \
+widgets_file_icons.c \
+widgets_file_icons_2.c \
+widgets_file_icons_2_grouped.c \
+widgets_file_icons_2_same.c \
+widgets_file_icons_2_same_grouped.c \
+widgets_file_icons_3.c \
+widgets_file_icons_4.c \
+widgets_list_1.c \
+widgets_list_1_grouped.c \
+widgets_list_2.c \
+widgets_list_2_grouped.c \
+widgets_list_3.c \
+widgets_list_3_grouped.c \
+widgets_list_4.c \
+widgets_list_4_grouped.c \
image_blend_unscaled.c \
+image_blend_solid_middle_unscaled.c \
+image_blend_fade_unscaled.c \
+image_blend_fade_pow2_unscaled.c \
image_blend_solid_unscaled.c \
+image_blend_solid_fade_unscaled.c \
+image_blend_solid_fade_pow2_unscaled.c \
image_blend_nearest_scaled.c \
image_blend_nearest_solid_scaled.c \
image_blend_smooth_scaled.c \
image_blend_smooth_solid_scaled.c \
+image_blend_nearest_same_scaled.c \
+image_blend_nearest_solid_same_scaled.c \
+image_blend_smooth_same_scaled.c \
+image_blend_smooth_solid_same_scaled.c \
image_blend_border.c \
+image_blend_solid_middle_border.c \
image_blend_solid_border.c \
image_blend_border_recolor.c \
+image_map_rotate.c \
+image_map_solid_rotate.c \
+image_map_nearest_rotate.c \
+image_map_nearest_solid_rotate.c \
+image_map_color_rotate.c \
+image_map_color_solid_rotate.c \
+image_map_color_nearest_rotate.c \
+image_map_color_nearest_solid_rotate.c \
+image_map_color_alpha_rotate.c \
+image_map_color_alpha_solid_rotate.c \
+image_map_color_alpha_nearest_rotate.c \
+image_map_color_alpha_nearest_solid_rotate.c \
+image_map_3d_1.c \
+image_map_3d_2.c \
+image_map_3d_3.c \
+image_map_3d_4.c \
+image_map_3d_5.c \
+image_map_3d_6.c \
+image_map_3d_flow.c \
image_quality_scale.c \
image_data_argb.c \
image_data_argb_alpha.c \
image_data_ycbcr601pl.c \
image_data_ycbcr601pl_wide_stride.c \
+image_data_ycbcr601pl_map_solid_rotate.c \
+image_data_ycbcr601pl_map_nearest_solid_rotate.c \
image_crossfade.c \
text_basic.c \
text_styles.c \
text_change.c \
textblock_basic.c \
textblock_intl.c \
+textblock_auto_align.c \
+textblock_text_append.c \
rect_blend.c \
+rect_blend_pow2.c \
rect_solid.c \
rect_blend_few.c \
+rect_blend_pow2_few.c \
rect_solid_few.c \
image_blend_occlude1_few.c \
image_blend_occlude2_few.c \
image_blend_occlude1_very_many.c \
image_blend_occlude2_very_many.c \
image_blend_occlude3_very_many.c \
-poly_blend.c
+poly_blend.c \
+proxy_image.c \
+proxy_text_fixed.c \
+proxy_text_random.c
+
+#image_mask.c \
+#image_mask_2.c \
+#image_mask_3.c \
+#image_mask_4.c \
+#image_mask_5.c \
+#image_mask_6.c \
+#image_mask_7.c \
+#image_mask_8.c \
+#image_mask_9.c \
+#image_mask_10.c \
+#image_mask_11.c \
+#image_mask_12.c \
+#image_mask_13.c \
+#image_mask_14.c \
+#image_mask_15.c \
+#filter_object_colors.c \
+#filter_object_colors_solid.c \
+#filter_object_sepia.c \
+#filter_object_sepia_solid.c \
+#filter_object_greyscale.c \
+#filter_object_greyscale_solid.c \
+#filter_object_invert.c \
+#filter_object_invert_solid.c \
+#filter_object_brightness.c \
+#filter_object_brightness_solid.c \
+#filter_object_blur.c \
+#filter_object_blur_solid.c
expedite_CFLAGS = @WIN32_CFLAGS@
-expedite_LDADD = @EVAS_LIBS@ @SDL_LIBS@ @x_libs@ @ddraw_libs@ @ddraw_16_libs@ @d3d_libs@ @wince_16_libs@ @glew_libs@ @DIRECTFB_LIBS@ @XCB_LIBS@ -lm
+expedite_CXXFLAGS = @EXPEDITE_CXXFLAGS@
+expedite_LDADD = @SDL_LIBS@ @x_libs@ @gdi_libs@ @ddraw_libs@ @d3d_libs@ @wince_16_libs@ @DIRECTFB_LIBS@ @XCB_LIBS@ @EVAS_LIBS@ @EINA_LIBS@ @EVIL_LIBS@ @gl_cocoa_libs@ -lm
expedite_LDFLAGS = @lt_enable_auto_import@
-if BUILD_SOFTWARE_X11
+if BUILD_SOFTWARE_XLIB
expedite_SOURCES += \
-engine_software_x11.c engine_software_x11.h
+engine_software_xlib.c engine_software_xlib.h
endif
if BUILD_XRENDER_X11
engine_software_xcb.c engine_software_xcb.h
endif
+if BUILD_XRENDER_XCB
+expedite_SOURCES += \
+engine_xrender_xcb.c engine_xrender_xcb.h
+endif
+
+if BUILD_SOFTWARE_GDI
+expedite_SOURCES += \
+engine_software_gdi.c engine_software_gdi.h
+endif
+
if BUILD_SOFTWARE_DDRAW
expedite_SOURCES += \
engine_software_ddraw.cpp engine_software_ddraw.h
engine_direct3d.cpp engine_direct3d.h
endif
-if BUILD_OPENGL_GLEW
+if BUILD_SDL
expedite_SOURCES += \
-engine_gl_glew.c engine_gl_glew.h
+engine_software_sdl.c engine_software_sdl.h
endif
-if BUILD_SOFTWARE_SDL
+if BUILD_OPENGL_SDL
expedite_SOURCES += \
-engine_software_sdl.c engine_software_sdl.h
+engine_gl_sdl.c engine_gl_sdl.h
+endif
+
+if BUILD_PSL1GHT
+expedite_SOURCES += \
+engine_psl1ght.c
endif
if BUILD_FB
engine_directfb.c engine_directfb.h
endif
-if BUILD_SOFTWARE_16_X11
+if BUILD_OPENGL_COCOA
expedite_SOURCES += \
-engine_software_16_x11.c engine_software_16_x11.h
+engine_gl_cocoa.m engine_gl_cocoa.h
endif
-if BUILD_SOFTWARE_16_DDRAW
+if BUILD_SOFTWARE_16_X11
expedite_SOURCES += \
-engine_software_16_ddraw.cpp engine_software_16_ddraw.h
+engine_software_16_x11.c engine_software_16_x11.h
endif
if BUILD_SOFTWARE_16_WINCE
expedite_SOURCES += \
-engine_software_16_wince.c engine_software_16_wince.h
+engine_software_16_wince.c engine_software_16_wince.h engine_software_16_wince.rc
endif
+.rc.lo:
+ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --tag=RC --mode=compile $(RC) $(RCFLAGS) $< -o $@
+
+EXTRA_DIST = $(bin_SCRIPTS)
}
static void
-_loop(double t, int f)
+_loop(double t __UNUSED__, int f __UNUSED__)
{
}
static HWND window;
+static HINSTANCE instance;
static LRESULT CALLBACK
{
PRECT rect = (PRECT)lParam;
+ evas_output_viewport_set(evas, 0, 0,
+ rect->right - rect->left,
+ rect->bottom - rect->top);
evas_output_size_set(evas,
rect->right - rect->left,
rect->bottom - rect->top);
+ win_w = rect->right - rect->left;
+ win_h = rect->bottom - rect->top;
return 0;
}
case WM_RBUTTONDOWN:
}
}
-int
-engine_direct3d_args(int argc, char **argv)
+Eina_Bool
+engine_direct3d_args(const char *engine, int width, int height)
{
WNDCLASS wc;
RECT rect;
- HINSTANCE instance;
HDC dc;
MSG msg;
Evas_Engine_Info_Direct3D *einfo;
+ DWORD style;
int depth;
int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "direct3d")) ok = 1;
- }
- }
- if (!ok) return 0;
instance = GetModuleHandle(NULL);
- if (!instance) return 0;
+ if (!instance) return EINA_FALSE;
wc.style = 0;
wc.lpfnWndProc = MainWndProc;
rect.left = 0;
rect.top = 0;
- rect.right = win_w;
- rect.bottom = win_h;
+ rect.right = width;
+ rect.bottom = height;
AdjustWindowRect (&rect, WS_OVERLAPPEDWINDOW | WS_SIZEBOX, FALSE);
window = CreateWindowEx(0,
einfo = (Evas_Engine_Info_Direct3D *)evas_engine_info_get(evas);
if (!einfo)
{
- fprintf(stderr, "Evas does not support the Direct3D Engine\n");
+ fprintf(stderr, "Evas does not support the Direct3D Engine\n");
goto destroy_window;
}
einfo->info.window = window;
einfo->info.depth = depth;
einfo->info.rotation = 0;
- evas_engine_info_set(evas, (Evas_Engine_Info *)einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *)einfo))
+ {
+ printf("Evas can not setup the informations of the Direct3D Engine\n");
+ goto destroy_window;
+ }
/* the second parameter is ignored, as it's the first call of ShowWindow */
ShowWindow(window, SW_SHOWDEFAULT);
UpdateWindow(window);
- return 1;
+ return EINA_TRUE;
destroy_window:
DestroyWindow(window);
free_library:
FreeLibrary(instance);
- return 0;
+ return EINA_FALSE;
}
void
goto again;
}
+
+void
+engine_direct3d_shutdown(void)
+{
+ DestroyWindow(window);
+ UnregisterClass("Evas_Direct3D_Test", instance);
+ FreeLibrary(instance);
+}
#endif
-int engine_direct3d_args(int argc, char **argv);
+Eina_Bool engine_direct3d_args(const char *engine, int width, int height);
void engine_direct3d_loop(void);
+void engine_direct3d_shutdown(void);
#ifdef __cplusplus
static IDirectFBWindow *_dfb_window;
static IDirectFBSurface *_dfb_surface;
+#define DBG(...) do {} while (0)
+//#define DBG(...) fprintf(stderr, __VA_ARGS__)
+
#define DFBCHECK(x...) \
{ \
_err = x; \
} \
}
-int
-engine_directfb_args(int argc, char **argv)
+Eina_Bool
+engine_directfb_args(const char *engine, int width, int height)
{
Evas_Engine_Info_DirectFB *einfo;
DFBWindowDescription desc;
int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "directfb")) ok = 1;
- }
- }
- if (!ok) return 0;
evas_output_method_set(evas, evas_render_method_lookup("directfb"));
einfo = (Evas_Engine_Info_DirectFB *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the DirectFB Engine\n");
- return 0;
+ return EINA_FALSE;
}
DFBCHECK(DirectFBInit(NULL, NULL));
DFBCHECK(_dfb->CreateInputEventBuffer(_dfb, DICAPS_ALL, DFB_FALSE, &_input_event));
memset(&desc, 0, sizeof(DFBWindowDescription));
- desc.flags = (DWDESC_POSX | DWDESC_POSY | DWDESC_WIDTH | DWDESC_HEIGHT | DWDESC_CAPS);
+ desc.flags = (DWDESC_POSX | DWDESC_POSY | DWDESC_WIDTH | DWDESC_HEIGHT | DWDESC_PIXELFORMAT);
desc.posx = 0;
desc.posy = 0;
- desc.width = win_w;
- desc.height = win_h;
- desc.caps = DWCAPS_ALPHACHANNEL;
+ desc.width = width;
+ desc.height = height;
+ desc.pixelformat = DSPF_ARGB;
DFBCHECK(_layer->CreateWindow(_layer, &desc, &_dfb_window));
DFBCHECK(_dfb_window->AttachEventBuffer(_dfb_window, _window_event));
DFBCHECK(_dfb_window->SetOptions(_dfb_window, DWOP_NONE));
DFBCHECK(_dfb_window->SetOpacity(_dfb_window, 0xFF));
DFBCHECK(_dfb_window->GetSurface(_dfb_window, &_dfb_surface));
+ DFBCHECK(_dfb_surface->SetPorterDuff(_dfb_surface, DSPD_SRC_OVER));
einfo->info.dfb = _dfb;
einfo->info.surface = _dfb_surface;
- einfo->info.flags = DSDRAW_BLEND;
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the DirectFB Engine\n");
+ return EINA_FALSE;
+ }
- return 1;
+ return EINA_TRUE;
}
static void
static void
engine_directfb_event_window(const DFBWindowEvent *ev)
{
- fprintf(stderr, "===> Window Event (type=%#10x, window=%d) <===\n",
- ev->type, ev->window_id);
+ DBG("===> Window Event (type=%#10x, window=%d) <===\n",
+ ev->type, ev->window_id);
if (ev->type & DWET_POSITION)
{
- fprintf(stderr, "\tDWET_POSITION %d, %d\n", ev->x, ev->y);
+ DBG("\tDWET_POSITION %d, %d\n", ev->x, ev->y);
}
if (ev->type & DWET_SIZE)
{
- fprintf(stderr, "\tDWET_SIZE %dx%d\n", ev->w, ev->h);
- evas_output_size_set(evas, ev->w, ev->h);
+ DBG("\tDWET_SIZE %dx%d\n", ev->w, ev->h);
+ evas_output_viewport_set(evas, 0, 0,
+ ev->w, ev->h);
+ evas_output_size_set(evas, ev->w, ev->h);
+ win_w = ev->w;
+ win_h = ev->h;
}
if (ev->type & DWET_CLOSE)
{
- fprintf(stderr, "\tDWET_CLOSE\n");
+ DBG("\tDWET_CLOSE\n");
engine_directfb_quit();
}
if (ev->type & DWET_DESTROYED)
{
- fprintf(stderr, "\tDWET_DESTROYED\n");
+ DBG("\tDWET_DESTROYED\n");
engine_directfb_quit();
}
if (ev->type & DWET_GOTFOCUS)
{
- fprintf(stderr, "\tDWET_GOTFOCUS\n");
+ DBG("\tDWET_GOTFOCUS\n");
}
if (ev->type & DWET_LOSTFOCUS)
{
- fprintf(stderr, "\tDWET_LOSTFOCUS\n");
+ DBG("\tDWET_LOSTFOCUS\n");
}
if (ev->type & DWET_KEYDOWN)
const char *k;
k = key_string(ev->key_symbol);
- fprintf(stderr, "\tDWET_KEYDOWN key_symbol=%s\n", k);
+ DBG("\tDWET_KEYDOWN key_symbol=%s\n", k);
if (k)
evas_event_feed_key_down(evas, k, k, NULL, NULL, 0, NULL);
const char *k;
k = key_string(ev->key_symbol);
- fprintf(stderr, "\tDWET_KEYUP key_symbol=%s\n", k);
+ DBG("\tDWET_KEYUP key_symbol=%s\n", k);
if (k)
evas_event_feed_key_up(evas, k, k, NULL, NULL, 0, NULL);
if (ev->type & DWET_BUTTONDOWN)
{
- fprintf(stderr, "\tDWET_BUTTONDOWN pos=(%d, %d) cur_pos=(%d, %d) "
- "button=%#x buttons=%#x\n",
- ev->x, ev->y, ev->cx, ev->cy, ev->button, ev->buttons);
+ DBG("\tDWET_BUTTONDOWN pos=(%d, %d) cur_pos=(%d, %d) "
+ "button=%#x buttons=%#x\n",
+ ev->x, ev->y, ev->cx, ev->cy, ev->button, ev->buttons);
evas_event_feed_mouse_move(evas, ev->cx, ev->cy, 0, NULL);
evas_event_feed_mouse_down(evas, ev->button, EVAS_BUTTON_NONE, 0, NULL);
}
if (ev->type & DWET_BUTTONUP)
{
- fprintf(stderr, "\tDWET_BUTTONUP pos=(%d, %d) cur_pos=(%d, %d) "
- "button=%#x buttons=%#x\n",
- ev->x, ev->y, ev->cx, ev->cy, ev->button, ev->buttons);
+ DBG("\tDWET_BUTTONUP pos=(%d, %d) cur_pos=(%d, %d) "
+ "button=%#x buttons=%#x\n",
+ ev->x, ev->y, ev->cx, ev->cy, ev->button, ev->buttons);
evas_event_feed_mouse_move(evas, ev->cx, ev->cy, 0, NULL);
evas_event_feed_mouse_up(evas, ev->button, EVAS_BUTTON_NONE, 0, NULL);
}
if (ev->type & DWET_MOTION)
{
- fprintf(stderr, "\tDWET_MOTION pos=(%d, %d) cur_pos=(%d, %d) "
- "buttons=%#x\n",
- ev->x, ev->y, ev->cx, ev->cy, ev->buttons);
+ DBG("\tDWET_MOTION pos=(%d, %d) cur_pos=(%d, %d) buttons=%#x\n",
+ ev->x, ev->y, ev->cx, ev->cy, ev->buttons);
+ /* Mouse Motion Compression [tm] */
+ _layer->GetCursorPosition( _layer, (int*)&ev->x, (int*)&ev->y );
+
evas_event_feed_mouse_move(evas, ev->x, ev->y, 0, NULL);
}
if (ev->type & DWET_LEAVE)
{
- fprintf(stderr, "\tDWET_LEAVE pos=(%d, %d) cur_pos=(%d, %d)\n",
- ev->x, ev->y, ev->cx, ev->cy);
+ DBG("\tDWET_LEAVE pos=(%d, %d) cur_pos=(%d, %d)\n",
+ ev->x, ev->y, ev->cx, ev->cy);
evas_event_feed_mouse_out(evas, 0, NULL);
}
if (ev->type & DWET_ENTER)
{
- fprintf(stderr, "\tDWET_ENTER pos=(%d, %d) cur_pos=(%d, %d)\n",
- ev->x, ev->y, ev->cx, ev->cy);
+ DBG("\tDWET_ENTER pos=(%d, %d) cur_pos=(%d, %d)\n",
+ ev->x, ev->y, ev->cx, ev->cy);
evas_event_feed_mouse_in(evas, 0, NULL);
}
if (ev->type & DWET_WHEEL)
{
- fprintf(stderr, "\tDWET_WHEEL step=%d\n", ev->step);
+ DBG("\tDWET_WHEEL step=%d\n", ev->step);
}
- fprintf(stderr, "\n");
+ DBG("\n");
}
void
while ((_input_event->GetEvent(_input_event, &ev) == DFB_OK) ||
(_window_event->GetEvent(_window_event, &ev) == DFB_OK))
{
- fprintf(stderr, "got dfb input event %d\n", ev.clazz);
+ DBG("got dfb input event %d\n", ev.clazz);
switch (ev.clazz)
{
case DFEC_NONE:
- fprintf(stderr, "No event?\n");
+ DBG("No event?\n");
break;
case DFEC_INPUT:
- fprintf(stderr, "Input\n");
+ DBG("Input\n");
break;
case DFEC_WINDOW:
engine_directfb_event_window((const DFBWindowEvent *)&ev);
break;
case DFEC_USER:
- fprintf(stderr, "User\n");
+ DBG("User\n");
break;
case DFEC_UNIVERSAL:
- fprintf(stderr, "Universal\n");
+ DBG("Universal\n");
break;
}
}
}
+
+void
+engine_directfb_shutdown(void)
+{
+ DFBCHECK(_input_event->Release(_input_event));
+ DFBCHECK(_window_event->Release(_window_event));
+ DFBCHECK(_dfb_surface->Release(_dfb_surface));
+ DFBCHECK(_dfb_window->Release(_dfb_window));
+ DFBCHECK(_layer->Release(_layer));
+ DFBCHECK(_dfb->Release(_dfb));
+}
#ifndef ENGINE_DIRECTFB_H
#define ENGINE_DIRECTFB_H
-int engine_directfb_args(int argc, char **argv);
+Eina_Bool engine_directfb_args(const char *engine, int width, int height);
void engine_directfb_loop(void);
+void engine_directfb_shutdown(void);
#endif
#include <Evas_Engine_FB.h>
-int
-engine_fb_args(int argc, char **argv)
+Eina_Bool
+engine_fb_args(const char *engine __UNUSED__, int width __UNUSED__, int height __UNUSED__)
{
Evas_Engine_Info_FB *einfo;
- int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "fb")) ok = 1;
- }
- }
- if (!ok) return 0;
evas_output_method_set(evas, evas_render_method_lookup("fb"));
einfo = (Evas_Engine_Info_FB *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the FB Engine\n");
- return 0;
+ return EINA_FALSE;
}
einfo->info.virtual_terminal = 0;
einfo->info.device_number = 0;
einfo->info.refresh = 0;
einfo->info.rotation = 0;
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the FB Engine\n");
+ return EINA_FALSE;
+ }
- return 1;
+ return EINA_TRUE;
}
void
{
return;
}
+
+void
+engine_fb_shutdown(void)
+{
+ return;
+}
#ifndef ENGINE_FB_H
#define ENGINE_FB_H
-int engine_fb_args(int argc, char **argv);
+Eina_Bool engine_fb_args(const char *engine, int width, int height);
void engine_fb_loop(void);
+void engine_fb_shutdown(void);
#endif
--- /dev/null
+#ifndef ENGINE_GL_COCOA_H
+#define ENGINE_GL_COCOA_H
+
+int engine_gl_cocoa_args(int argc, char **argv);
+void engine_gl_cocoa_loop(void);
+void engine_gl_cocoa_shutdown(void);
+
+#endif
--- /dev/null
+/* NOTE: If you're using Expedite for performance testing,
+ set "Disable Beam Synchronization" in GL_Cocoa Debug. */
+
+#include "main.h"
+
+#include <Cocoa/Cocoa.h>
+#include <Evas_Engine_GL_Cocoa.h>
+
+static NSView * evas_view;
+static NSWindow * main_window;
+
+
+int
+engine_gl_cocoa_args(int argc, char **argv)
+{
+ Evas_Engine_Info_GL_Cocoa *einfo;
+ int i;
+ int ok = 0;
+
+ /*
+ for (i = 1; i < argc; i++)
+ {
+ if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
+ {
+ i++;
+ if (!strcmp(argv[i], "gl-cocoa")) ok = 1;
+ }
+ }
+ if (!ok) return 0;
+ */
+
+ evas_output_method_set(evas, evas_render_method_lookup("gl_cocoa"));
+ einfo = (Evas_Engine_Info_GL_Cocoa *)evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ printf("Evas is a goat and can't run GL_COCOA ... or .... it's me the goat\n");
+ return 0;
+ }
+
+ // Set up the Cocoa runtime
+ [[NSAutoreleasePool alloc] init];
+ [NSApplication sharedApplication];
+
+ // Register ourselves as a full-fledged Cocoa app, instead of a NSUIElement.
+ // This gives benefits like window focus and a dock icon!
+ ProcessSerialNumber psn = { 0, kCurrentProcess };
+ TransformProcessType (&psn, kProcessTransformToForegroundApplication);
+
+ [NSApp finishLaunching];
+ // Create our main window, and embed an EvasGLView in it
+ main_window = [[NSWindow alloc] initWithContentRect:NSMakeRect(20,500,win_w,win_h) styleMask:(NSTitledWindowMask | NSClosableWindowMask | NSResizableWindowMask | NSMiniaturizableWindowMask) backing:NSBackingStoreBuffered defer:NO screen:nil];
+ [main_window makeKeyAndOrderFront:NSApp];
+ [main_window setTitle:@"Expedite"];
+ [main_window makeMainWindow];
+ [main_window setAcceptsMouseMovedEvents:YES];
+ [NSApp activateIgnoringOtherApps:YES];
+
+ evas_output_size_set(evas, win_w, win_h);
+ evas_output_viewport_set(evas, 0, 0, win_w, win_h);
+
+ einfo->window = main_window;
+
+ //einfo->info.context = [evas_view context];
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the GL_Cocoa Engine\n");
+ exit(-1);
+ }
+
+ evas_view = (NSView*)einfo->view;
+ [[main_window contentView] addSubview:evas_view];
+ [evas_view display];
+
+ evas_damage_rectangle_add(evas,0,0, win_w ,win_h);
+ return 1;
+}
+
+void
+engine_gl_cocoa_loop(void)
+{
+ NSDate *date = [NSDate dateWithTimeIntervalSinceNow:0.001];
+
+ NSEvent *event = [NSApp nextEventMatchingMask:NSAnyEventMask
+ untilDate:date
+ inMode:NSDefaultRunLoopMode
+ dequeue:YES];
+ [date release];
+
+ if (!event) return;
+
+ if([event type] == NSMouseMoved || [event type] == NSLeftMouseDragged || [event type] == NSRightMouseDragged)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+
+ // Also notify on entering or leaving the window
+ NSPoint mouseLoc = [[event window] convertBaseToScreen:[event locationInWindow]];
+
+ if(NSPointInRect(mouseLoc, [[event window] frame]))
+ evas_event_feed_mouse_in(evas, 0, NULL);
+ else
+ evas_event_feed_mouse_out(evas, 0, NULL);
+
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSLeftMouseDown)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_down(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSLeftMouseUp)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_up(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSRightMouseDown)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_down(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSRightMouseUp)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_up(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSKeyDown)
+ {
+ NSString * chars = [event charactersIgnoringModifiers];
+
+ switch([chars characterAtIndex:0])
+ {
+ case NSLeftArrowFunctionKey:
+ evas_event_feed_key_down(evas, "Left", "Left", NULL, NULL, 0, NULL);
+ break;
+ case NSRightArrowFunctionKey:
+ evas_event_feed_key_down(evas, "Right", "Right", NULL, NULL, 0, NULL);
+ break;
+ case NSEnterCharacter:
+ case NSCarriageReturnCharacter:
+ evas_event_feed_key_down(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ break;
+ case 's':
+ case '\e':
+ evas_event_feed_key_down(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ break;
+ case 'q':
+ evas_event_feed_key_down(evas, "q", "q", NULL, NULL, 0, NULL);
+ break;
+ }
+
+ [chars release];
+ }
+ else if([event type] == NSKeyUp)
+ {
+ NSString * chars = [event charactersIgnoringModifiers];
+
+ switch([chars characterAtIndex:0])
+ {
+ case NSLeftArrowFunctionKey:
+ evas_event_feed_key_up(evas, "Left", "Left", NULL, NULL, 0, NULL);
+ break;
+ case NSRightArrowFunctionKey:
+ evas_event_feed_key_up(evas, "Right", "Right", NULL, NULL, 0, NULL);
+ break;
+ case NSEnterCharacter:
+ case NSCarriageReturnCharacter:
+ evas_event_feed_key_up(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ break;
+ case '\e':
+ evas_event_feed_key_up(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ break;
+ case 'q':
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_event_feed_key_up(evas, "Q", "Q", NULL, NULL, 0, NULL);
+ else
+ evas_event_feed_key_up(evas, "q", "q", NULL, NULL, 0, NULL);
+ break;
+ }
+
+ [chars release];
+ }
+ else if([event type] == NSFlagsChanged)
+ {
+ int flags = [event modifierFlags];
+
+ // Turn special key flags on
+ if(flags & NSShiftKeyMask)
+ evas_key_modifier_on(evas, "Shift");
+ else if(flags & NSControlKeyMask)
+ evas_key_modifier_on(evas, "Control");
+ else if(flags & NSAlternateKeyMask)
+ evas_key_modifier_on(evas, "Alt");
+ else if(flags & NSCommandKeyMask)
+ evas_key_modifier_on(evas, "Super");
+ else if(flags & NSAlphaShiftKeyMask)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_key_lock_off(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ }
+
+ // Turn special key flags off
+ if(!(flags & NSShiftKeyMask))
+ evas_key_modifier_off(evas, "Shift");
+ else if(!(flags & NSControlKeyMask))
+ evas_key_modifier_off(evas, "Control");
+ else if(!(flags & NSAlternateKeyMask))
+ evas_key_modifier_off(evas, "Alt");
+ else if(!(flags & NSCommandKeyMask))
+ evas_key_modifier_off(evas, "Super");
+ }
+ else
+ {
+ [NSApp sendEvent:event];
+ }
+
+ [event release];
+ [NSAutoreleasePool release];
+}
+
+void
+engine_gl_cocoa_shutdown(void)
+{
+ /* If someone knows what to do here... */
+}
static HWND window;
+static HINSTANCE instance;
static LRESULT CALLBACK
MainWndProc(HWND hwnd,
case WM_SIZING:
{
PRECT rect = (PRECT)lParam;
-
+
+ evas_output_viewport_set(evas, 0, 0,
+ rect->right - rect->left,
+ rect->bottom - rect->top);
evas_output_size_set(evas,
rect->right - rect->left,
rect->bottom - rect->top);
+ win_w = rect->right - rect->left;
+ win_h = rect->bottom - rect->top;
return 0;
}
case WM_RBUTTONDOWN:
}
}
-int
-engine_gl_glew_args(int argc, char **argv)
+Eina_Bool
+engine_gl_glew_args(const char *engine, int width, int height)
{
WNDCLASS wc;
RECT rect;
- HINSTANCE hinstance;
HDC dc;
Evas_Engine_Info_GL_Glew *einfo;
+ DWORD style;
int depth;
int i;
- int ok = 0;
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "gl-glew")) ok = 1;
- }
- }
- if (!ok) return 0;
-
- hinstance = GetModuleHandle(NULL);
- if (!instance) return 0;
+ instance = GetModuleHandle(NULL);
+ if (!instance) return EINA_FALSE;
wc.style = 0;
wc.lpfnWndProc = MainWndProc;
wc.cbClsExtra = 0;
wc.cbWndExtra = 0;
- wc.hInstance = hinstance;
+ wc.hInstance = instance;
wc.hIcon = LoadIcon (NULL, IDI_APPLICATION);
wc.hCursor = LoadCursor (NULL, IDC_ARROW);
wc.hbrBackground = (HBRUSH)(1 + COLOR_BTNFACE);
rect.left = 0;
rect.top = 0;
- rect.right = win_w;
- rect.bottom = win_h;
+ rect.right = width;
+ rect.bottom = height;
AdjustWindowRect (&rect, WS_CLIPCHILDREN | WS_CLIPSIBLINGS | WS_OVERLAPPEDWINDOW | WS_SIZEBOX, FALSE);
window = CreateWindowEx(0,
WS_CLIPCHILDREN | WS_CLIPSIBLINGS | WS_OVERLAPPEDWINDOW | WS_SIZEBOX,
CW_USEDEFAULT, CW_USEDEFAULT,
rect.right - rect.left, rect.bottom - rect.top,
- NULL, NULL, hinstance, NULL);
+ NULL, NULL, instance, NULL);
if (!window)
goto unregister_class;
if (!SetWindowLong(window, GWL_STYLE, style))
goto unregister_class;
+ dc = GetDC(NULL);
+ if (!dc)
+ goto destroy_window;
+
+ depth = GetDeviceCaps(dc, BITSPIXEL);
+ ReleaseDC(NULL, dc);
+
evas_output_method_set(evas, evas_render_method_lookup("gl_glew"));
einfo = (Evas_Engine_Info_GL_Glew *)evas_engine_info_get(evas);
if (!einfo)
einfo->info.window = window;
einfo->info.depth = depth;
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the GL Glew Engine\n");
+ goto destroy_window;
+ }
/* the second parameter is ignored, as it's the first call of ShowWindow */
ShowWindow(window, SW_SHOWDEFAULT);
UpdateWindow(window);
- return 1;
+ return EINA_TRUE;
destroy_window:
DestroyWindow(window);
free_library:
FreeLibrary(instance);
- return 0;
+ return EINA_FALSE;
}
void
goto again;
}
+
+void
+engine_gl_glew_shutdown(void)
+{
+ DestroyWindow(window);
+ UnregisterClass("Evas_Software_Gdi_Test", instance);
+ FreeLibrary(instance);
+}
#define __ENGINE_GL_GLEW_H__
-int engine_gl_glew_args(int argc, char **argv);
+Eina_Bool engine_gl_glew_args(const char *engine, int width, int height);
void engine_gl_glew_loop(void);
+void engine_gl_glew_shutdown(void);
#endif /* __ENGINE_GL_GLEW_H__ */
--- /dev/null
+#include <assert.h>
+#include "main.h"
+
+#include <Evas_Engine_GL_SDL.h>
+
+Eina_Bool
+engine_gl_sdl_args(const char *engine, int width, int height)
+{
+ Evas_Engine_Info_GL_SDL *einfo;
+ int i;
+
+ evas_output_method_set(evas, evas_render_method_lookup("gl_sdl"));
+
+ einfo = (Evas_Engine_Info_GL_SDL *) evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ printf("Evas wasn't build with GL SDL backend.\n");
+ return EINA_FALSE;
+ }
+
+ /* the following is specific to the engine */
+ einfo->flags.fullscreen = fullscreen;
+ einfo->flags.noframe = 0;
+
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas could not initialize the GL SDL Engine\n");
+ return EINA_FALSE;
+ }
+
+ return EINA_TRUE;
+}
+
+void
+engine_gl_sdl_loop(void)
+{
+ SDL_Event event;
+
+ while(SDL_PollEvent(&event))
+ {
+ switch(event.type)
+ {
+ case SDL_MOUSEMOTION:
+ evas_event_feed_mouse_move(evas, event.motion.x, event.motion.y, 0, NULL);
+ break;
+ case SDL_MOUSEBUTTONDOWN:
+ evas_event_feed_mouse_move(evas, event.button.x, event.button.y, 0, NULL);
+ evas_event_feed_mouse_down(evas, event.button.button, EVAS_BUTTON_NONE, 0, NULL);
+ break;
+ case SDL_MOUSEBUTTONUP:
+ evas_event_feed_mouse_move(evas, event.button.x, event.button.y, 0, NULL);
+ evas_event_feed_mouse_up(evas, event.button.button, EVAS_BUTTON_NONE, 0, NULL);
+ break;
+ case SDL_VIDEORESIZE:
+ evas_output_viewport_set(evas, 0, 0,
+ event.resize.w, event.resize.w);
+ evas_output_size_set(evas, event.resize.w, event.resize.w);
+ evas_output_size_get(evas, &win_w, &win_h);
+ break;
+ case SDL_VIDEOEXPOSE:
+ evas_output_size_get(evas, &win_w, &win_h);
+ evas_damage_rectangle_add(evas, 0, 0, win_w, win_h);
+ break;
+ case SDL_KEYDOWN:
+ switch (event.key.keysym.sym)
+ {
+ case SDLK_LSHIFT:
+ case SDLK_RSHIFT:
+ evas_key_modifier_on(evas, "Shift");
+ break;
+ case SDLK_RCTRL:
+ case SDLK_LCTRL:
+ evas_key_modifier_on(evas, "Control");
+ break;
+ case SDLK_MENU:
+ case SDLK_RALT:
+ case SDLK_LALT:
+ evas_key_modifier_on(evas, "Alt");
+ break;
+ case SDLK_LSUPER:
+ case SDLK_RSUPER:
+ evas_key_modifier_on(evas, "Super");
+ break;
+ case SDLK_CAPSLOCK:
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_key_lock_off(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ break;
+ case SDLK_NUMLOCK:
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Num_Lock"))
+ evas_key_lock_off(evas, "Num_Lock");
+ else
+ evas_key_lock_on(evas, "Num_Lock");
+ break;
+ case SDLK_SCROLLOCK:
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Scroll_Lock"))
+ evas_key_lock_off(evas, "Scroll_Lock");
+ else
+ evas_key_lock_on(evas, "Scroll_Lock");
+ break;
+ case SDLK_s:
+ case SDLK_ESCAPE:
+ evas_event_feed_key_down(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ break;
+ case SDLK_KP_ENTER:
+ case SDLK_RETURN:
+ evas_event_feed_key_down(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ break;
+ case SDLK_LEFT: evas_event_feed_key_down(evas, "Left", "Left", NULL, NULL, 0, NULL); break;
+ case SDLK_RIGHT: evas_event_feed_key_down(evas, "Right", "Right", NULL, NULL, 0, NULL); break;
+ case SDLK_q:
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_event_feed_key_down(evas, "Q", "Q", NULL, NULL, 0, NULL);
+ else
+ evas_event_feed_key_down(evas, "q", "q", NULL, NULL, 0, NULL);
+ break;
+ default:
+ break;
+ }
+ break;
+ case SDL_KEYUP:
+ switch (event.key.keysym.sym)
+ {
+ case SDLK_LSHIFT:
+ case SDLK_RSHIFT:
+ evas_key_modifier_off(evas, "Shift");
+ break;
+ case SDLK_RCTRL:
+ case SDLK_LCTRL:
+ evas_key_modifier_off(evas, "Control");
+ break;
+ case SDLK_MENU:
+ case SDLK_RALT:
+ case SDLK_LALT:
+ evas_key_modifier_off(evas, "Alt");
+ break;
+ case SDLK_LSUPER:
+ case SDLK_RSUPER:
+ evas_key_modifier_off(evas, "Super");
+ break;
+ case SDLK_ESCAPE: evas_event_feed_key_up(evas, "Escape", "Escape", NULL, NULL, 0, NULL); break;
+ case SDLK_RETURN: evas_event_feed_key_up(evas, "Return", "Return", NULL, NULL, 0, NULL); break;
+ case SDLK_LEFT: evas_event_feed_key_up(evas, "Left", "Left", NULL, NULL, 0, NULL); break;
+ case SDLK_RIGHT: evas_event_feed_key_up(evas, "Right", "Right", NULL, NULL, 0, NULL); break;
+ case SDLK_q:
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_event_feed_key_up(evas, "Q", "Q", NULL, NULL, 0, NULL);
+ else
+ evas_event_feed_key_up(evas, "q", "q", NULL, NULL, 0, NULL);
+ break;
+ default:
+ break;
+ }
+ break;
+ case SDL_QUIT:
+ case SDL_SYSWMEVENT:
+ case SDL_USEREVENT:
+ case SDL_ACTIVEEVENT:
+ case SDL_JOYAXISMOTION:
+ case SDL_JOYBALLMOTION:
+ case SDL_JOYHATMOTION:
+ case SDL_JOYBUTTONDOWN:
+ case SDL_JOYBUTTONUP:
+ default:
+ break;
+ }
+ }
+}
+
+void
+engine_gl_sdl_shutdown(void)
+{
+}
--- /dev/null
+#ifndef ENGINE_GL_SDL_H
+#define ENGINE_GL_SDL_H
+
+Eina_Bool engine_gl_sdl_args(const char *engine, int width, int height);
+void engine_gl_sdl_loop(void);
+void engine_gl_sdl_shutdown(void);
+
+#endif
#include "main.h"
#include <X11/Xlib.h>
+#include <X11/XKBlib.h>
#include <X11/Xutil.h>
+#include <X11/Xatom.h>
#include <Evas_Engine_GL_X11.h>
static Display *disp = NULL;
static Window win = 0;
+static int first_expose = 0;
-int
-engine_gl_x11_args(int argc, char **argv)
+Eina_Bool
+engine_gl_x11_args(const char *engine __UNUSED__, int width, int height)
{
XSetWindowAttributes attr;
XClassHint chint;
XSizeHints szhints;
Evas_Engine_Info_GL_X11 *einfo;
- int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "gl")) ok = 1;
- }
- }
- if (!ok) return 0;
disp = XOpenDisplay(NULL);
- if (!disp) return 0;
+ if (!disp) return EINA_FALSE;
evas_output_method_set(evas, evas_render_method_lookup("gl_x11"));
einfo = (Evas_Engine_Info_GL_X11 *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the OpenGL X11 Engine\n");
- return 0;
+ goto close_display;
}
einfo->info.display = disp;
- einfo->info.visual = einfo->func.best_visual_get(disp, DefaultScreen(disp));
- einfo->info.colormap = einfo->func.best_colormap_get(disp, DefaultScreen(disp));
- einfo->info.depth = einfo->func.best_depth_get(disp, DefaultScreen(disp));
+ einfo->info.screen = DefaultScreen(einfo->info.display);
+ einfo->info.visual = einfo->func.best_visual_get(einfo);
+ einfo->info.colormap = einfo->func.best_colormap_get(einfo);
+ einfo->info.depth = einfo->func.best_depth_get(einfo);
attr.backing_store = NotUseful;
attr.colormap = einfo->info.colormap;
attr.border_pixel = 0;
KeyPressMask | KeyReleaseMask;
attr.bit_gravity = ForgetGravity;
win = XCreateWindow(disp, DefaultRootWindow(disp),
- 0, 0, win_w, win_h, 0,
+ 0, 0, width, height, 0,
einfo->info.depth, InputOutput,
einfo->info.visual,
CWBackingStore | CWColormap |
CWBackPixmap | CWBorderPixel |
CWBitGravity | CWEventMask,
&attr);
+ if (!win)
+ goto close_display;
+
einfo->info.drawable = win;
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the OpenGL X11 Engine\n");
+ goto destroy_window;
+ }
+ if (fullscreen)
+ {
+ Atom prop = XInternAtom(disp, "_NET_WM_STATE", False);
+ Atom state = XInternAtom(disp, "_NET_WM_STATE_FULLSCREEN", False);
+ unsigned long data = state;
+ XChangeProperty(disp, win, prop, XA_ATOM, 32, PropModeReplace,
+ (unsigned char*) &data, 1);
+ }
+
XStoreName(disp, win, "Expedite - Evas Test Suite");
chint.res_name = "expedite";
chint.res_class = "Expedite";
XSetClassHint(disp, win, &chint);
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
- szhints.min_width = szhints.max_width = win_w;
- szhints.min_height = szhints.max_height = win_h;
+ szhints.min_width = szhints.max_width = width;
+ szhints.min_height = szhints.max_height = height;
XSetWMNormalHints(disp, win, &szhints);
XMapWindow(disp, win);
XSync(disp, False);
- return 1;
+ while (!first_expose)
+ engine_gl_x11_loop();
+ return EINA_TRUE;
+
+ destroy_window:
+ XDestroyWindow(disp, win);
+ close_display:
+ XCloseDisplay(disp);
+
+ return EINA_FALSE;
}
void
evas_event_feed_mouse_move(evas, ev.xmotion.x, ev.xmotion.y, 0, NULL);
break;
case Expose:
+ first_expose = 1;
evas_damage_rectangle_add(evas,
ev.xexpose.x,
ev.xexpose.y,
ev.xexpose.height);
break;
case ConfigureNotify:
+ evas_output_viewport_set(evas, 0, 0,
+ ev.xconfigure.width,
+ ev.xconfigure.height);
evas_output_size_set(evas,
ev.xconfigure.width,
ev.xconfigure.height);
+ win_w = ev.xconfigure.width;
+ win_h = ev.xconfigure.height;
break;
case EnterNotify:
evas_event_feed_mouse_in(evas, 0, NULL);
evas_event_feed_mouse_out(evas, 0, NULL);
break;
case KeyPress:
- ks = XKeycodeToKeysym(ev.xkey.display, ev.xkey.keycode, 0);
+ ks = XkbKeycodeToKeysym(ev.xkey.display, ev.xkey.keycode, 0, 0);
kstr = XKeysymToString(ks);
if (kstr)
{
}
break;
case KeyRelease:
- ks = XKeycodeToKeysym(ev.xkey.display, ev.xkey.keycode, 0);
+ ks = XkbKeycodeToKeysym(ev.xkey.display, ev.xkey.keycode, 0, 0);
kstr = XKeysymToString(ks);
if (kstr)
{
}
goto again;
}
+
+void
+engine_gl_x11_shutdown(void)
+{
+ XDestroyWindow(disp, win);
+ XCloseDisplay(disp);
+}
#ifndef ENGINE_GL_X11_H
#define ENGINE_GL_X11_H
-int engine_gl_x11_args(int argc, char **argv);
+Eina_Bool engine_gl_x11_args(const char *engine, int width, int height);
void engine_gl_x11_loop(void);
+void engine_gl_x11_shutdown(void);
#endif
--- /dev/null
+#include "main.h"
+
+#include <Evas_Engine_PSL1GHT.h>
+#include <io/mouse.h>
+#include <io/kb.h>
+
+static int window_width = 0;
+static int window_height = 0;
+
+Eina_Bool
+engine_psl1ght_args(const char *engine, int width, int height)
+{
+ Evas_Engine_Info_PSL1GHT *einfo;
+
+ evas_output_method_set(evas, evas_render_method_lookup("psl1ght"));
+ einfo = (Evas_Engine_Info_PSL1GHT *)evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ printf("Evas does not support the PSL1GHT Engine\n");
+ return EINA_FALSE;
+ }
+
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *)einfo))
+ {
+ printf("Evas can not setup the informations of the PSL1GHT Engine\n");
+ return EINA_FALSE;
+ }
+
+ window_width = width;
+ window_height = height;
+ ioMouseInit(1);
+ ioKbInit(1);
+ return EINA_TRUE;
+}
+
+void
+engine_psl1ght_loop(void)
+{
+ mouseInfo mouseinfo;
+ static int mouse_connected = FALSE;
+ static u8 mouse_buttons = 0;
+ static int mouse_x = 0;
+ static int mouse_y = 0;
+ KbInfo kbInfo;
+ static int keyboard_connected = FALSE;
+ static KbLed keyboard_leds = {{0}};
+ static KbMkey keyboard_mods = {{0}};
+ static u16 keyboard_old_key = 0;
+ int i;
+
+ /* Check mouse events */
+ ioMouseGetInfo(&mouseinfo);
+
+ if (mouseinfo.status[0] == 1 && !mouse_connected) // Connected
+ {
+ mouse_connected = TRUE;
+ mouse_buttons = 0;
+
+ // Old events in the queue are discarded
+ ioMouseClearBuf(0);
+ }
+ else if (mouseinfo.status[0] != 1 && mouse_connected) // Disconnected
+ {
+ mouse_connected = FALSE;
+ mouse_buttons = 0;
+ }
+
+ if (mouse_connected)
+ {
+ mouseDataList datalist;
+
+ ioMouseGetDataList(0, &datalist);
+
+ for (i = 0; i < datalist.count; i++) {
+ u8 old_left = mouse_buttons & 1;
+ u8 new_left = datalist.list[i].buttons & 1;
+ u8 old_right = mouse_buttons & 2;
+ u8 new_right = datalist.list[i].buttons & 2;
+ u8 old_middle = mouse_buttons & 4;
+ u8 new_middle = datalist.list[i].buttons & 4;
+
+ mouse_x += datalist.list[i].x_axis;
+ mouse_y += datalist.list[i].y_axis;
+ if (mouse_x < 0) mouse_x = 0;
+ if (mouse_y < 0) mouse_y = 0;
+ if (mouse_x > window_width) mouse_x = window_width;
+ if (mouse_y > window_height) mouse_x = window_height;
+
+ evas_event_feed_mouse_move(evas, mouse_x, mouse_y, 0, NULL);
+
+ if (old_left != new_left)
+ {
+ if (new_left)
+ evas_event_feed_mouse_down(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+ else
+ evas_event_feed_mouse_up(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+ }
+ if (old_right != new_right)
+ {
+ if (new_right)
+ evas_event_feed_mouse_down(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ else
+ evas_event_feed_mouse_up(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ }
+ if (old_middle != new_middle)
+ {
+ if (new_middle)
+ evas_event_feed_mouse_down(evas, 2, EVAS_BUTTON_NONE, 0, NULL);
+ else
+ evas_event_feed_mouse_up(evas, 2, EVAS_BUTTON_NONE, 0, NULL);
+ }
+ mouse_buttons = datalist.list[i].buttons;
+ }
+ }
+
+ /* Check keyboard events */
+ ioKbGetInfo(&kbInfo);
+
+ if (kbInfo.status[0] == 1 && !keyboard_connected)
+ {
+ /* Connected */
+ keyboard_connected = true;
+
+ // Old events in the queue are discarded
+ ioKbClearBuf(0);
+ keyboard_leds._KbLedU.leds = 0;
+ keyboard_mods._KbMkeyU.mkeys = 0;
+ keyboard_old_key = 0;
+
+ // Set raw keyboard code types to get scan codes
+ ioKbSetCodeType(0, KB_CODETYPE_ASCII);
+ ioKbSetReadMode(0, KB_RMODE_INPUTCHAR);
+ }
+ else if (kbInfo.status[0] != 1 && keyboard_connected)
+ {
+ /* Disconnected keyboard */
+ keyboard_connected = FALSE;
+ }
+
+ if (keyboard_connected)
+ {
+ KbData Keys;
+
+ // Read data from the keyboard buffer
+ if (ioKbRead(0, &Keys) == 0 && Keys.nb_keycode > 0)
+ {
+ if (Keys.mkey._KbMkeyU._KbMkeyS.l_shift !=
+ keyboard_mods._KbMkeyU._KbMkeyS.l_shift ||
+ Keys.mkey._KbMkeyU._KbMkeyS.r_shift !=
+ keyboard_mods._KbMkeyU._KbMkeyS.r_shift)
+ {
+ if (Keys.mkey._KbMkeyU._KbMkeyS.r_shift ||
+ Keys.mkey._KbMkeyU._KbMkeyS.l_shift)
+ evas_key_modifier_on(evas, "Shift");
+ else
+ evas_key_modifier_off(evas, "Shift");
+ }
+ if (Keys.mkey._KbMkeyU._KbMkeyS.l_ctrl !=
+ keyboard_mods._KbMkeyU._KbMkeyS.l_ctrl ||
+ Keys.mkey._KbMkeyU._KbMkeyS.r_ctrl !=
+ keyboard_mods._KbMkeyU._KbMkeyS.r_ctrl)
+ {
+ if (Keys.mkey._KbMkeyU._KbMkeyS.r_ctrl ||
+ Keys.mkey._KbMkeyU._KbMkeyS.l_ctrl)
+ evas_key_modifier_on(evas, "Control");
+ else
+ evas_key_modifier_off(evas, "Control");
+ }
+ if (Keys.mkey._KbMkeyU._KbMkeyS.l_alt !=
+ keyboard_mods._KbMkeyU._KbMkeyS.l_alt ||
+ Keys.mkey._KbMkeyU._KbMkeyS.r_alt !=
+ keyboard_mods._KbMkeyU._KbMkeyS.r_alt)
+ {
+ if (Keys.mkey._KbMkeyU._KbMkeyS.r_alt ||
+ Keys.mkey._KbMkeyU._KbMkeyS.l_alt)
+ evas_key_modifier_on(evas, "Alt");
+ else
+ evas_key_modifier_off(evas, "Alt");
+ }
+ if (Keys.mkey._KbMkeyU._KbMkeyS.l_win !=
+ keyboard_mods._KbMkeyU._KbMkeyS.l_win ||
+ Keys.mkey._KbMkeyU._KbMkeyS.r_win !=
+ keyboard_mods._KbMkeyU._KbMkeyS.r_win)
+ {
+ if (Keys.mkey._KbMkeyU._KbMkeyS.r_win ||
+ Keys.mkey._KbMkeyU._KbMkeyS.l_win)
+ evas_key_modifier_on(evas, "Super");
+ else
+ evas_key_modifier_off(evas, "Super");
+ }
+ keyboard_mods = Keys.mkey;
+
+ if (Keys.led._KbLedU._KbLedS.num_lock !=
+ keyboard_leds._KbLedU._KbLedS.num_lock)
+ {
+ if (Keys.led._KbLedU._KbLedS.num_lock)
+ evas_key_lock_on(evas, "Num_Lock");
+ else
+ evas_key_lock_on(evas, "Num_Lock");
+ }
+ if (Keys.led._KbLedU._KbLedS.caps_lock !=
+ keyboard_leds._KbLedU._KbLedS.caps_lock)
+ {
+ if (Keys.led._KbLedU._KbLedS.caps_lock)
+ evas_key_lock_on(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ }
+ if (Keys.led._KbLedU._KbLedS.scroll_lock !=
+ keyboard_leds._KbLedU._KbLedS.scroll_lock)
+ {
+ if (Keys.led._KbLedU._KbLedS.scroll_lock)
+ evas_key_lock_on(evas, "Scroll_Lock");
+ else
+ evas_key_lock_on(evas, "Scroll_Lock");
+ }
+ keyboard_leds = Keys.led;
+
+ for (i = 0; i < Keys.nb_keycode; i++) {
+ if (Keys.keycode[i] != keyboard_old_key)
+ {
+ u16 key = Keys.keycode[i];
+ char *key_str = NULL;
+
+ if (key == 0)
+ key = keyboard_old_key;
+ key_str = (char *)&key;
+
+ printf ("Key %d is %X\n", i, key);
+ key &= ~KB_KEYPAD;
+ if (key & KB_RAWDAT)
+ {
+ key &= 0xFF;
+ if (key == KB_RAWKEY_ESCAPE)
+ key_str = "Escape";
+ else if (key == KB_RAWKEY_ENTER)
+ key_str = "Return";
+ else if (key == KB_RAWKEY_UP_ARROW)
+ key_str = "Up";
+ else if (key == KB_RAWKEY_DOWN_ARROW)
+ key_str = "Down";
+ else if (key == KB_RAWKEY_LEFT_ARROW)
+ key_str = "Left";
+ else if (key == KB_RAWKEY_RIGHT_ARROW)
+ key_str = "Right";
+ else
+ key_str = NULL;
+ }
+ else {
+ if (key == 0x0A)
+ key_str = "Return";
+ else {
+ key_str[0] = key_str[1];
+ key_str[1] = 0;
+ }
+ }
+ if (key_str)
+ {
+ if (Keys.keycode[i] != 0)
+ {
+ printf ("Key %s pressed\n", key_str);
+ evas_event_feed_key_up(evas, key_str, key_str, NULL, NULL, 0, NULL);
+ }
+ else {
+ evas_event_feed_key_down(evas, key_str, key_str, NULL, NULL, 0, NULL);
+ printf ("Key %s released\n", key_str);
+ }
+ }
+ keyboard_old_key = Keys.keycode[0];
+ }
+ }
+ }
+ }
+ return;
+}
+
+void
+engine_psl1ght_shutdown(void)
+{
+ ioMouseEnd();
+ ioKbEnd();
+ return;
+}
+
--- /dev/null
+#ifndef ENGINE_SOFTWARE_PSL1GHT_H
+#define ENGINE_SOFTWARE_PSL1GHT_H
+
+Eina_Bool engine_psl1ght_args(const char *engine, int width, int height);
+void engine_psl1ght_loop(void);
+void engine_psl1ght_shutdown(void);
+
+#endif
--- /dev/null
+#ifndef ENGINE_QUARTZ_H
+#define ENGINE_QUARTZ_H
+
+Eina_Bool engine_quartz_args(const char *engine, int width, int height);
+void engine_quartz_loop(void);
+void engine_quartz_shutdown(void);
+
+#endif
--- /dev/null
+/* NOTE: If you're using Expedite for performance testing,
+ set "Disable Beam Synchronization" in Quartz Debug. */
+
+#include "main.h"
+
+#include <Cocoa/Cocoa.h>
+#include <Evas_Engine_Quartz.h>
+
+@interface EvasView : NSView
+{
+ CGContextRef ctx;
+}
+@end
+
+static EvasView * evas_view;
+static NSWindow * main_window;
+
+@implementation EvasView
+
+- (id) init
+{
+ self = [super init];
+ if (self != nil)
+ {
+ ctx = NULL;
+ }
+ return self;
+}
+
+- (void)drawRect:(NSRect)rect
+{
+ if(ctx != NULL)
+ {
+ evas_damage_rectangle_add(evas, 0, 0, win_w, win_h);
+ return;
+ }
+
+ ctx = [[NSGraphicsContext currentContext] graphicsPort];
+ CGContextRetain(ctx);
+}
+
+- (CGContextRef)context
+{
+ return ctx;
+}
+
+@end
+
+Eina_Bool
+engine_quartz_args(const char *engine, int width, int height)
+{
+ Evas_Engine_Info_Quartz *einfo;
+ int i;
+
+ evas_output_method_set(evas, evas_render_method_lookup("quartz"));
+ einfo = (Evas_Engine_Info_Quartz *)evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ printf("Evas does not support the Quartz Engine\n");
+ return EINA_FALSE;
+ }
+
+ // Set up the Cocoa runtime
+ [[NSAutoreleasePool alloc] init];
+ [NSApplication sharedApplication];
+
+ // Register ourselves as a full-fledged Cocoa app, instead of a NSUIElement.
+ // This gives benefits like window focus and a dock icon!
+ ProcessSerialNumber psn = { 0, kCurrentProcess };
+ TransformProcessType (&psn, kProcessTransformToForegroundApplication);
+
+ [NSApp finishLaunching];
+
+ // Create our main window, and embed an EvasView in it
+ main_window = [[NSWindow alloc] initWithContentRect:NSMakeRect(20,500,width,height) styleMask:(NSTitledWindowMask | NSClosableWindowMask | NSResizableWindowMask | NSMiniaturizableWindowMask) backing:NSBackingStoreBuffered defer:NO screen:nil];
+ [main_window makeKeyAndOrderFront:NSApp];
+ [main_window setTitle:@"Expedite"];
+ [main_window makeMainWindow];
+ [main_window setAcceptsMouseMovedEvents:YES];
+ [NSApp activateIgnoringOtherApps:YES];
+
+ evas_view = [[EvasView alloc] initWithFrame:NSMakeRect(0,0,width,height)];
+ [[main_window contentView] addSubview:evas_view];
+
+ // drawRect: must be run at least once, to make sure we've set ctx
+ [evas_view display];
+
+ evas_output_size_set(evas, width, height);
+ evas_output_viewport_set(evas, 0, 0, width, height);
+
+ einfo->info.context = [evas_view context];
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the Quartz Engine\n");
+ return EINA_FALSE;
+ }
+
+ return EINA_TRUE;
+}
+
+void
+engine_quartz_loop(void)
+{
+ NSDate *date = [NSDate dateWithTimeIntervalSinceNow:0.001];
+
+ NSEvent *event = [NSApp nextEventMatchingMask:NSAnyEventMask
+ untilDate:date
+ inMode:NSDefaultRunLoopMode
+ dequeue:YES];
+ [date release];
+
+ if (!event) return;
+
+ if([event type] == NSMouseMoved || [event type] == NSLeftMouseDragged || [event type] == NSRightMouseDragged)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+
+ // Also notify on entering or leaving the window
+ NSPoint mouseLoc = [[event window] convertBaseToScreen:[event locationInWindow]];
+
+ if(NSPointInRect(mouseLoc, [[event window] frame]))
+ evas_event_feed_mouse_in(evas, 0, NULL);
+ else
+ evas_event_feed_mouse_out(evas, 0, NULL);
+
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSLeftMouseDown)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_down(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSLeftMouseUp)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_up(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSRightMouseDown)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_down(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSRightMouseUp)
+ {
+ evas_event_feed_mouse_move(evas, [event locationInWindow].x, [event locationInWindow].y, 0, NULL);
+ evas_event_feed_mouse_up(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ [NSApp sendEvent:event];
+ }
+ else if([event type] == NSKeyDown)
+ {
+ NSString * chars = [event charactersIgnoringModifiers];
+
+ switch([chars characterAtIndex:0])
+ {
+ case NSLeftArrowFunctionKey:
+ evas_event_feed_key_down(evas, "Left", "Left", NULL, NULL, 0, NULL);
+ break;
+ case NSRightArrowFunctionKey:
+ evas_event_feed_key_down(evas, "Right", "Right", NULL, NULL, 0, NULL);
+ break;
+ case NSEnterCharacter:
+ case NSCarriageReturnCharacter:
+ evas_event_feed_key_down(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ break;
+ case 's':
+ case '\e':
+ evas_event_feed_key_down(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ break;
+ case 'q':
+ evas_event_feed_key_down(evas, "q", "q", NULL, NULL, 0, NULL);
+ break;
+ }
+
+ [chars release];
+ }
+ else if([event type] == NSKeyUp)
+ {
+ NSString * chars = [event charactersIgnoringModifiers];
+
+ switch([chars characterAtIndex:0])
+ {
+ case NSLeftArrowFunctionKey:
+ evas_event_feed_key_up(evas, "Left", "Left", NULL, NULL, 0, NULL);
+ break;
+ case NSRightArrowFunctionKey:
+ evas_event_feed_key_up(evas, "Right", "Right", NULL, NULL, 0, NULL);
+ break;
+ case NSEnterCharacter:
+ case NSCarriageReturnCharacter:
+ evas_event_feed_key_up(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ break;
+ case '\e':
+ evas_event_feed_key_up(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ break;
+ case 'q':
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_event_feed_key_up(evas, "Q", "Q", NULL, NULL, 0, NULL);
+ else
+ evas_event_feed_key_up(evas, "q", "q", NULL, NULL, 0, NULL);
+ break;
+ }
+
+ [chars release];
+ }
+ else if([event type] == NSFlagsChanged)
+ {
+ int flags = [event modifierFlags];
+
+ // Turn special key flags on
+ if(flags & NSShiftKeyMask)
+ evas_key_modifier_on(evas, "Shift");
+ else if(flags & NSControlKeyMask)
+ evas_key_modifier_on(evas, "Control");
+ else if(flags & NSAlternateKeyMask)
+ evas_key_modifier_on(evas, "Alt");
+ else if(flags & NSCommandKeyMask)
+ evas_key_modifier_on(evas, "Super");
+ else if(flags & NSAlphaShiftKeyMask)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_key_lock_off(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ }
+
+ // Turn special key flags off
+ if(!(flags & NSShiftKeyMask))
+ evas_key_modifier_off(evas, "Shift");
+ else if(!(flags & NSControlKeyMask))
+ evas_key_modifier_off(evas, "Control");
+ else if(!(flags & NSAlternateKeyMask))
+ evas_key_modifier_off(evas, "Alt");
+ else if(!(flags & NSCommandKeyMask))
+ evas_key_modifier_off(evas, "Super");
+ }
+ else
+ {
+ [NSApp sendEvent:event];
+ }
+
+ [event release];
+ [NSAutoreleasePool release];
+}
+
+void
+engine_quartz_shutdown(void)
+{
+ /* If someone knows what to do here... */
+}
if (_resume)
_resume (backend);
return 0;
+ case WM_SIZE:
+ {
+ Evas_Engine_Info_Software_16_WinCE *einfo;
+
+ printf ("WM_SIZE %dx%d\n", LOWORD(lParam), HIWORD(lParam));
+ einfo = (Evas_Engine_Info_Software_16_WinCE *)evas_engine_info_get(evas);
+ if (!einfo)
+ return 0;
+
+ if (einfo->info.rotation != 0)
+ {
+ einfo->info.width = win_h;
+ einfo->info.height = win_w;
+ einfo->info.rotation = 90;
+ }
+ else
+ {
+ einfo->info.width = win_w;
+ einfo->info.height = win_h;
+ einfo->info.rotation = 0;
+ }
+
+ evas_engine_info_set(evas, (Evas_Engine_Info *)einfo);
+
+ return 0;
+ }
default:
return DefWindowProc(hwnd, uMsg, wParam, lParam);
}
}
-int
-engine_software_16_wince_args(int argc, char **argv)
+Eina_Bool
+engine_software_16_wince_args(const char *engine, int width, int height)
{
WNDCLASS wc;
RECT rect;
Evas_Engine_Info_Software_16_WinCE *einfo;
- int width;
- int height;
+ HWND task_bar;
+ HWND sip_window;
+ HWND sip_icon;
int stride_x;
int stride_y;
int bpp;
int ok = 0;
int i;
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "wince")) ok = 1;
- if (!strcmp(argv[i], "wince-fb")) { ok = 1; backend = 1; }
- if (!strcmp(argv[i], "wince-gapi")) { ok = 1; backend = 2; }
- if (!strcmp(argv[i], "wince-ddraw")) { ok = 1; backend = 3; }
- }
- }
- if (!ok) return 0;
+ if (!strcmp(engine, "wince")) ok = 1;
+ if (!strcmp(engine, "wince-fb")) { ok = 1; backend = 1; }
+ if (!strcmp(engine, "wince-gapi")) { ok = 1; backend = 2; }
+ if (!strcmp(engine, "wince-ddraw")) { ok = 1; backend = 3; }
+ if (!strcmp(engine, "wince-gdi")) { ok = 1; backend = 4; }
+ if (!ok) return EINA_FALSE;
instance = GetModuleHandle(NULL);
- if (!instance) return 0;
+ if (!instance) return EINA_FALSE;
memset (&wc, 0, sizeof (wc));
wc.style = CS_HREDRAW | CS_VREDRAW;
wc.lpszClassName = L"Evas_Software_16_WinCE_Test";
if(!RegisterClass(&wc))
- {
- FreeLibrary(instance);
- return 0;
- }
+ goto free_library;
SetRect(&rect, 0, 0,
GetSystemMetrics(SM_CXSCREEN),
rect.bottom - rect.top,
NULL, NULL, instance, NULL);
if (!window)
- {
- UnregisterClass(L"Evas_Software_16_WinCE_Test", instance);
- FreeLibrary(instance);
- return 0;
- }
-
- SHFullScreen(window,
- SHFS_HIDETASKBAR | SHFS_HIDESTARTICON | SHFS_HIDESIPBUTTON);
+ goto unregister_class;
+
+ /* hide top level windows (Task bar, SIP and SIP button */
+ task_bar = FindWindow(L"HHTaskBar", NULL);
+ ShowWindow(task_bar, SW_HIDE);
+ EnableWindow(task_bar, FALSE);
+ sip_window = FindWindow(L"SipWndClass", NULL);
+ ShowWindow(sip_window, SW_HIDE);
+ EnableWindow(sip_window, FALSE);
+ sip_icon = FindWindow(L"MS_SIPBUTTON", NULL);
+ ShowWindow(sip_icon, SW_HIDE);
+ EnableWindow(sip_icon, FALSE);
if (!_wince_hardware_keys_register(window))
- {
- DestroyWindow(window);
- UnregisterClass(L"Evas_Software_16_WinCE_Test", instance);
- FreeLibrary(instance);
- return 0;
- }
+ goto destroy_window;
evas_output_method_set(evas, evas_render_method_lookup("software_16_wince"));
+
einfo = (Evas_Engine_Info_Software_16_WinCE *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the 16bit Software WinCE Engine\n");
- DestroyWindow(window);
- UnregisterClass(L"Evas_Software_16_WinCE_Test", instance);
- FreeLibrary(instance);
- return 0;
+ goto destroy_window;
}
einfo->info.window = window;
- einfo->info.width = win_w;
- einfo->info.height = win_h;
+ einfo->info.width = width;
+ einfo->info.height = height;
einfo->info.backend = backend;
einfo->info.rotation = 0;
- evas_engine_info_set(evas, (Evas_Engine_Info *)einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the 16 bits Software WinCE Engine\n");
+ goto destroy_window;
+ }
_suspend = einfo->func.suspend;
_resume = einfo->func.resume;
ShowWindow(window, SW_SHOWDEFAULT);
UpdateWindow(window);
- return 1;
+ return EINA_TRUE;
+
+ destroy_window:
+ DestroyWindow(window);
+ ShowWindow(task_bar, SW_SHOW);
+ EnableWindow(task_bar, TRUE);
+ ShowWindow(sip_window, SW_SHOW);
+ EnableWindow(sip_window, TRUE);
+ ShowWindow(sip_icon, SW_SHOW);
+ EnableWindow(sip_icon, TRUE);
+ unregister_class:
+ UnregisterClass(L"Evas_Software_16_WinCE_Test", instance);
+ free_library:
+ FreeLibrary(instance);
+
+ return EINA_FALSE;
}
void
goto again;
}
+
+void
+engine_software_16_wince_shutdown(void)
+{
+ HWND task_bar;
+ HWND sip_window;
+ HWND sip_icon;
+
+ DestroyWindow(window);
+
+ /* show top level windows (Task bar, SIP and SIP button */
+ task_bar = FindWindow(L"HHTaskBar", NULL);
+ ShowWindow(task_bar, SW_SHOW);
+ EnableWindow(task_bar, TRUE);
+ sip_window = FindWindow(L"SipWndClass", NULL);
+ ShowWindow(sip_window, SW_SHOW);
+ EnableWindow(sip_window, TRUE);
+ sip_icon = FindWindow(L"MS_SIPBUTTON", NULL);
+ ShowWindow(sip_icon, SW_SHOW);
+ EnableWindow(sip_icon, TRUE);
+
+ UnregisterClass(L"Evas_Software_16_WinCE_Test", instance);
+ FreeLibrary(instance);
+}
#define __ENGINE_SOFTWARE_16_WINCE_H__
-int engine_software_16_wince_args(int argc, char **argv);
+Eina_Bool engine_software_16_wince_args(const char *engine, int width, int height);
void engine_software_16_wince_loop(void);
+void engine_software_16_wince_shutdown(void);
#endif /* __ENGINE_SOFTWARE_16_WINCE_H__ */
--- /dev/null
+HI_RES_AWARE CEUX {1}
#include <X11/Xlib.h>
#include <X11/Xutil.h>
+#include <X11/Xatom.h>
#include <Evas_Engine_Software_16_X11.h>
static Display *disp = NULL;
static Window win = 0;
+static int first_expose = 0;
-int
-engine_software_16_x11_args(int argc, char **argv)
+Eina_Bool
+engine_software_16_x11_args(const char *engine, int width, int height)
{
XSetWindowAttributes attr;
XClassHint chint;
XSizeHints szhints;
Evas_Engine_Info_Software_16_X11 *einfo;
int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "x11-16")) ok = 1;
- }
- }
- if (!ok) return 0;
disp = XOpenDisplay(NULL);
- if (!disp) return 0;
+ if (!disp) return EINA_FALSE;
evas_output_method_set(evas, evas_render_method_lookup("software_16_x11"));
einfo = (Evas_Engine_Info_Software_16_X11 *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the Software 16bit X11 Engine\n");
- return 0;
+ goto close_display;
}
einfo->info.display = disp;
KeyPressMask | KeyReleaseMask;
attr.bit_gravity = ForgetGravity;
win = XCreateWindow(disp, DefaultRootWindow(disp),
- 0, 0, win_w, win_h, 0,
+ 0, 0, width, height, 0,
DefaultDepth(disp, DefaultScreen(disp)), InputOutput,
DefaultVisual(disp, DefaultScreen(disp)),
CWBackingStore | CWColormap |
CWBackPixmap | CWBorderPixel |
CWBitGravity | CWEventMask,
&attr);
+ if (!win)
+ goto close_display;
+
einfo->info.drawable = win;
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the Software 16bit X11 Engine\n");
+ goto destroy_window;
+ }
+ if (fullscreen)
+ {
+ Atom prop = XInternAtom(disp, "_NET_WM_STATE", False);
+ Atom state = XInternAtom(disp, "_NET_WM_STATE_FULLSCREEN", False);
+ unsigned long data = state;
+ XChangeProperty(disp, win, prop, XA_ATOM, 32, PropModeReplace,
+ (unsigned char*) &data, 1);
+ }
+
XStoreName(disp, win, "Expedite - Evas Test Suite");
chint.res_name = "expedite";
chint.res_class = "Expedite";
XSetClassHint(disp, win, &chint);
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
- szhints.min_width = szhints.max_width = win_w;
- szhints.min_height = szhints.max_height = win_h;
+ szhints.min_width = szhints.max_width = width;
+ szhints.min_height = szhints.max_height = height;
XSetWMNormalHints(disp, win, &szhints);
XMapWindow(disp, win);
XSync(disp, False);
- return 1;
+ while (!first_expose)
+ engine_software_16_x11_loop();
+ return EINA_TRUE;
+
+ destroy_window:
+ XDestroyWindow(disp, win);
+ close_display:
+ XCloseDisplay(disp);
+
+ return EINA_FALSE;
}
void
evas_event_feed_mouse_move(evas, ev.xmotion.x, ev.xmotion.y, 0, NULL);
break;
case Expose:
+ first_expose = 1;
evas_damage_rectangle_add(evas,
ev.xexpose.x,
ev.xexpose.y,
ev.xexpose.height);
break;
case ConfigureNotify:
+ evas_output_viewport_set(evas, 0, 0,
+ ev.xconfigure.width,
+ ev.xconfigure.height);
evas_output_size_set(evas,
ev.xconfigure.width,
ev.xconfigure.height);
+ win_w = ev.xconfigure.width;
+ win_h = ev.xconfigure.height;
break;
case EnterNotify:
evas_event_feed_mouse_in(evas, 0, NULL);
}
goto again;
}
+
+void
+engine_software_16_x11_shutdown(void)
+{
+ XDestroyWindow(disp, win);
+ XCloseDisplay(disp);
+}
#ifndef ENGINE_SOFTWARE_16_X11_H
#define ENGINE_SOFTWARE_16_X11_H
-int engine_software_16_x11_args(int argc, char **argv);
+Eina_Bool engine_software_16_x11_args(const char *engine, int width, int height);
void engine_software_16_x11_loop(void);
+void engine_software_16_x11_shutdown(void);
#endif
static HWND window;
+static HINSTANCE instance;
static LRESULT CALLBACK
{
PRECT rect = (PRECT)lParam;
+ evas_output_viewport_set(evas, 0, 0,
+ rect->right - rect->left,
+ rect->bottom - rect->top);
evas_output_size_set(evas,
rect->right - rect->left,
rect->bottom - rect->top);
+ win_w = rect->right - rect->left;
+ win_h = rect->bottom - rect->top;
return 0;
}
case WM_RBUTTONDOWN:
}
}
-int
-engine_software_ddraw_args(int argc, char **argv)
+Eina_Bool
+engine_software_ddraw_args(const char *engine, int width, int height)
{
WNDCLASS wc;
RECT rect;
- HINSTANCE instance;
HDC dc;
Evas_Engine_Info_Software_DDraw *einfo;
DWORD style;
DWORD exstyle;
int depth;
int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "ddraw")) ok = 1;
- }
- }
- if (!ok) return 0;
instance = GetModuleHandle(NULL);
if (!instance) return 0;
rect.left = 0;
rect.top = 0;
- rect.right = win_w;
- rect.bottom = win_h;
+ rect.right = width;
+ rect.bottom = height;
AdjustWindowRectEx (&rect, style, FALSE, exstyle);
window = CreateWindowEx(exstyle,
style = GetWindowLong(window, GWL_STYLE);
style &= ~WS_THICKFRAME;
if (!SetWindowLong(window, GWL_STYLE, style))
- goto unregister_class;
+ goto destroy_window;
dc = GetDC(NULL);
if (!dc)
einfo->info.window = window;
einfo->info.depth = depth;
einfo->info.rotation = 0;
- evas_engine_info_set(evas, (Evas_Engine_Info *)einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the Software DirectDraw Engine\n");
+ goto destroy_window;
+ }
/* the second parameter is ignored, as it's the first call of ShowWindow */
ShowWindow(window, SW_SHOWDEFAULT);
goto again;
}
+
+void
+engine_software_ddraw_shutdown(void)
+{
+ DestroyWindow(window);
+ UnregisterClass("Evas_Software_DDraw_Test", instance);
+ FreeLibrary(instance);
+}
extern "C" {
#endif
-
-int engine_software_ddraw_args(int argc, char **argv);
+Eina_Bool engine_software_ddraw_args(const char *engine, int width, int height);
void engine_software_ddraw_loop(void);
+void engine_software_ddraw_shutdown(void);
#ifdef __cplusplus
--- /dev/null
+#include "main.h"
+
+#include <windowsx.h>
+#include <Evas_Engine_Software_Gdi.h>
+
+
+static HWND window;
+static HINSTANCE instance;
+
+
+static LRESULT CALLBACK
+MainWndProc(HWND hwnd,
+ UINT uMsg,
+ WPARAM wParam,
+ LPARAM lParam)
+{
+ switch (uMsg)
+ {
+ case WM_CREATE:
+ return 0;
+ case WM_DESTROY:
+ PostQuitMessage(0);
+ return 0;
+ case WM_CLOSE:
+ PostQuitMessage(0);
+ return 0;
+ case WM_WINDOWPOSCHANGED: {
+ PAINTSTRUCT ps;
+ HDC hdc;
+
+ hdc = BeginPaint (window, &ps);
+ evas_damage_rectangle_add(evas,
+ ps.rcPaint.left, ps.rcPaint.top,
+ ps.rcPaint.right - ps.rcPaint.left,
+ ps.rcPaint.bottom - ps.rcPaint.top);
+ EndPaint(window, &ps);
+ return 0;
+ }
+ case WM_SIZING:
+ {
+ PRECT rect = (PRECT)lParam;
+
+ evas_output_viewport_set(evas, 0, 0,
+ rect->right - rect->left,
+ rect->bottom - rect->top);
+ evas_output_size_set(evas,
+ rect->right - rect->left,
+ rect->bottom - rect->top);
+ win_w = rect->right - rect->left;
+ win_h = rect->bottom - rect->top;
+ return 0;
+ }
+ case WM_RBUTTONDOWN:
+ evas_event_feed_mouse_move(evas, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam), 0, NULL);
+ evas_event_feed_mouse_down(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ return 0;
+ case WM_LBUTTONDOWN:
+ evas_event_feed_mouse_move(evas, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam), 0, NULL);
+ evas_event_feed_mouse_down(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+ return 0;
+ case WM_LBUTTONUP:
+ evas_event_feed_mouse_move(evas, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam), 0, NULL);
+ evas_event_feed_mouse_up(evas, 1, EVAS_BUTTON_NONE, 0, NULL);
+ return 0;
+ case WM_RBUTTONUP:
+ evas_event_feed_mouse_move(evas, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam), 0, NULL);
+ evas_event_feed_mouse_up(evas, 3, EVAS_BUTTON_NONE, 0, NULL);
+ return 0;
+ case WM_MOUSEMOVE:
+ if (!evas_pointer_inside_get(evas)) evas_event_feed_mouse_in(evas, 0, NULL);
+ evas_event_feed_mouse_move(evas, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam), 0, NULL);
+ return 0;
+ case WM_MOUSELEAVE:
+ evas_event_feed_mouse_out(evas, 0, NULL);
+ return 0;
+ /* FIXME : can't find an event when the mouse is entering */
+ case WM_KEYDOWN:
+ case WM_SYSKEYDOWN: {
+ int key;
+
+ key = LOWORD(wParam);
+
+ if ((key == VK_SHIFT) ||
+ (key == VK_LSHIFT) ||
+ (key == VK_RSHIFT))
+ evas_key_modifier_on(evas, "Shift");
+ if ((key == VK_CONTROL) ||
+ (key == VK_LCONTROL) ||
+ (key == VK_RCONTROL))
+ evas_key_modifier_on(evas, "Control");
+ if ((key == VK_MENU) ||
+ (key == VK_LMENU) ||
+ (key == VK_RMENU))
+ evas_key_modifier_on(evas, "Alt");
+ if ((key == VK_LWIN) ||
+ (key == VK_RWIN))
+ evas_key_modifier_on(evas, "Super");
+
+ if (key == VK_CAPITAL)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_key_lock_off(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ }
+ if (key == VK_NUMLOCK)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Num_Lock"))
+ evas_key_lock_off(evas, "Num_Lock");
+ else
+ evas_key_lock_on(evas, "Num_Lock");
+ }
+ if (key == VK_SCROLL)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Scroll_Lock"))
+ evas_key_lock_off(evas, "Scroll_Lock");
+ else
+ evas_key_lock_on(evas, "Scroll_Lock");
+ }
+ if (key == VK_ESCAPE)
+ evas_event_feed_key_down(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ if (key == VK_RETURN)
+ evas_event_feed_key_down(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ if (key == VK_LEFT)
+ evas_event_feed_key_down(evas, "Left", "Left", NULL, NULL, 0, NULL);
+ if (key == VK_RIGHT)
+ evas_event_feed_key_down(evas, "Right", "Right", NULL, NULL, 0, NULL);
+ if (key == 81)
+ evas_event_feed_key_down(evas, "Q", "Q", NULL, NULL, 0, NULL);
+ if (key == 113)
+ evas_event_feed_key_down(evas, "q", "q", NULL, NULL, 0, NULL);
+ return 0;
+ }
+ case WM_KEYUP:
+ case WM_SYSKEYUP: {
+ int key;
+
+ key = LOWORD(wParam);
+
+ if ((key == VK_SHIFT) ||
+ (key == VK_LSHIFT) ||
+ (key == VK_RSHIFT))
+ evas_key_modifier_off(evas, "Shift");
+ if ((key == VK_CONTROL) ||
+ (key == VK_LCONTROL) ||
+ (key == VK_RCONTROL))
+ evas_key_modifier_off(evas, "Control");
+ if ((key == VK_MENU) ||
+ (key == VK_LMENU) ||
+ (key == VK_RMENU))
+ evas_key_modifier_off(evas, "Alt");
+ if ((key == VK_LWIN) ||
+ (key == VK_RWIN))
+ evas_key_modifier_off(evas, "Super");
+ if (key == VK_ESCAPE)
+ evas_event_feed_key_up(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ if (key == VK_RETURN)
+ evas_event_feed_key_up(evas, "Return", "Return", NULL, NULL, 0, NULL);
+ if (key == VK_LEFT)
+ evas_event_feed_key_up(evas, "Left", "Left", NULL, NULL, 0, NULL);
+ if (key == VK_RIGHT)
+ evas_event_feed_key_up(evas, "Right", "Right", NULL, NULL, 0, NULL);
+ if (key == 81)
+ evas_event_feed_key_up(evas, "Q", "Q", NULL, NULL, 0, NULL);
+ if (key == 113)
+ evas_event_feed_key_up(evas, "q", "q", NULL, NULL, 0, NULL);
+ return 0;
+ }
+ default:
+ return DefWindowProc(hwnd, uMsg, wParam, lParam);
+ }
+}
+
+Eina_Bool
+engine_software_gdi_args(const char *engine __UNUSED__, int width, int height)
+{
+ WNDCLASS wc;
+ RECT rect;
+ HDC dc;
+ Evas_Engine_Info_Software_Gdi *einfo;
+ DWORD style;
+ DWORD exstyle;
+ int depth;
+
+ instance = GetModuleHandle(NULL);
+ if (!instance) return EINA_FALSE;
+
+ wc.style = CS_HREDRAW | CS_VREDRAW;
+ wc.lpfnWndProc = MainWndProc;
+ wc.cbClsExtra = 0;
+ wc.cbWndExtra = 0;
+ wc.hInstance = instance;
+ wc.hIcon = LoadIcon(NULL, IDI_APPLICATION);
+ wc.hCursor = LoadCursor(NULL, IDC_ARROW);
+ wc.hbrBackground = GetSysColorBrush(COLOR_BTNFACE);
+ wc.lpszMenuName = NULL;
+ wc.lpszClassName = "Evas_Software_Gdi_Test";
+
+ if(!RegisterClass(&wc))
+ goto free_library;
+
+ style = WS_OVERLAPPEDWINDOW | WS_SIZEBOX;
+ exstyle = 0;
+
+ rect.left = 0;
+ rect.top = 0;
+ rect.right = width;
+ rect.bottom = height;
+ AdjustWindowRectEx (&rect, style, FALSE, exstyle);
+
+ window = CreateWindowEx(exstyle,
+ "Evas_Software_Gdi_Test",
+ "Evas_Software_Gdi_Test",
+ style,
+ CW_USEDEFAULT, CW_USEDEFAULT,
+ rect.right - rect.left, rect.bottom - rect.top,
+ NULL, NULL, instance, NULL);
+ if (!window)
+ goto destroy_window;
+
+ /* make the window non resizable */
+ style = GetWindowLong(window, GWL_STYLE);
+ style &= ~WS_THICKFRAME;
+ if (!SetWindowLong(window, GWL_STYLE, style))
+ goto unregister_class;
+
+ dc = GetDC(NULL);
+ if (!dc)
+ goto destroy_window;
+
+ depth = GetDeviceCaps(dc, BITSPIXEL);
+ ReleaseDC(NULL, dc);
+
+ evas_output_method_set(evas, evas_render_method_lookup("software_gdi"));
+ einfo = (Evas_Engine_Info_Software_Gdi *)evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ fprintf(stderr, "Evas does not support the Software GDI Engine\n");
+ goto destroy_window;
+ }
+
+ einfo->info.window = window;
+ einfo->info.depth = depth;
+ einfo->info.rotation = 0;
+ einfo->info.borderless = 0;
+ einfo->info.fullscreen = 0;
+ einfo->info.region = 0;
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the Software GDI Engine\n");
+ goto destroy_window;
+ }
+
+ /* the second parameter is ignored, as it's the first call of ShowWindow */
+ ShowWindow(window, SW_SHOWDEFAULT);
+ UpdateWindow(window);
+
+ return EINA_TRUE;
+
+ destroy_window:
+ DestroyWindow(window);
+ unregister_class:
+ UnregisterClass("Evas_Software_Gdi_Test", instance);
+ free_library:
+ FreeLibrary(instance);
+
+ return EINA_FALSE;
+}
+
+void
+engine_software_gdi_loop(void)
+{
+ MSG msg;
+ int res;
+
+ again:
+ if (!PeekMessage (&msg, window, 0, 0, PM_NOREMOVE))
+ return;
+
+ res = GetMessage (&msg, NULL, 0, 0);
+ TranslateMessage (&msg);
+ DispatchMessage (&msg);
+
+ goto again;
+}
+
+void
+engine_software_gdi_shutdown(void)
+{
+ DestroyWindow(window);
+ UnregisterClass("Evas_Software_Gdi_Test", instance);
+ FreeLibrary(instance);
+}
--- /dev/null
+#ifndef __ENGINE_SOFTWARE_GDI_H__
+#define __ENGINE_SOFTWARE_GDI_H__
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+Eina_Bool engine_software_gdi_args(const char *engine, int width, int height);
+void engine_software_gdi_loop(void);
+void engine_software_gdi_shutdown(void);
+
+
+#ifdef __cplusplus
+}
+#endif
+
+
+#endif /* __ENGINE_SOFTWARE_GDI_H__ */
#include "main.h"
#include <SDL/SDL.h>
-#include <Evas_Engine_SDL.h>
+#include <Evas_Engine_Buffer.h>
-int
-engine_software_sdl_args(int argc, char **argv)
+static void *
+_expedite_sdl_switch_buffer(void *data, void *dest __UNUSED__)
{
- Evas_Engine_Info_SDL *einfo;
- int i;
- int ok = 0;
+ SDL_Flip(data);
+ return ((SDL_Surface*)data)->pixels;
+}
+
+Eina_Bool
+engine_software_sdl_args(const char *engine, int width, int height)
+{
+ int ok = 0;
+
+ if (!strcmp(engine, "sdl")) ok = 1;
+ if (!ok) return EINA_FALSE;
- for (i = 1; i < argc; ++i)
+ if (ok == 1)
{
- if ((!strcmp(argv[i], "-e") && (i < (argc - 1))))
+ Evas_Engine_Info_Buffer *einfo;
+
+ evas_output_method_set(evas, evas_render_method_lookup("buffer"));
+
+ einfo = (Evas_Engine_Info_Buffer *) evas_engine_info_get(evas);
+ if (einfo)
{
- i++;
- if (!strcmp(argv[i], "sdl")) ok = 1;
- if (!strcmp(argv[i], "sdl-16")) ok = 2;
- }
- }
- if (!ok) return 0;
+ SDL_Init(SDL_INIT_NOPARACHUTE);
- if (ok == 1)
- evas_output_method_set(evas, evas_render_method_lookup("software_sdl"));
- else
- evas_output_method_set(evas, evas_render_method_lookup("software_16_sdl"));
+ if (SDL_InitSubSystem(SDL_INIT_VIDEO) < 0)
+ {
+ printf("SDL_Init failed with %s", SDL_GetError());
+ SDL_Quit();
+ return EINA_FALSE;
+ }
- einfo = (Evas_Engine_Info_SDL *) evas_engine_info_get(evas);
+ einfo->info.depth_type = EVAS_ENGINE_BUFFER_DEPTH_RGB32;
+ einfo->info.switch_data = SDL_SetVideoMode(width, height, 32, SDL_HWSURFACE | SDL_DOUBLEBUF);
+ if (!einfo->info.switch_data)
+ {
+ printf("SDL_SetVideoMode failed !");
+ return EINA_FALSE;
+ }
- /* the following is specific to the engine */
- einfo->info.fullscreen = 0;
- einfo->info.noframe = 0;
+ SDL_SetAlpha(einfo->info.switch_data, SDL_SRCALPHA, 0);
+ SDL_FillRect(einfo->info.switch_data, NULL, 0);
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
- return 1;
+ einfo->info.dest_buffer = ((SDL_Surface*)einfo->info.switch_data)->pixels;
+ einfo->info.dest_buffer_row_bytes = width * sizeof (int);
+ einfo->info.use_color_key = 0;
+ einfo->info.alpha_threshold = 0;
+ einfo->info.func.new_update_region = NULL;
+ einfo->info.func.free_update_region = NULL;
+ einfo->info.func.switch_buffer = _expedite_sdl_switch_buffer;
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("evas_engine_info_set() for engine 'sdl' with 'buffer' backend failed.");
+ return EINA_FALSE;
+ }
+ }
+ }
+
+ return EINA_TRUE;
}
void
engine_software_sdl_loop(void)
{
SDL_Event event;
+ int rmethod;
while(SDL_PollEvent(&event))
{
break;
case SDL_MOUSEBUTTONDOWN:
evas_event_feed_mouse_move(evas, event.button.x, event.button.y, 0, NULL);
- evas_event_feed_mouse_down(evas, event.button.state, EVAS_BUTTON_NONE, 0, NULL);
+ evas_event_feed_mouse_down(evas, event.button.button, EVAS_BUTTON_NONE, 0, NULL);
break;
case SDL_MOUSEBUTTONUP:
evas_event_feed_mouse_move(evas, event.button.x, event.button.y, 0, NULL);
- evas_event_feed_mouse_up(evas, event.button.state, EVAS_BUTTON_NONE, 0, NULL);
+ evas_event_feed_mouse_up(evas, event.button.button, EVAS_BUTTON_NONE, 0, NULL);
break;
case SDL_VIDEORESIZE:
- evas_output_size_set(evas, event.resize.w, event.resize.w);
+ rmethod = evas_output_method_get(evas);
+ if (rmethod == evas_render_method_lookup("buffer"))
+ {
+ Evas_Engine_Info_Buffer *einfo;
+
+ einfo = (Evas_Engine_Info_Buffer *) evas_engine_info_get(evas);
+ if (einfo)
+ {
+ einfo->info.depth_type = EVAS_ENGINE_BUFFER_DEPTH_RGB32;
+ einfo->info.switch_data = SDL_SetVideoMode(event.resize.w, event.resize.h, 32, SDL_HWSURFACE | SDL_DOUBLEBUF);
+ if (!einfo->info.switch_data)
+ {
+ return ;
+ }
+
+ SDL_SetAlpha(einfo->info.switch_data, SDL_SRCALPHA, 0);
+ SDL_FillRect(einfo->info.switch_data, NULL, 0);
+
+ einfo->info.dest_buffer = ((SDL_Surface*)einfo->info.switch_data)->pixels;
+ einfo->info.dest_buffer_row_bytes = event.resize.w * sizeof (int);
+ einfo->info.use_color_key = 0;
+ einfo->info.alpha_threshold = 0;
+ einfo->info.func.new_update_region = NULL;
+ einfo->info.func.free_update_region = NULL;
+ einfo->info.func.switch_buffer = _expedite_sdl_switch_buffer;
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ return ;
+ }
+ }
+ }
+
+ evas_output_viewport_set(evas, 0, 0,
+ event.resize.h, event.resize.w);
+ evas_output_size_set(evas, event.resize.h, event.resize.w);
evas_output_size_get(evas, &win_w, &win_h);
break;
case SDL_VIDEOEXPOSE:
}
}
}
+
+void
+engine_software_sdl_shutdown(void)
+{
+}
#ifndef ENGINE_SOFTWARE_SDL_H
#define ENGINE_SOFTWARE_SDL_H
-int engine_software_sdl_args(int argc, char **argv);
+Eina_Bool engine_software_sdl_args(const char *engine, int width, int height);
void engine_software_sdl_loop(void);
+void engine_software_sdl_shutdown(void);
#endif
#include <xcb/xcb.h>
#include <xcb/xcb_keysyms.h>
-#include <Evas_Engine_Software_Xcb.h>
+#include <Evas_Engine_Software_X11.h>
#define XK_MISCELLANY
#include <X11/keysymdef.h>
static xcb_connection_t *conn = NULL;
-static xcb_screen_t *screen = NULL;
-static xcb_window_t win = 0;
+static xcb_screen_t *screen = NULL;
+static xcb_window_t win = 0;
+static int first_expose = 0;
-int
-engine_software_xcb_args(int argc, char **argv)
+Eina_Bool
+engine_software_xcb_args(const char *engine, int width, int height)
{
struct xcb_size_hints_t hints;
uint32_t value_list[6];
xcb_screen_iterator_t iter;
- Evas_Engine_Info_Software_Xcb *einfo;
+ Evas_Engine_Info_Software_X11 *einfo;
xcb_intern_atom_reply_t *reply;
- char *str;
+ const char *str;
xcb_intern_atom_cookie_t cookie1;
xcb_intern_atom_cookie_t cookie2;
xcb_intern_atom_cookie_t cookie3;
xcb_atom_t wm_size_hint;
uint32_t value_mask;
int s;
+ int s_tmp;
int l1;
int l2;
int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "xcb")) ok = 1;
- }
- }
- if (!ok) return 0;
conn = xcb_connect(NULL, &s);
- if (!conn) return 0;
+ if (xcb_connection_has_error(conn)) return EINA_FALSE;
+
+ cookie1 = xcb_intern_atom_unchecked(conn, 0, strlen("STRING"), "STRING");
+ cookie2 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NAME"), "WM_NAME");
+ cookie3 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_CLASS"), "WM_CLASS");
+ cookie4 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NORMAL_HINTS)"), "WM_NORMAL_HINTS)");
+ cookie5 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_SIZE_HINTS)"), "WM_SIZE_HINTS)");
+ s_tmp = s;
iter = xcb_setup_roots_iterator(xcb_get_setup(conn));
- for (; iter.rem; --s, xcb_screen_next (&iter))
- if (s == 0)
+ for (; iter.rem; --s_tmp, xcb_screen_next (&iter))
+ if (s_tmp == 0)
{
screen = iter.data;
break;
}
- evas_output_method_set(evas, evas_render_method_lookup("software_xcb"));
- einfo = (Evas_Engine_Info_Software_Xcb *)evas_engine_info_get(evas);
+ evas_output_method_set(evas, evas_render_method_lookup("software_x11"));
+ einfo = (Evas_Engine_Info_Software_X11 *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the Software XCB Engine\n");
- return 0;
+ goto close_connection;
}
- einfo->info.conn = conn;
+ einfo->info.backend = EVAS_ENGINE_INFO_SOFTWARE_X11_BACKEND_XCB;
+ einfo->info.connection = conn;
einfo->info.screen = screen;
- einfo->info.visual = einfo->func.best_visual_get(screen);
- einfo->info.colormap = einfo->func.best_colormap_get(screen);
- einfo->info.depth = einfo->func.best_depth_get(screen);
+ einfo->info.visual = einfo->func.best_visual_get(1, conn, s);
+ einfo->info.colormap = einfo->func.best_colormap_get(1, conn, s);
+ einfo->info.depth = einfo->func.best_depth_get(1, conn, s);
einfo->info.rotation = 0;
einfo->info.debug = 0;
value_list[5] = einfo->info.colormap;
win = xcb_generate_id(conn);
+ if (!win)
+ goto close_connection;
xcb_create_window(conn,
einfo->info.depth,
- win, screen->root, 0, 0, win_w, win_h, 0,
+ win, screen->root, 0, 0, width, height, 0,
XCB_WINDOW_CLASS_INPUT_OUTPUT,
- einfo->info.visual->visual_id,
+ ((xcb_visualtype_t *)einfo->info.visual)->visual_id,
value_mask,
value_list);
einfo->info.drawable = win;
- xcb_map_window(conn, win);
-
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the Software XCB Engine\n");
+ goto destroy_window;
+ }
+
+ if (fullscreen)
+ {
+ xcb_intern_atom_cookie_t cookie1;
+ xcb_intern_atom_cookie_t cookie2;
+ xcb_intern_atom_reply_t *reply;
+ xcb_atom_t prop;
+ xcb_atom_t type;
+ xcb_atom_t state;
+
+ cookie1 = xcb_intern_atom_unchecked(conn, 0, strlen("_NET_WM_STATE"), "_NET_WM_STATE");
+ cookie2 = xcb_intern_atom_unchecked(conn, 0, strlen("_NET_WM_STATE_FULLSCREEN"), "_NET_WM_STATE_FULLSCREEN");
+ reply = xcb_intern_atom_reply(conn, cookie1, NULL);
+ prop = reply->atom;
+ free(reply);
+ reply = xcb_intern_atom_reply(conn, cookie2, NULL);
+ state = reply->atom;
+ free(reply);
+ xcb_change_property(conn, XCB_PROP_MODE_REPLACE, win, prop, XCB_ATOM_ATOM, 32, 1, (const void *)&state);
+ }
-/* XStoreName(disp, win, "Expedite - Evas Test Suite"); */
+ str = "expedite\0Expedite";
- cookie1 = xcb_intern_atom_unchecked(conn, 0, strlen("STRING"), "STRING");
- cookie2 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NAME"), "WM_NAME");
- cookie3 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_CLASS"), "WM_CLASS");
- cookie4 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NORMAL_HINTS)"), "WM_NORMAL_HINTS)");
- cookie5 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_SIZE_HINTS)"), "WM_SIZE_HINTS)");
+ memset(&hints, 0, sizeof(hints));
+ hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
+ hints.min_width = width;
+ hints.max_width = width;
+ hints.min_height = height;
+ hints.max_height = height;
reply = xcb_intern_atom_reply(conn, cookie1, NULL);
string = reply->atom;
free(reply);
+
reply = xcb_intern_atom_reply(conn, cookie2, NULL);
wm_name = reply->atom;
free(reply);
wm_name, string, 8,
strlen("Expedite - Evas Test Suite"), "Expedite - Evas Test Suite");
-/* chint.res_name = "expedite"; */
-/* chint.res_class = "Expedite"; */
-/* XSetClassHint(disp, win, &chint); */
-
- l1 = strlen("expedite");
- l2 = strlen("Expedite");
- str = (char *)malloc(l1 + l2 + 1);
- memcpy(str, "expedite", l1);
- str[l1] = '\0';
- memcpy(str + l1 + 1, "Expedite", l2);
-
reply = xcb_intern_atom_reply(conn, cookie3, NULL);
wm_class = reply->atom;
free(reply);
xcb_change_property(conn, XCB_PROP_MODE_REPLACE, win,
wm_class, string, 8,
l1 + l2 + 1, str);
- free(str);
-
-/* szhints.flags = PMinSize | PMaxSize | PSize | USSize; */
-/* szhints.min_width = szhints.max_width = win_w; */
-/* szhints.min_height = szhints.max_height = win_h; */
-/* XSetWMNormalHints(disp, win, &szhints); */
-
- memset(&hints, 0, sizeof(hints));
- hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
- hints.min_width = win_w;
- hints.max_width = win_w;
- hints.min_height = win_h;
- hints.max_height = win_h;
reply = xcb_intern_atom_reply(conn, cookie4, NULL);
wm_normal_hint = reply->atom;
wm_normal_hint, wm_size_hint, 32,
sizeof(hints) / 4, &hints);
- free(xcb_get_input_focus_reply(conn, xcb_get_input_focus_unchecked(conn), NULL));
+ xcb_map_window(conn, win);
- return 1;
+ free(xcb_get_input_focus_reply(conn, xcb_get_input_focus_unchecked(conn), NULL));
+
+ while (!first_expose)
+ engine_software_xcb_loop();
+ return EINA_TRUE;
+
+ destroy_window:
+ xcb_destroy_window(conn, win);
+ close_connection:
+ free(xcb_intern_atom_reply(conn, cookie1, NULL));
+ free(xcb_intern_atom_reply(conn, cookie2, NULL));
+ free(xcb_intern_atom_reply(conn, cookie3, NULL));
+ free(xcb_intern_atom_reply(conn, cookie4, NULL));
+ free(xcb_intern_atom_reply(conn, cookie5, NULL));
+ xcb_disconnect(conn);
+
+ return EINA_FALSE;
}
void
e = (xcb_expose_event_t *)ev;
+ first_expose = 1;
evas_damage_rectangle_add(evas,
e->x,
e->y,
case XCB_CONFIGURE_NOTIFY:
{
xcb_configure_notify_event_t *e;
-
+
e = (xcb_configure_notify_event_t *)ev;
+ evas_output_viewport_set(evas, 0, 0,
+ e->width,
+ e->height);
evas_output_size_set(evas,
e->width,
e->height);
+ win_w = e->width;
+ win_h = e->height;
break;
}
case XCB_ENTER_NOTIFY:
xcb_key_press_event_t *e;
xcb_key_symbols_t *kss;
xcb_keysym_t ks;
- char *str;
+ char *str = "";
e = (xcb_key_press_event_t *)ev;
str = "Escape";
if (ks == XK_Return)
str = "Return";
- if (ks == 71)
+ if (ks == 113)
str = "q";
evas_event_feed_key_down(evas, str, str, NULL, NULL, 0, NULL);
xcb_key_release_event_t *e;
xcb_key_symbols_t *kss;
xcb_keysym_t ks;
- char *str;
+ char *str = "";
e = (xcb_key_release_event_t *)ev;
str = "Escape";
if (ks == XK_Return)
str = "Return";
- if (ks == 71)
+ if (ks == 113)
str = "q";
evas_event_feed_key_up(evas, str, str, NULL, NULL, 0, NULL);
goto again;
}
+
+void
+engine_software_xcb_shutdown(void)
+{
+ xcb_destroy_window(conn, win);
+ xcb_disconnect(conn);
+}
#ifndef ENGINE_SOFTWARE_XCB_H
#define ENGINE_SOFTWARE_XCB_H
-int engine_software_xcb_args(int argc, char **argv);
+Eina_Bool engine_software_xcb_args(const char *engine, int width, int height);
void engine_software_xcb_loop(void);
+void engine_software_xcb_shutdown(void);
#endif
--- /dev/null
+#include "main.h"
+
+#include <X11/Xlib.h>
+#include <X11/XKBlib.h>
+#include <X11/Xutil.h>
+#include <X11/Xatom.h>
+#include <Evas_Engine_Software_X11.h>
+
+static Display *disp = NULL;
+static Window win = 0;
+static int first_expose = 0;
+
+Eina_Bool
+engine_software_xlib_args(const char *engine __UNUSED__, int width, int height)
+{
+ XSetWindowAttributes attr;
+ XClassHint chint;
+ XSizeHints szhints;
+ Evas_Engine_Info_Software_X11 *einfo;
+
+ disp = XOpenDisplay(NULL);
+ if (!disp) return EINA_FALSE;
+
+ evas_output_method_set(evas, evas_render_method_lookup("software_x11"));
+ einfo = (Evas_Engine_Info_Software_X11 *)evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ printf("Evas does not support the Software Xlib Engine\n");
+ goto close_display;
+ }
+
+ einfo->info.backend = EVAS_ENGINE_INFO_SOFTWARE_X11_BACKEND_XLIB;
+ einfo->info.connection = disp;
+ einfo->info.screen = NULL;
+ einfo->info.visual = einfo->func.best_visual_get(0, disp, DefaultScreen(disp));
+ einfo->info.colormap = einfo->func.best_colormap_get(0, disp, DefaultScreen(disp));
+ einfo->info.depth = einfo->func.best_depth_get(0, disp, DefaultScreen(disp));
+ einfo->info.rotation = 0;
+ einfo->info.debug = 0;
+#ifdef EVAS_FRAME_QUEUING
+ {
+ char *render_mode;
+ render_mode = getenv("EVAS_RENDER_MODE");
+ if (render_mode && !strcmp(render_mode, "non-blocking"))
+ {
+ einfo->render_mode = EVAS_RENDER_MODE_NONBLOCKING;
+ }
+ }
+#endif
+ attr.backing_store = NotUseful;
+ attr.colormap = einfo->info.colormap;
+ attr.border_pixel = 0;
+ attr.background_pixmap = None;
+ attr.event_mask =
+ ExposureMask | ButtonPressMask | ButtonReleaseMask | PointerMotionMask |
+ StructureNotifyMask | EnterWindowMask | LeaveWindowMask |
+ KeyPressMask | KeyReleaseMask;
+ attr.bit_gravity = ForgetGravity;
+ win = XCreateWindow(disp, DefaultRootWindow(disp),
+ 0, 0, width, height, 0,
+ einfo->info.depth, InputOutput,
+ einfo->info.visual,
+ CWBackingStore | CWColormap |
+ CWBackPixmap | CWBorderPixel |
+ CWBitGravity | CWEventMask,
+ &attr);
+ if (!win)
+ goto close_display;
+
+ einfo->info.drawable = win;
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the Software Xlib Engine\n");
+ goto destroy_window;
+ }
+
+ if (fullscreen)
+ {
+ Atom prop = XInternAtom(disp, "_NET_WM_STATE", False);
+ Atom state = XInternAtom(disp, "_NET_WM_STATE_FULLSCREEN", False);
+ unsigned long data = state;
+ XChangeProperty(disp, win, prop, XA_ATOM, 32, PropModeReplace,
+ (unsigned char*) &data, 1);
+ }
+
+ XStoreName(disp, win, "Expedite - Evas Test Suite");
+ chint.res_name = "expedite";
+ chint.res_class = "Expedite";
+ XSetClassHint(disp, win, &chint);
+ szhints.flags = PMinSize | PMaxSize | PSize | USSize;
+ szhints.min_width = szhints.max_width = width;
+ szhints.min_height = szhints.max_height = height;
+ XSetWMNormalHints(disp, win, &szhints);
+ XMapWindow(disp, win);
+ XSync(disp, False);
+ while (!first_expose)
+ engine_software_xlib_loop();
+ return EINA_TRUE;
+
+ destroy_window:
+ XDestroyWindow(disp, win);
+ close_display:
+ XCloseDisplay(disp);
+
+ return EINA_FALSE;
+}
+
+void
+engine_software_xlib_loop(void)
+{
+ XEvent ev;
+ KeySym ks;
+ char *kstr;
+
+ again:
+ if (!XCheckMaskEvent(disp,
+ ExposureMask |
+ StructureNotifyMask |
+ KeyPressMask |
+ KeyReleaseMask |
+ ButtonPressMask |
+ ButtonReleaseMask |
+ PointerMotionMask |
+ EnterWindowMask |
+ LeaveWindowMask, &ev))
+ return;
+ switch (ev.type)
+ {
+ case ButtonPress:
+ evas_event_feed_mouse_move(evas, ev.xbutton.x, ev.xbutton.y, 0, NULL);
+ evas_event_feed_mouse_down(evas, ev.xbutton.button, EVAS_BUTTON_NONE, 0, NULL);
+ break;
+ case ButtonRelease:
+ evas_event_feed_mouse_move(evas, ev.xbutton.x, ev.xbutton.y, 0, NULL);
+ evas_event_feed_mouse_up(evas, ev.xbutton.button, EVAS_BUTTON_NONE, 0, NULL);
+ break;
+ case MotionNotify:
+ evas_event_feed_mouse_move(evas, ev.xmotion.x, ev.xmotion.y, 0, NULL);
+ break;
+ case Expose:
+ first_expose = 1;
+ evas_damage_rectangle_add(evas,
+ ev.xexpose.x,
+ ev.xexpose.y,
+ ev.xexpose.width,
+ ev.xexpose.height);
+ break;
+ case ConfigureNotify:
+ evas_output_viewport_set(evas, 0, 0,
+ ev.xconfigure.width,
+ ev.xconfigure.height);
+ evas_output_size_set(evas,
+ ev.xconfigure.width,
+ ev.xconfigure.height);
+ win_w = ev.xconfigure.width;
+ win_h = ev.xconfigure.height;
+ break;
+ case EnterNotify:
+ evas_event_feed_mouse_in(evas, 0, NULL);
+ break;
+ case LeaveNotify:
+ evas_event_feed_mouse_out(evas, 0, NULL);
+ break;
+ case KeyPress:
+ ks = XkbKeycodeToKeysym(ev.xkey.display, ev.xkey.keycode, 0, 0);
+ kstr = XKeysymToString(ks);
+ if (kstr)
+ {
+ if ((!strcmp(kstr, "Shift_L")) ||
+ (!strcmp(kstr, "Shift_R")))
+ evas_key_modifier_on(evas, "Shift");
+ if ((!strcmp(kstr, "Control_L")) ||
+ (!strcmp(kstr, "Control_R")))
+ evas_key_modifier_on(evas, "Control");
+ if ((!strcmp(kstr, "Alt_L")) ||
+ (!strcmp(kstr, "Alt_R")))
+ evas_key_modifier_on(evas, "Alt");
+ if ((!strcmp(kstr, "Super_L")) ||
+ (!strcmp(kstr, "Super_R")))
+ evas_key_modifier_on(evas, "Super");
+ if (!strcmp(kstr, "Caps_Lock"))
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_key_lock_off(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ }
+ if (!strcmp(kstr, "Num_Lock"))
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Num_Lock"))
+ evas_key_lock_off(evas, "Num_Lock");
+ else
+ evas_key_lock_on(evas, "Num_Lock");
+ }
+ if (!strcmp(kstr, "Scroll_Lock"))
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Scroll_Lock"))
+ evas_key_lock_off(evas, "Scroll_Lock");
+ else
+ evas_key_lock_on(evas, "Scroll_Lock");
+ }
+ if (kstr) evas_event_feed_key_down(evas, kstr, kstr, NULL, NULL, 0, NULL);
+ }
+ break;
+ case KeyRelease:
+ ks = XkbKeycodeToKeysym(ev.xkey.display, ev.xkey.keycode, 0, 0);
+ kstr = XKeysymToString(ks);
+ if (kstr)
+ {
+ if ((!strcmp(kstr, "Shift_L")) ||
+ (!strcmp(kstr, "Shift_R")))
+ evas_key_modifier_off(evas, "Shift");
+ if ((!strcmp(kstr, "Control_L")) ||
+ (!strcmp(kstr, "Control_R")))
+ evas_key_modifier_off(evas, "Control");
+ if ((!strcmp(kstr, "Alt_L")) ||
+ (!strcmp(kstr, "Alt_R")))
+ evas_key_modifier_off(evas, "Alt");
+ if ((!strcmp(kstr, "Super_L")) ||
+ (!strcmp(kstr, "Super_R")))
+ evas_key_modifier_off(evas, "Super");
+ evas_event_feed_key_up(evas, kstr, kstr, NULL, NULL, 0, NULL);
+ }
+ break;
+ default:
+ break;
+ }
+ goto again;
+}
+
+void
+engine_software_xlib_shutdown(void)
+{
+ XDestroyWindow(disp, win);
+ XCloseDisplay(disp);
+}
--- /dev/null
+#ifndef ENGINE_SOFTWARE_XLIB_H
+#define ENGINE_SOFTWARE_XLIB_H
+
+Eina_Bool engine_software_xlib_args(const char *engine, int width, int height);
+void engine_software_xlib_loop(void);
+void engine_software_xlib_shutdown(void);
+
+#endif
#include <X11/Xlib.h>
#include <X11/Xutil.h>
+#include <X11/Xatom.h>
#include <Evas_Engine_XRender_X11.h>
static Display *disp = NULL;
static Window win = 0;
+static int first_expose = 0;
-int
-engine_xrender_x11_args(int argc, char **argv)
+Eina_Bool
+engine_xrender_x11_args(const char *engine, int width, int height)
{
XSetWindowAttributes attr;
XClassHint chint;
XSizeHints szhints;
Evas_Engine_Info_XRender_X11 *einfo;
int i;
- int ok = 0;
-
- for (i = 1; i < argc; i++)
- {
- if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
- {
- i++;
- if (!strcmp(argv[i], "xr")) ok = 1;
- }
- }
- if (!ok) return 0;
disp = XOpenDisplay(NULL);
- if (!disp) return 0;
+ if (!disp) return EINA_FALSE;
evas_output_method_set(evas, evas_render_method_lookup("xrender_x11"));
einfo = (Evas_Engine_Info_XRender_X11 *)evas_engine_info_get(evas);
if (!einfo)
{
printf("Evas does not support the XRender X11 Engine\n");
- return 0;
+ goto close_display;
}
- einfo->info.display = disp;
+ einfo->info.backend = EVAS_ENGINE_INFO_XRENDER_BACKEND_XLIB;
+ einfo->info.connection = disp;
+ einfo->info.screen = NULL;
einfo->info.visual = DefaultVisual(disp, DefaultScreen(disp));
attr.backing_store = NotUseful;
attr.border_pixel = 0;
KeyPressMask | KeyReleaseMask;
attr.bit_gravity = ForgetGravity;
win = XCreateWindow(disp, DefaultRootWindow(disp),
- 0, 0, win_w, win_h, 0,
+ 0, 0, width, height, 0,
0, InputOutput,
einfo->info.visual,
CWBackingStore |
CWBackPixmap | CWBorderPixel |
CWBitGravity | CWEventMask,
&attr);
+ if (!win)
+ goto close_display;
einfo->info.drawable = win;
- evas_engine_info_set(evas, (Evas_Engine_Info *) einfo);
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the XRender X11 Engine\n");
+ goto destroy_window;
+ }
+
+ if (fullscreen)
+ {
+ Atom prop = XInternAtom(disp, "_NET_WM_STATE", False);
+ Atom state = XInternAtom(disp, "_NET_WM_STATE_FULLSCREEN", False);
+ unsigned long data = state;
+ XChangeProperty(disp, win, prop, XA_ATOM, 32, PropModeReplace,
+ (unsigned char*) &data, 1);
+ }
+
XStoreName(disp, win, "Expedite - Evas Test Suite");
chint.res_name = "expedite";
chint.res_class = "Expedite";
XSetClassHint(disp, win, &chint);
szhints.flags = PMinSize | PMaxSize | PSize | USSize;
- szhints.min_width = szhints.max_width = win_w;
- szhints.min_height = szhints.max_height = win_h;
+ szhints.min_width = szhints.max_width = width;
+ szhints.min_height = szhints.max_height = height;
XSetWMNormalHints(disp, win, &szhints);
XMapWindow(disp, win);
XSync(disp, False);
- return 1;
+ while (!first_expose)
+ engine_xrender_x11_loop();
+ return EINA_TRUE;
+
+ destroy_window:
+ XDestroyWindow(disp, win);
+ close_display:
+ XCloseDisplay(disp);
+
+ return EINA_FALSE;
}
void
evas_event_feed_mouse_move(evas, ev.xmotion.x, ev.xmotion.y, 0, NULL);
break;
case Expose:
+ first_expose = 1;
evas_damage_rectangle_add(evas,
ev.xexpose.x,
ev.xexpose.y,
ev.xexpose.height);
break;
case ConfigureNotify:
+ evas_output_viewport_set(evas, 0, 0,
+ ev.xconfigure.width,
+ ev.xconfigure.height);
evas_output_size_set(evas,
ev.xconfigure.width,
ev.xconfigure.height);
+ win_w = ev.xconfigure.width;
+ win_h = ev.xconfigure.height;
break;
case EnterNotify:
evas_event_feed_mouse_in(evas, 0, NULL);
}
goto again;
}
+
+void
+engine_xrender_x11_shutdown(void)
+{
+ XDestroyWindow(disp, win);
+ XCloseDisplay(disp);
+}
#ifndef ENGINE_XRENDER_X11_H
#define ENGINE_XRENDER_X11_H
-int engine_xrender_x11_args(int argc, char **argv);
+Eina_Bool engine_xrender_x11_args(const char *engine, int width, int height);
void engine_xrender_x11_loop(void);
+void engine_xrender_x11_shutdown(void);
#endif
--- /dev/null
+#include "main.h"
+
+#include <xcb/xcb.h>
+#include <xcb/xcb_keysyms.h>
+#include <Evas_Engine_XRender_X11.h>
+
+#define XK_MISCELLANY
+#include <X11/keysymdef.h>
+
+enum {
+ XCB_SIZE_US_POSITION_HINT = 1 << 0,
+ XCB_SIZE_US_SIZE_HINT = 1 << 1,
+ XCB_SIZE_P_POSITION_HINT = 1 << 2,
+ XCB_SIZE_P_SIZE_HINT = 1 << 3,
+ XCB_SIZE_P_MIN_SIZE_HINT = 1 << 4,
+ XCB_SIZE_P_MAX_SIZE_HINT = 1 << 5,
+ XCB_SIZE_P_RESIZE_INC_HINT = 1 << 6,
+ XCB_SIZE_P_ASPECT_HINT = 1 << 7,
+ XCB_SIZE_BASE_SIZE_HINT = 1 << 8,
+ XCB_SIZE_P_WIN_GRAVITY_HINT = 1 << 9
+};
+
+struct xcb_size_hints_t {
+ uint32_t flags;
+ int32_t x, y, width, height;
+ int32_t min_width, min_height;
+ int32_t max_width, max_height;
+ int32_t width_inc, height_inc;
+ int32_t min_aspect_num, min_aspect_den;
+ int32_t max_aspect_num, max_aspect_den;
+ int32_t base_width, base_height;
+ uint32_t win_gravity;
+};
+
+
+static xcb_connection_t *conn = NULL;
+static xcb_screen_t *screen = NULL;
+static xcb_window_t win = 0;
+static int first_expose = 0;
+
+static xcb_visualtype_t *
+_engine_xrender_visual_get(xcb_connection_t *conn, xcb_screen_t *screen)
+{
+ xcb_depth_iterator_t iter_depth;
+
+ iter_depth = xcb_screen_allowed_depths_iterator(screen);
+ for (; iter_depth.rem; xcb_depth_next (&iter_depth))
+ {
+ xcb_visualtype_iterator_t iter_vis;
+
+ iter_vis = xcb_depth_visuals_iterator(iter_depth.data);
+ for (; iter_vis.rem; xcb_visualtype_next (&iter_vis))
+ {
+ if (screen->root_visual == iter_vis.data->visual_id)
+ return iter_vis.data;
+ }
+ }
+}
+
+Eina_Bool
+engine_xrender_xcb_args(const char *engine, int width, int height)
+{
+ struct xcb_size_hints_t hints;
+ uint32_t value_list[6];
+ xcb_screen_iterator_t iter;
+ Evas_Engine_Info_XRender_X11 *einfo;
+ xcb_intern_atom_reply_t *reply;
+ char *str;
+ xcb_intern_atom_cookie_t cookie1;
+ xcb_intern_atom_cookie_t cookie2;
+ xcb_intern_atom_cookie_t cookie3;
+ xcb_intern_atom_cookie_t cookie4;
+ xcb_intern_atom_cookie_t cookie5;
+ xcb_atom_t string;
+ xcb_atom_t wm_name;
+ xcb_atom_t wm_class;
+ xcb_atom_t wm_normal_hint;
+ xcb_atom_t wm_size_hint;
+ uint32_t value_mask;
+ int s;
+ int s_tmp;
+ int l1;
+ int l2;
+ int i;
+
+ conn = xcb_connect(NULL, &s);
+ if (xcb_connection_has_error(conn)) return EINA_FALSE;
+
+ s_tmp = s;
+ iter = xcb_setup_roots_iterator(xcb_get_setup(conn));
+ for (; iter.rem; --s_tmp, xcb_screen_next (&iter))
+ if (s_tmp == 0)
+ {
+ screen = iter.data;
+ break;
+ }
+
+ evas_output_method_set(evas, evas_render_method_lookup("xrender_x11"));
+ einfo = (Evas_Engine_Info_XRender_X11 *)evas_engine_info_get(evas);
+ if (!einfo)
+ {
+ printf("Evas does not support the XRender XCB Engine\n");
+ goto close_connection;
+ }
+
+ einfo->info.backend = EVAS_ENGINE_INFO_XRENDER_BACKEND_XCB;
+ einfo->info.connection = conn;
+ einfo->info.screen = screen;
+ einfo->info.visual = _engine_xrender_visual_get(conn, screen);
+
+ value_mask =
+ XCB_CW_BACK_PIXMAP | XCB_CW_BORDER_PIXEL | XCB_CW_BIT_GRAVITY |
+ XCB_CW_BACKING_STORE | XCB_CW_EVENT_MASK | XCB_CW_COLORMAP;
+
+ value_list[0] = XCB_NONE;
+ value_list[1] = 0;
+ value_list[2] = XCB_GRAVITY_BIT_FORGET;
+ value_list[3] = XCB_BACKING_STORE_NOT_USEFUL;
+ value_list[4] =
+ XCB_EVENT_MASK_KEY_PRESS | XCB_EVENT_MASK_KEY_RELEASE |
+ XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
+ XCB_EVENT_MASK_ENTER_WINDOW | XCB_EVENT_MASK_LEAVE_WINDOW |
+ XCB_EVENT_MASK_POINTER_MOTION | XCB_EVENT_MASK_EXPOSURE |
+ XCB_EVENT_MASK_STRUCTURE_NOTIFY;
+ value_list[5] =screen->default_colormap;
+
+ win = xcb_generate_id(conn);
+ if (!win)
+ goto close_connection;
+ xcb_create_window(conn,
+ screen->root_depth,
+ win, screen->root, 0, 0, width, height, 0,
+ XCB_WINDOW_CLASS_INPUT_OUTPUT,
+ ((xcb_visualtype_t *)einfo->info.visual)->visual_id,
+ value_mask,
+ value_list);
+ einfo->info.drawable = win;
+
+ if (!evas_engine_info_set(evas, (Evas_Engine_Info *) einfo))
+ {
+ printf("Evas can not setup the informations of the XRender XCB Engine\n");
+ goto destroy_window;
+ }
+
+/* XStoreName(disp, win, "Expedite - Evas Test Suite"); */
+
+ cookie1 = xcb_intern_atom_unchecked(conn, 0, strlen("STRING"), "STRING");
+ cookie2 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NAME"), "WM_NAME");
+ cookie3 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_CLASS"), "WM_CLASS");
+ cookie4 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_NORMAL_HINTS)"), "WM_NORMAL_HINTS)");
+ cookie5 = xcb_intern_atom_unchecked(conn, 0, strlen("WM_SIZE_HINTS)"), "WM_SIZE_HINTS)");
+
+ reply = xcb_intern_atom_reply(conn, cookie1, NULL);
+ string = reply->atom;
+ free(reply);
+ reply = xcb_intern_atom_reply(conn, cookie2, NULL);
+ wm_name = reply->atom;
+ free(reply);
+
+ xcb_change_property(conn, XCB_PROP_MODE_REPLACE, win,
+ wm_name, string, 8,
+ strlen("Expedite - Evas Test Suite"), "Expedite - Evas Test Suite");
+
+/* chint.res_name = "expedite"; */
+/* chint.res_class = "Expedite"; */
+/* XSetClassHint(disp, win, &chint); */
+
+ l1 = strlen("expedite");
+ l2 = strlen("Expedite");
+ str = (char *)malloc(l1 + l2 + 1);
+ memcpy(str, "expedite", l1);
+ str[l1] = '\0';
+ memcpy(str + l1 + 1, "Expedite", l2);
+
+ reply = xcb_intern_atom_reply(conn, cookie3, NULL);
+ wm_class = reply->atom;
+ free(reply);
+
+ xcb_change_property(conn, XCB_PROP_MODE_REPLACE, win,
+ wm_class, string, 8,
+ l1 + l2 + 1, str);
+ free(str);
+
+/* szhints.flags = PMinSize | PMaxSize | PSize | USSize; */
+/* szhints.min_width = szhints.max_width = width; */
+/* szhints.min_height = szhints.max_height = height; */
+/* XSetWMNormalHints(disp, win, &szhints); */
+
+ memset(&hints, 0, sizeof(hints));
+ hints.flags = XCB_SIZE_US_SIZE_HINT | XCB_SIZE_P_SIZE_HINT | XCB_SIZE_P_MIN_SIZE_HINT | XCB_SIZE_P_MAX_SIZE_HINT;
+ hints.min_width = width;
+ hints.max_width = width;
+ hints.min_height = height;
+ hints.max_height = height;
+
+ reply = xcb_intern_atom_reply(conn, cookie4, NULL);
+ wm_normal_hint = reply->atom;
+ free(reply);
+
+ reply = xcb_intern_atom_reply(conn, cookie5, NULL);
+ wm_size_hint = reply->atom;
+ free(reply);
+
+ xcb_change_property(conn, XCB_PROP_MODE_REPLACE, win,
+ wm_normal_hint, wm_size_hint, 32,
+ sizeof(hints) / 4, &hints);
+
+ free(xcb_get_input_focus_reply(conn, xcb_get_input_focus_unchecked(conn), NULL));
+
+ xcb_map_window(conn, win);
+
+ while (!first_expose)
+ engine_xrender_xcb_loop();
+ return EINA_TRUE;
+
+ destroy_window:
+ xcb_destroy_window(conn, win);
+ close_connection:
+ xcb_disconnect(conn);
+
+ return EINA_FALSE;
+}
+
+void
+engine_xrender_xcb_loop(void)
+{
+ xcb_generic_event_t *ev;
+
+ again:
+ ev = xcb_poll_for_event(conn);
+ if (!ev)
+ return;
+
+ switch (ev->response_type)
+ {
+ case XCB_BUTTON_PRESS:
+ {
+ xcb_button_press_event_t *e;
+
+ e = (xcb_button_press_event_t *)ev;
+
+ evas_event_feed_mouse_move(evas, e->event_x, e->event_y, 0, NULL);
+ evas_event_feed_mouse_down(evas, e->detail, EVAS_BUTTON_NONE, 0, NULL);
+ break;
+ }
+ case XCB_BUTTON_RELEASE:
+ {
+ xcb_button_release_event_t *e;
+
+ e = (xcb_button_release_event_t *)ev;
+
+ evas_event_feed_mouse_move(evas, e->event_x, e->event_y, 0, NULL);
+ evas_event_feed_mouse_up(evas, e->detail, EVAS_BUTTON_NONE, 0, NULL);
+ break;
+ }
+ case XCB_MOTION_NOTIFY:
+ {
+ xcb_motion_notify_event_t *e;
+
+ e = (xcb_motion_notify_event_t *)ev;
+
+ evas_event_feed_mouse_move(evas, e->event_x, e->event_y, 0, NULL);
+ break;
+ }
+ case XCB_EXPOSE:
+ {
+ xcb_expose_event_t *e;
+
+ e = (xcb_expose_event_t *)ev;
+
+ first_expose = 1;
+ evas_damage_rectangle_add(evas,
+ e->x,
+ e->y,
+ e->width,
+ e->height);
+ break;
+ }
+ case XCB_CONFIGURE_NOTIFY:
+ {
+ xcb_configure_notify_event_t *e;
+
+ e = (xcb_configure_notify_event_t *)ev;
+
+ evas_output_viewport_set(evas, 0, 0,
+ e->width,
+ e->height);
+ evas_output_size_set(evas,
+ e->width,
+ e->height);
+ win_w = e->width;
+ win_h = e->height;
+ break;
+ }
+ case XCB_ENTER_NOTIFY:
+ evas_event_feed_mouse_in(evas, 0, NULL);
+ break;
+ case XCB_LEAVE_NOTIFY:
+ evas_event_feed_mouse_out(evas, 0, NULL);
+ break;
+ case XCB_KEY_PRESS:
+ {
+ xcb_key_press_event_t *e;
+ xcb_key_symbols_t *kss;
+ xcb_keysym_t ks;
+ char *str = "";
+
+ e = (xcb_key_press_event_t *)ev;
+
+ kss = xcb_key_symbols_alloc(conn);
+
+ ks = xcb_key_symbols_get_keysym(kss, e->detail, 0);
+
+ if ((ks == XK_Shift_L) || (ks == XK_Shift_R))
+ evas_key_modifier_on(evas, "Shift");
+ else if ((ks == XK_Control_L) || (ks == XK_Control_R))
+ evas_key_modifier_on(evas, "Control");
+ else if ((ks == XK_Alt_L) || (ks == XK_Alt_R))
+ evas_key_modifier_on(evas, "Alt");
+ else if ((ks == XK_Super_L) || (ks == XK_Super_R))
+ evas_key_modifier_on(evas, "Super");
+ else if (ks == XK_Caps_Lock)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Caps_Lock"))
+ evas_key_lock_off(evas, "Caps_Lock");
+ else
+ evas_key_lock_on(evas, "Caps_Lock");
+ }
+ else if (ks == XK_Scroll_Lock)
+ {
+ if (evas_key_lock_is_set(evas_key_lock_get(evas), "Scroll_Lock"))
+ evas_key_lock_off(evas, "Scroll_Lock");
+ else
+ evas_key_lock_on(evas, "Scroll_Lock");
+ }
+
+ if (ks == XK_Left)
+ str = "Left";
+ if (ks == XK_Right)
+ str = "Right";
+ if (ks == XK_Escape)
+ str = "Escape";
+ if (ks == XK_Return)
+ str = "Return";
+ if (ks == 113)
+ str = "q";
+
+ evas_event_feed_key_down(evas, str, str, NULL, NULL, 0, NULL);
+
+ xcb_key_symbols_free(kss);
+ break;
+ }
+ case XCB_KEY_RELEASE:
+ {
+ xcb_key_release_event_t *e;
+ xcb_key_symbols_t *kss;
+ xcb_keysym_t ks;
+ char *str = "";
+
+ e = (xcb_key_release_event_t *)ev;
+
+ kss = xcb_key_symbols_alloc(conn);
+
+ ks = xcb_key_symbols_get_keysym(kss, e->detail, 0);
+
+ if ((ks == XK_Shift_L) || (ks == XK_Shift_R))
+ evas_key_modifier_on(evas, "Shift");
+ else if ((ks == XK_Control_L) || (ks == XK_Control_R))
+ evas_key_modifier_on(evas, "Control");
+ else if ((ks == XK_Alt_L) || (ks == XK_Alt_R))
+ evas_key_modifier_on(evas, "Alt");
+ else if ((ks == XK_Super_L) || (ks == XK_Super_R))
+ evas_key_modifier_on(evas, "Super");
+
+ if (ks == XK_Left)
+ str = "Left";
+ if (ks == XK_Right)
+ str = "Right";
+ if (ks == XK_Escape)
+ str = "Escape";
+ if (ks == XK_Return)
+ str = "Return";
+ if (ks == 113)
+ str = "q";
+
+ evas_event_feed_key_up(evas, str, str, NULL, NULL, 0, NULL);
+
+ xcb_key_symbols_free(kss);
+ break;
+ }
+ default:
+ free(ev);
+ return;
+ }
+ free(ev);
+
+ goto again;
+}
+
+void
+engine_xrender_xcb_shutdown(void)
+{
+ xcb_destroy_window(conn, win);
+ xcb_disconnect(conn);
+}
--- /dev/null
+#ifndef ENGINE_XRENDER_XCB_H
+#define ENGINE_XRENDER_XCB_H
+
+Eina_Bool engine_xrender_xcb_args(const char *engine, int width, int height);
+void engine_xrender_xcb_loop(void);
+void engine_xrender_xcb_shutdown(void);
+
+#endif
--- /dev/null
+#!/usr/bin/env python
+
+import sys
+import os
+import os.path
+import csv
+from optparse import OptionParser
+
+fmttext = '%(value)7.2f (%(percentual)+6.1f%%)'
+fmthtml = '%(value)7.2f <span style="color: #666; width: 55pt; display: inline-block; text-align: right; text-shadow: #999 1px 1px 3px;">(%(percentual)+0.1f%%)</span>'
+
+
+parser = OptionParser(usage="%prog [options] <reference> <file2> .. <fileN>",
+ description="""\
+Generate reports comparing two or more outputs of expedite.
+
+Just run expedite and save output to a file and then feed them to this
+program. The first file is used as base for comparison and other files
+will print relative improvements.
+""")
+parser.add_option("-e", "--accepted-error",
+ help=("maximum error to accept as percentage 0.0-1.0. "
+ "[default=%default]"),
+ action="store", type="float", default=0.05)
+parser.add_option("-r", "--report",
+ help=("kind of report to use. One of text or html. "
+ "[default=%default]"),
+ action="store", type="choice", default="text",
+ choices=["text", "html"])
+parser.add_option("-F", "--format",
+ help=("format to use as python format string, "
+ "valid keys are: value and percentual. "
+ "[defaults: html=\"%s\", text=\"%s\"]" %
+ (fmthtml, fmttext)),
+ action="store", type="str", default=None)
+parser.add_option("-C", "--no-color", dest="color",
+ help="do not use color in reports.",
+ action="store_false", default=True)
+
+options, files = parser.parse_args()
+if len(files) < 2:
+ raise SystemExit("need at least 2 files to compare")
+
+if options.format is None:
+ if options.report == "html":
+ options.format = fmthtml
+ else:
+ options.format = fmttext
+
+ref_f = files[0]
+others_f = files[1:]
+
+max_test_name = 0
+data = {}
+tests = []
+for f in files:
+ d = data[f] = {}
+ for row in csv.reader(open(f)):
+ t = row[1].strip()
+ if f == ref_f:
+ tests.append(t)
+ d[t] = float(row[0])
+ max_test_name = max(len(t), max_test_name)
+
+def report_text():
+ test_name_fmt = "%%%ds:" % max_test_name
+
+ fmtsize = len(options.format % {"value": 12345.67, "percentual": 1234.56})
+ hdrfmt = "%%%d.%ds" % (fmtsize, fmtsize)
+
+ print test_name_fmt % "\\",
+ print "%7.7s" % (files[0][-7:],),
+ for f in files[1:]:
+ n, e = os.path.splitext(f)
+ print hdrfmt % n[-fmtsize:],
+ print
+
+ if options.color and os.environ.get("TERM", "") in (
+ "xterm", "xterm-color", "rxvt", "rxvt-unicode", "screen",
+ "Eterm", "aterm", "gnome", "interix"):
+ color_good = "\033[1;32m"
+ color_bad = "\033[1;31m"
+ color_equal = "\033[1;30m"
+ color_reset = "\033[0m"
+ else:
+ color_good = ""
+ color_bad = ""
+ color_equal = ""
+ color_reset = ""
+
+
+ def print_row(test):
+ print test_name_fmt % test,
+ ref_val = data[ref_f][test]
+ print "%7.2f" % ref_val,
+ for f in others_f:
+ try:
+ val = data[f][test]
+ except KeyError:
+ print "-?????-",
+ continue
+
+ percent = (val - ref_val) / ref_val
+ if percent < -options.accepted_error:
+ c = color_bad
+ elif percent > options.accepted_error:
+ c = color_good
+ else:
+ c = color_equal
+
+ fmt = options.format % {"value": val, "percentual": percent * 100}
+ if len(fmt) < fmtsize:
+ fmt = hdrfmt % fmt
+ print "%s%s%s" % (c, fmt, color_reset),
+
+ print
+
+ for t in tests:
+ print_row(t)
+
+
+def report_html():
+ import time
+
+ fnames = [os.path.basename(f) for f in files]
+ print """\
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>expedite comparison sheet: %(files)s</title>
+ </head>
+ <style type="text/css">
+ table
+ {
+ border: 1px solid black;
+ border-collapse: collapse;
+ }
+ thead
+ {
+ border-bottom: 1px solid black;
+ }
+ tr.overall-results
+ {
+ border-top: 1px solid black;
+ font-weight: bold;
+ }
+ td.value, td.value-reference, td.value-missing, td.value-good, td.value-bad, td.value-equal
+ {
+ font-family: courier, monospaced;
+ font-size: 10pt;
+ text-align: right;
+ border-left: 1px solid black;
+ border-bottom: 1px dashed #ccc;
+ }
+ td.test-name, thead tr td { text-align: right; }\
+"""
+ if options.color:
+ print """\
+ td.value-good { background-color: #aaffaa; }
+ td.value-bad { background-color: #ffaaaa; }
+ td.value-missing { background-color: #ffffaa; }
+ td.test-name, thead tr td
+ {
+ font-weight: bold;
+ background-color: #d9d9d9;
+ border-bottom: 1px dashed #ccc;
+ }
+"""
+
+ print """
+ </style>
+ <body>
+ <p>Comparison sheet for %(files)s, created at %(date)s.</p>
+ <table>
+ <thead>
+ <tr>
+ <td>\\</td>\
+""" % {"files": ", ".join(fnames),
+ "date": time.asctime(),
+ }
+
+ for f in fnames:
+ print """\
+ <td>%s</td>\
+""" % f
+ print """\
+ </tr>
+ </thead>
+ <tbody>\
+"""
+
+ def print_row(test):
+ ref_val = data[ref_f][test]
+ if "EVAS SPEED" in test.upper():
+ extra_cls = ' class="overall-results"'
+ else:
+ extra_cls = ""
+
+ print """\
+ <tr%s>
+ <td class="test-name">%s</td>
+ <td class="value-reference">%7.2f</td>\
+""" % (extra_cls, test, ref_val)
+
+ for f in others_f:
+ try:
+ val = data[f][test]
+ except KeyError:
+ print """\
+ <td class="value-missing">-?????-</td>\
+"""
+ continue
+
+ percent = (val - ref_val) / ref_val
+ if percent < -options.accepted_error:
+ c = 'bad'
+ elif percent > options.accepted_error:
+ c = 'good'
+ else:
+ c = 'equal'
+
+ v = options.format % {"value": val, "percentual": percent * 100}
+
+ print """\
+ <td class="value-%s">%s</td>\
+""" % (c, v)
+
+ print """\
+ </tr>\
+"""
+
+ for t in tests:
+ print_row(t)
+
+ print """\
+ </tbody>
+ </table>
+ </body>
+</html>
+"""
+
+if options.report == "text":
+ report_text()
+elif options.report == "html":
+ report_html()
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_blur
+#define NAME "Filter Object Blur"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_BLUR);
+ evas_object_filter_param_int_set(o, "radius", 3);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_blur_solid
+#define NAME "Filter Object Blur Solid"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_BLUR);
+ evas_object_filter_param_int_set(o, "radius", 5);
+ evas_object_layer_set(o,1);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_brightness
+#define NAME "Filter Object Brightness"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_BRIGHTNESS);
+ evas_object_filter_param_float_set(o, "adjust", i / (double)OBNUM);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_filter_param_float_set(o_images[i], "adjust",
+ ((i + f) % OBNUM) / (2.0 * OBNUM) - 1);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_brightness_solid
+#define NAME "Filter Object Brightness Solid"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_BRIGHTNESS);
+ evas_object_filter_param_float_set(o, "adjust",
+ i / (2.0 * OBNUM) - 1.0);
+ evas_object_layer_set(o,1);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_filter_param_float_set(o_images[i], "adjust",
+ (((i + f) % OBNUM) * 2.0) / (OBNUM) - 1.0);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_colors
+#define NAME "Filter Object Colors"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+ Evas_Filter filters[3] = {
+ EVAS_FILTER_GREYSCALE,
+ EVAS_FILTER_INVERT,
+ EVAS_FILTER_SEPIA
+ };
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, filters[i % 3]);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_colors_solid
+#define NAME "Filter Object Colors Solid"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+ Evas_Filter filters[3] = {
+ EVAS_FILTER_GREYSCALE,
+ EVAS_FILTER_INVERT,
+ EVAS_FILTER_SEPIA
+ };
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, filters[i % 3]);
+ evas_object_layer_set(o,1);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_greyscale
+#define NAME "Filter Object Greyscale"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_GREYSCALE);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_greyscale_solid
+#define NAME "Filter Object Greyscale Solid"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_GREYSCALE);
+ evas_object_layer_set(o,1);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_invert
+#define NAME "Filter Object Invert"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_INVERT);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_invert_solid
+#define NAME "Filter Object Invert Solid"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_INVERT);
+ evas_object_layer_set(o,1);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_sepia
+#define NAME "Filter Object Sepia"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_SEPIA);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME filter_object_sepia_solid
+#define NAME "Filter Object Sepia Solid"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_filter_set(o, EVAS_FILTER_SEPIA);
+ evas_object_layer_set(o,1);
+ evas_object_show(o);
+ src = o;
+ o_images[i] = src;
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
/* metadata */
#define FNAME image_blend_border_start
#define NAME "Image Blend Border"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
o = evas_object_image_add(evas);
o_images[i] = o;
evas_object_image_file_set(o, build_path("bar.png"), NULL);
- evas_object_image_border_set(o, 8, 8, 8, 8);
+ evas_object_image_border_set(o, 6, 6, 6, 6);
evas_object_show(o);
}
done = 0;
/* metadata */
#define FNAME image_blend_border_recolor_start
#define NAME "Image Blend Border Recolor"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_fade_pow2_unscaled_start
+#define NAME "Image Blend Fade Power 2 Unscaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ int a;
+
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ a = 256 - (1 << ((rnd() % 8) + 1));
+ if (a < 128) a = 128;
+ evas_object_color_set(o, a, a, a, a);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_fade_unscaled_start
+#define NAME "Image Blend Fade Unscaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ int a;
+
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ a = rnd()&0xff;
+ evas_object_color_set(o, a, a, a, a);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_nearest_same_scaled_start
+#define NAME "Image Blend Nearest Same Scaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 40 + ((i % 3) * (w0 / 2));
+ h = 40 + ((i % 3) * (h0 / 2));
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_blend_nearest_scaled_start
#define NAME "Image Blend Nearest Scaled"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_nearest_solid_same_scaled_start
+#define NAME "Image Blend Nearest Solid Same Scaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 40 + ((i % 3) * (w0 / 2));
+ h = 40 + ((i % 3) * (h0 / 2));
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_blend_nearest_solid_scaled_start
#define NAME "Image Blend Nearest Solid Scaled"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude1_start
#define NAME "Image Blend Occlude 1"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude1_few_start
#define NAME "Image Blend Occlude 1 Few"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude1_many_start
#define NAME "Image Blend Occlude 1 Many"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude1_very_many_start
#define NAME "Image Blend Occlude 1 Very Many"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude2_start
#define NAME "Image Blend Occlude 2"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude2_few_start
#define NAME "Image Blend Occlude 2 Few"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude2_many_start
#define NAME "Image Blend Occlude 2 Many"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude2_very_many_start
#define NAME "Image Blend Occlude 2 Very Many"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude3_start
#define NAME "Image Blend Occlude 3"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude3_few_start
#define NAME "Image Blend Occlude 3 Few"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude3_many_start
#define NAME "Image Blend Occlude 3 Many"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_occlude3_very_many_start
#define NAME "Image Blend Occlude 3 Very Many"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_smooth_same_scaled_start
+#define NAME "Image Blend Smooth Same Scaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_smooth_scale_set(o, 1);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 40 + ((i % 3) * (w0 / 2));
+ h = 40 + ((i % 3) * (h0 / 2));
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_blend_smooth_scaled_start
#define NAME "Image Blend Smooth Scaled"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_smooth_solid_same_scaled_start
+#define NAME "Image Blend Smooth Solid Same Scaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_smooth_scale_set(o, 1);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 40 + ((i % 3) * (w0 / 2));
+ h = 40 + ((i % 3) * (h0 / 2));
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_blend_smooth_solid_scaled_start
#define NAME "Image Blend Smooth Solid Scaled"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_solid_border_start
#define NAME "Image Blend Solid Border"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_solid_fade_pow2_unscaled_start
+#define NAME "Image Blend Solid Fade Power 2 Unscaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ int a;
+
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ a = 256 - (1 << ((rnd() % 8) + 1));
+ if (a < 128) a = 128;
+ evas_object_color_set(o, a, a, a, a);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_solid_fade_unscaled_start
+#define NAME "Image Blend Solid Fade Unscaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ int a;
+
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ a = rnd()&0xff;
+ evas_object_color_set(o, a, a, a, a);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_solid_middle_border
+#define NAME "Image Blend Solid Middle Border"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("bar.png"), NULL);
+ evas_object_image_border_set(o, 6, 6, 6, 6);
+ evas_object_image_border_center_fill_set(o, EVAS_BORDER_FILL_SOLID);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 5 + ((1.0 + cos((double)(f + (i * 10)) / (7.4 * SLOW) )) * w0 * 2);
+ h = 5 + ((1.0 + sin((double)(f + (i * 19)) / (12.6 * SLOW) )) * h0 * 2);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_solid_middle_unscaled_start
+#define NAME "Image Blend Solid Middle Unscaled"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_border_set(o, 43, 48, 48, 83);
+ evas_object_image_border_center_fill_set(o, EVAS_BORDER_FILL_SOLID);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_blend_solid_unscaled_start
#define NAME "Image Blend Solid Unscaled"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_blend_unscaled_start
#define NAME "Image Blend Unscaled"
-#define ICON "flower.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_crossfade_start
#define NAME "Image Crossfade"
-#define ICON "mushroom.png"
+#define ICON "blend.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME image_data_argb_start
#define NAME "Image Data ARGB"
-#define ICON "mushroom.png"
+#define ICON "data.png"
#ifndef PROTO
# ifndef UI
{
o = evas_object_image_add(evas);
o_images[i] = o;
+ evas_object_image_content_hint_set(o, EVAS_IMAGE_CONTENT_HINT_DYNAMIC);
evas_object_image_colorspace_set(o, EVAS_COLORSPACE_ARGB8888);
evas_object_image_size_set(o, 640, 480);
evas_object_image_alpha_set(o, 0);
/* loop - do things */
static void _loop(double t, int f)
{
- int i;
+ int i, st;
Evas_Coord x, y, w, h;
for (i = 0; i < 1; i++)
{
unsigned int *data, *p;
- int ff;
+
w = 640;
h = 480;
x = (win_w / 2) - (w / 2);
evas_object_resize(o_images[i], w, h);
evas_object_image_fill_set(o_images[i], 0, 0, w, h);
data = evas_object_image_data_get(o_images[i], 1);
+ st = evas_object_image_stride_get(o_images[i]) >> 2;
p = data;
- ff = (f ^ (f << 8) ^ (f << 16) ^ (f << 24));
- for (y = 0; y < 480; y++)
+ for (y = 0; y < h; y++)
{
- for (x = 0; x < 640; x++)
+ for (x = 0; x < w; x++)
{
*p = ((((x * y) + f) << 8) ^ (x - y - f)) | 0xff000000;
p++;
}
+ p += (st - w);
}
evas_object_image_data_set(o_images[i], data);
- evas_object_image_data_update_add(o_images[i], 0, 0, 640, 480);
+ evas_object_image_data_update_add(o_images[i], 0, 0, w, h);
}
FPS_STD(NAME);
}
/* metadata */
#define FNAME image_data_argb_alpha_start
#define NAME "Image Data ARGB Alpha"
-#define ICON "mushroom.png"
+#define ICON "data.png"
#ifndef PROTO
# ifndef UI
{
o = evas_object_image_add(evas);
o_images[i] = o;
+ evas_object_image_content_hint_set(o, EVAS_IMAGE_CONTENT_HINT_DYNAMIC);
evas_object_image_colorspace_set(o, EVAS_COLORSPACE_ARGB8888);
evas_object_image_size_set(o, 640, 480);
evas_object_image_alpha_set(o, 1);
/* loop - do things */
static void _loop(double t, int f)
{
- int i;
+ int i, st;
Evas_Coord x, y, w, h;
for (i = 0; i < 1; i++)
{
unsigned int *data, *p;
- int ff, a, r, g, b;
+ int a, r, g, b;
w = 640;
h = 480;
x = (win_w / 2) - (w / 2);
evas_object_resize(o_images[i], w, h);
evas_object_image_fill_set(o_images[i], 0, 0, w, h);
data = evas_object_image_data_get(o_images[i], 1);
+ st = evas_object_image_stride_get(o_images[i]) >> 2;
p = data;
- ff = (f ^ (f << 8) ^ (f << 16) ^ (f << 24));
- for (y = 0; y < 480; y++)
+ for (y = 0; y < h; y++)
{
- for (x = 0; x < 640; x++)
+ for (x = 0; x < w; x++)
{
r = (x * y / 7) + f;
g = (x / 2);
*p = (a << 24) | (r << 16) | (g << 8) | b;
p++;
}
+ p += (st - w);
}
evas_object_image_data_set(o_images[i], data);
- evas_object_image_data_update_add(o_images[i], 0, 0, 640, 480);
+ evas_object_image_data_update_add(o_images[i], 0, 0, w, h);
}
FPS_STD(NAME);
}
/* metadata */
#define FNAME image_data_ycbcr601pl_start
#define NAME "Image Data YCbCr 601 Pointer List"
-#define ICON "mushroom.png"
+#define ICON "data.png"
#ifndef PROTO
# ifndef UI
{
int i, y;
FILE *f;
+ size_t r;
unsigned char **data, **lp;
Evas_Object *o;
for (i = 0; i < 1; i++)
{
o = evas_object_image_add(evas);
o_images[i] = o;
+ evas_object_image_content_hint_set(o, EVAS_IMAGE_CONTENT_HINT_DYNAMIC);
evas_object_image_colorspace_set(o, EVAS_COLORSPACE_YCBCR422P601_PL);
evas_object_image_size_set(o, 640, 480);
evas_object_image_alpha_set(o, 0);
f = fopen(build_path("tp.yuv"), "rb");
if (f)
{
- fread(yp, 640 * 480, 1, f);
- fread(up, 320 * 240, 1, f);
- fread(vp, 320 * 240, 1, f);
+ r = fread(yp, 640 * 480, 1, f);
+ r = fread(up, 320 * 240, 1, f);
+ r = fread(vp, 320 * 240, 1, f);
fclose(f);
}
data = evas_object_image_data_get(o_images[i], 1);
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_data_ycbcr601pl_map_nearest_solid_rotate_start
+#define NAME "Image Data YCbCr 601 Pointer List Map Nearest Solid Rotate"
+#define ICON "data.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[1];
+static unsigned char *yp = NULL, *up = NULL, *vp = NULL;
+
+/* setup */
+static void _setup(void)
+{
+ int i, y;
+ FILE *f;
+ unsigned char **data, **lp;
+ size_t r;
+ Evas_Object *o;
+ for (i = 0; i < 1; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_content_hint_set(o, EVAS_IMAGE_CONTENT_HINT_DYNAMIC);
+ evas_object_image_colorspace_set(o, EVAS_COLORSPACE_YCBCR422P601_PL);
+ evas_object_image_size_set(o, 640, 480);
+ evas_object_image_alpha_set(o, 0);
+ evas_object_image_fill_set(o, 0, 0, 640, 480);
+ evas_object_resize(o, 640, 480);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ yp = malloc(640 * 480);
+ up = malloc(320 * 240);
+ vp = malloc(320 * 240);
+ f = fopen(build_path("tp.yuv"), "rb");
+ if (f)
+ {
+ r = fread(yp, 640 * 480, 1, f);
+ r = fread(up, 320 * 240, 1, f);
+ r = fread(vp, 320 * 240, 1, f);
+ fclose(f);
+ }
+ data = evas_object_image_data_get(o_images[i], 1);
+ lp = data;
+ for (y = 0; y < 480; y++)
+ {
+ *lp = yp + (y * 640);
+ lp++;
+ }
+ for (y = 0; y < 240; y++)
+ {
+ *lp = up + (y * 320);
+ lp++;
+ }
+ for (y = 0; y < 240; y++)
+ {
+ *lp = vp + (y * 320);
+ lp++;
+ }
+ evas_object_image_data_set(o_images[i], data);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < 1; i++) evas_object_del(o_images[i]);
+ free(yp);
+ free(up);
+ free(vp);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < 1; i++)
+ {
+ w = 640;
+ h = 480;
+ x = (win_w / 2) - (w / 2);
+ y = (win_h / 2) - (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_data_ycbcr601pl_map_solid_rotate_start
+#define NAME "Image Data YCbCr 601 Pointer List Map Solid Rotate"
+#define ICON "data.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[1];
+static unsigned char *yp = NULL, *up = NULL, *vp = NULL;
+
+/* setup */
+static void _setup(void)
+{
+ int i, y;
+ FILE *f;
+ unsigned char **data, **lp;
+ size_t r;
+ Evas_Object *o;
+ for (i = 0; i < 1; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_content_hint_set(o, EVAS_IMAGE_CONTENT_HINT_DYNAMIC);
+ evas_object_image_colorspace_set(o, EVAS_COLORSPACE_YCBCR422P601_PL);
+ evas_object_image_size_set(o, 640, 480);
+ evas_object_image_alpha_set(o, 0);
+ evas_object_image_fill_set(o, 0, 0, 640, 480);
+ evas_object_resize(o, 640, 480);
+ evas_object_show(o);
+ yp = malloc(640 * 480);
+ up = malloc(320 * 240);
+ vp = malloc(320 * 240);
+ f = fopen(build_path("tp.yuv"), "rb");
+ if (f)
+ {
+ r = fread(yp, 640 * 480, 1, f);
+ r = fread(up, 320 * 240, 1, f);
+ r = fread(vp, 320 * 240, 1, f);
+ fclose(f);
+ }
+ data = evas_object_image_data_get(o_images[i], 1);
+ lp = data;
+ for (y = 0; y < 480; y++)
+ {
+ *lp = yp + (y * 640);
+ lp++;
+ }
+ for (y = 0; y < 240; y++)
+ {
+ *lp = up + (y * 320);
+ lp++;
+ }
+ for (y = 0; y < 240; y++)
+ {
+ *lp = vp + (y * 320);
+ lp++;
+ }
+ evas_object_image_data_set(o_images[i], data);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < 1; i++) evas_object_del(o_images[i]);
+ free(yp);
+ free(up);
+ free(vp);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < 1; i++)
+ {
+ w = 640;
+ h = 480;
+ x = (win_w / 2) - (w / 2);
+ y = (win_h / 2) - (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_data_ycbcr601pl_wide_stride_start
#define NAME "Image Data YCbCr 601 Pointer List Wide Stride"
-#define ICON "mushroom.png"
+#define ICON "data.png"
#ifndef PROTO
# ifndef UI
{
int i, y;
FILE *f;
+ size_t r;
unsigned char **data, **lp;
Evas_Object *o;
for (i = 0; i < 1; i++)
{
o = evas_object_image_add(evas);
o_images[i] = o;
+ evas_object_image_content_hint_set(o, EVAS_IMAGE_CONTENT_HINT_DYNAMIC);
evas_object_image_colorspace_set(o, EVAS_COLORSPACE_YCBCR422P601_PL);
evas_object_image_size_set(o, 320, 480);
evas_object_image_alpha_set(o, 0);
f = fopen(build_path("tp.yuv"), "rb");
if (f)
{
- fread(yp, 640 * 480, 1, f);
- fread(up, 320 * 240, 1, f);
- fread(vp, 320 * 240, 1, f);
+ r = fread(yp, 640 * 480, 1, f);
+ r = fread(up, 320 * 240, 1, f);
+ r = fread(vp, 320 * 240, 1, f);
fclose(f);
}
data = evas_object_image_data_get(o_images[i], 1);
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_1_start
+#define NAME "Image Map 3D 1"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+typedef struct _Point
+{
+ Evas_Coord x, y, z, u, v;
+} Point;
+
+typedef struct _Side
+{
+ Evas_Object *o;
+ Point pt[4];
+} Side;
+
+typedef struct _Cube
+{
+ Side side[6];
+} Cube;
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Cube *cubes[5];
+
+#define POINT(n, p, xx, yy, zz, uu, vv) \
+ c->side[n].pt[p].x = xx; \
+ c->side[n].pt[p].y = yy; \
+ c->side[n].pt[p].z = zz; \
+ c->side[n].pt[p].u = uu; \
+ c->side[n].pt[p].v = vv
+
+static Cube *
+_cube_new(Evas_Coord w, Evas_Coord h, Evas_Coord d)
+{
+ Cube *c;
+ int i;
+
+ w -= (w / 2);
+ h -= (h / 2);
+ d -= (d / 2);
+ c = calloc(1, sizeof(Cube));
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Object *o;
+ char buf[256];
+ o = evas_object_image_add(evas);
+ c->side[i].o = o;
+ snprintf(buf, sizeof(buf), "cube%i.png", i + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 256, 256);
+ evas_object_resize(o, 256, 256);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ POINT(0, 0, -w, -h, -d, 0, 0);
+ POINT(0, 1, w, -h, -d, 256, 0);
+ POINT(0, 2, w, h, -d, 256, 256);
+ POINT(0, 3, -w, h, -d, 0, 256);
+
+ POINT(1, 0, w, -h, -d, 0, 0);
+ POINT(1, 1, w, -h, d, 256, 0);
+ POINT(1, 2, w, h, d, 256, 256);
+ POINT(1, 3, w, h, -d, 0, 256);
+
+ POINT(2, 0, w, -h, d, 0, 0);
+ POINT(2, 1, -w, -h, d, 256, 0);
+ POINT(2, 2, -w, h, d, 256, 256);
+ POINT(2, 3, w, h, d, 0, 256);
+
+ POINT(3, 0, -w, -h, d, 0, 0);
+ POINT(3, 1, -w, -h, -d, 256, 0);
+ POINT(3, 2, -w, h, -d, 256, 256);
+ POINT(3, 3, -w, h, d, 0, 256);
+
+ POINT(4, 0, -w, -h, d, 0, 0);
+ POINT(4, 1, w, -h, d, 256, 0);
+ POINT(4, 2, w, -h, -d, 256, 256);
+ POINT(4, 3, -w, -h, -d, 0, 256);
+
+ POINT(5, 0, -w, h, -d, 0, 0);
+ POINT(5, 1, w, h, -d, 256, 0);
+ POINT(5, 2, w, h, d, 256, 256);
+ POINT(5, 3, -w, h, d, 0, 256);
+
+ return c;
+}
+
+static void
+_cube_pos(Cube *c,
+ Evas_Coord x, Evas_Coord y, Evas_Coord z,
+ double dx, double dy, double dz)
+{
+ static Evas_Map *m = NULL;
+ int i, j, order[6], sorted;
+ Evas_Coord mz[6];
+
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Coord tz[4];
+
+ for (j = 0; j < 4; j++)
+ {
+ evas_map_point_coord_set(m, j,
+ c->side[i].pt[j].x + x,
+ c->side[i].pt[j].y + y,
+ c->side[i].pt[j].z + z);
+ evas_map_point_image_uv_set(m, j,
+ c->side[i].pt[j].u,
+ c->side[i].pt[j].v);
+ evas_map_point_color_set(m, j, 255, 255, 255, 255);
+ }
+ evas_map_util_3d_rotate(m, dx, dy, dz, x, y, z);
+ evas_map_util_3d_lighting(m, -1000, -1000, -1000,
+ 255, 255, 255,
+ 20, 20, 20);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), 0, 512);
+ if (evas_map_util_clockwise_get(m))
+ {
+ evas_object_map_enable_set(c->side[i].o, 1);
+ evas_object_map_set(c->side[i].o, m);
+ evas_object_show(c->side[i].o);
+ }
+ else
+ evas_object_hide(c->side[i].o);
+
+ order[i] = i;
+ for (j = 0; j < 4; j++)
+ evas_map_point_coord_get(m, j, NULL, NULL, &(tz[j]));
+ mz[i] = (tz[0] + tz[1] + tz[2] + tz[3]) / 4;
+ }
+ sorted = 0;
+ do
+ {
+ sorted = 1;
+ for (i = 0; i < 5; i++)
+ {
+ if (mz[order[i]] > mz[order[i + 1]])
+ {
+ j = order[i];
+ order[i] = order[i + 1];
+ order[i + 1] = j;
+ sorted = 0;
+ }
+ }
+ }
+ while (!sorted);
+
+ evas_object_raise(c->side[order[0]].o);
+ for (i = 1; i < 6; i++)
+ evas_object_stack_below(c->side[order[i]].o, c->side[order[i - 1]].o);
+}
+
+static void
+_cube_free(Cube *c)
+{
+ int i;
+
+ for (i = 0; i < 6; i++) evas_object_del(c->side[i].o);
+ free(c);
+}
+
+/* setup */
+static void _setup(void)
+{
+ cubes[0] = _cube_new(128, 128, 256);
+ cubes[1] = _cube_new(256, 128, 128);
+ cubes[2] = _cube_new(256, 256, 128);
+ cubes[3] = _cube_new(128, 256, 128);
+ cubes[4] = _cube_new(256, 256, 256);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ _cube_free(cubes[0]);
+ _cube_free(cubes[1]);
+ _cube_free(cubes[2]);
+ _cube_free(cubes[3]);
+ _cube_free(cubes[4]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ _cube_pos(cubes[0],
+ (win_w / 2) - 640, (win_h / 2) - 256, 512,
+ f / 2.0, f, f / 3.0);
+ _cube_pos(cubes[1],
+ (win_w / 2) + 512, (win_h / 2) - 128, 384,
+ f / 3.0, f / 2.0, f / 4.0);
+ _cube_pos(cubes[2],
+ (win_w / 2) - 384, (win_h / 2) + 128, 256,
+ f / 2.0, f / 3.0, f);
+ _cube_pos(cubes[3],
+ (win_w / 2) + 256, (win_h / 2) + 64, 128,
+ f, f / 5.0, f / 2.0);
+ _cube_pos(cubes[4],
+ (win_w / 2), (win_h / 2), 0,
+ f / 4.0, f / 3.0, f / 5.0);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_2_start
+#define NAME "Image Map 3D 2"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+typedef struct _Point
+{
+ Evas_Coord x, y, z, u, v;
+} Point;
+
+typedef struct _Side
+{
+ Evas_Object *o;
+ Point pt[4];
+} Side;
+
+typedef struct _Cube
+{
+ Side side[6];
+} Cube;
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Cube *cubes[5];
+
+#define POINT(n, p, xx, yy, zz, uu, vv) \
+ c->side[n].pt[p].x = xx; \
+ c->side[n].pt[p].y = yy; \
+ c->side[n].pt[p].z = zz; \
+ c->side[n].pt[p].u = uu; \
+ c->side[n].pt[p].v = vv
+
+static Cube *
+_cube_new(Evas_Coord w, Evas_Coord h, Evas_Coord d)
+{
+ Cube *c;
+ int i;
+
+ w -= (w / 2);
+ h -= (h / 2);
+ d -= (d / 2);
+ c = calloc(1, sizeof(Cube));
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Object *o;
+ char buf[256];
+ o = evas_object_image_add(evas);
+ c->side[i].o = o;
+ snprintf(buf, sizeof(buf), "cube%i.png", i + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 256, 256);
+ evas_object_resize(o, 256, 256);
+ evas_object_show(o);
+ }
+ POINT(0, 0, -w, -h, -d, 0, 0);
+ POINT(0, 1, w, -h, -d, 256, 0);
+ POINT(0, 2, w, h, -d, 256, 256);
+ POINT(0, 3, -w, h, -d, 0, 256);
+
+ POINT(1, 0, w, -h, -d, 0, 0);
+ POINT(1, 1, w, -h, d, 256, 0);
+ POINT(1, 2, w, h, d, 256, 256);
+ POINT(1, 3, w, h, -d, 0, 256);
+
+ POINT(2, 0, w, -h, d, 0, 0);
+ POINT(2, 1, -w, -h, d, 256, 0);
+ POINT(2, 2, -w, h, d, 256, 256);
+ POINT(2, 3, w, h, d, 0, 256);
+
+ POINT(3, 0, -w, -h, d, 0, 0);
+ POINT(3, 1, -w, -h, -d, 256, 0);
+ POINT(3, 2, -w, h, -d, 256, 256);
+ POINT(3, 3, -w, h, d, 0, 256);
+
+ POINT(4, 0, -w, -h, d, 0, 0);
+ POINT(4, 1, w, -h, d, 256, 0);
+ POINT(4, 2, w, -h, -d, 256, 256);
+ POINT(4, 3, -w, -h, -d, 0, 256);
+
+ POINT(5, 0, -w, h, -d, 0, 0);
+ POINT(5, 1, w, h, -d, 256, 0);
+ POINT(5, 2, w, h, d, 256, 256);
+ POINT(5, 3, -w, h, d, 0, 256);
+
+ return c;
+}
+
+static void
+_cube_pos(Cube *c,
+ Evas_Coord x, Evas_Coord y, Evas_Coord z,
+ double dx, double dy, double dz)
+{
+ static Evas_Map *m = NULL;
+ int i, j, order[6], sorted;
+ Evas_Coord mz[6];
+
+ if (!m) m = evas_map_new(4);
+
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Coord tz[4];
+
+ for (j = 0; j < 4; j++)
+ {
+ evas_map_point_coord_set(m, j,
+ c->side[i].pt[j].x + x,
+ c->side[i].pt[j].y + y,
+ c->side[i].pt[j].z + z);
+ evas_map_point_image_uv_set(m, j,
+ c->side[i].pt[j].u,
+ c->side[i].pt[j].v);
+ evas_map_point_color_set(m, j, 255, 255, 255, 255);
+ }
+ evas_map_util_3d_rotate(m, dx, dy, dz, x, y, z);
+ evas_map_util_3d_lighting(m, -1000, -1000, -1000,
+ 255, 255, 255,
+ 20, 20, 20);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), 0, 512);
+ if (evas_map_util_clockwise_get(m))
+ {
+ evas_object_map_enable_set(c->side[i].o, 1);
+ evas_object_map_set(c->side[i].o, m);
+ evas_object_show(c->side[i].o);
+ }
+ else
+ evas_object_hide(c->side[i].o);
+
+ order[i] = i;
+ for (j = 0; j < 4; j++)
+ evas_map_point_coord_get(m, j, NULL, NULL, &(tz[j]));
+ mz[i] = (tz[0] + tz[1] + tz[2] + tz[3]) / 4;
+ }
+ sorted = 0;
+ do
+ {
+ sorted = 1;
+ for (i = 0; i < 5; i++)
+ {
+ if (mz[order[i]] > mz[order[i + 1]])
+ {
+ j = order[i];
+ order[i] = order[i + 1];
+ order[i + 1] = j;
+ sorted = 0;
+ }
+ }
+ }
+ while (!sorted);
+
+ evas_object_raise(c->side[order[0]].o);
+ for (i = 1; i < 6; i++)
+ evas_object_stack_below(c->side[order[i]].o, c->side[order[i - 1]].o);
+}
+
+static void
+_cube_free(Cube *c)
+{
+ int i;
+
+ for (i = 0; i < 6; i++) evas_object_del(c->side[i].o);
+ free(c);
+}
+
+/* setup */
+static void _setup(void)
+{
+ cubes[0] = _cube_new(128, 128, 256);
+ cubes[1] = _cube_new(256, 128, 128);
+ cubes[2] = _cube_new(256, 256, 128);
+ cubes[3] = _cube_new(128, 256, 128);
+ cubes[4] = _cube_new(256, 256, 256);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ _cube_free(cubes[0]);
+ _cube_free(cubes[1]);
+ _cube_free(cubes[2]);
+ _cube_free(cubes[3]);
+ _cube_free(cubes[4]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ _cube_pos(cubes[0],
+ (win_w / 2) - 640, (win_h / 2) - 256, 512,
+ f / 2.0, f, f / 3.0);
+ _cube_pos(cubes[1],
+ (win_w / 2) + 512, (win_h / 2) - 128, 384,
+ f / 3.0, f / 2.0, f / 4.0);
+ _cube_pos(cubes[2],
+ (win_w / 2) - 384, (win_h / 2) + 128, 256,
+ f / 2.0, f / 3.0, f);
+ _cube_pos(cubes[3],
+ (win_w / 2) + 256, (win_h / 2) + 64, 128,
+ f, f / 5.0, f / 2.0);
+ _cube_pos(cubes[4],
+ (win_w / 2), (win_h / 2), 0,
+ f / 4.0, f / 3.0, f / 5.0);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_3_start
+#define NAME "Image Map 3D 3"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+typedef struct _Point
+{
+ Evas_Coord x, y, z, u, v;
+} Point;
+
+typedef struct _Side
+{
+ Evas_Object *o;
+ Point pt[4];
+} Side;
+
+typedef struct _Cube
+{
+ Side side[6];
+} Cube;
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Cube *cubes[5];
+
+#define POINT(n, p, xx, yy, zz, uu, vv) \
+ c->side[n].pt[p].x = xx; \
+ c->side[n].pt[p].y = yy; \
+ c->side[n].pt[p].z = zz; \
+ c->side[n].pt[p].u = uu; \
+ c->side[n].pt[p].v = vv
+
+static Cube *
+_cube_new(Evas_Coord w, Evas_Coord h, Evas_Coord d)
+{
+ Cube *c;
+ int i;
+
+ w -= (w / 2);
+ h -= (h / 2);
+ d -= (d / 2);
+ c = calloc(1, sizeof(Cube));
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Object *o;
+ char buf[256];
+ o = evas_object_image_add(evas);
+ c->side[i].o = o;
+ snprintf(buf, sizeof(buf), "cube%i.png", i + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 256, 256);
+ evas_object_resize(o, 256, 256);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ POINT(0, 0, -w, -h, -d, 0, 0);
+ POINT(0, 1, w, -h, -d, 256, 0);
+ POINT(0, 2, w, h, -d, 256, 256);
+ POINT(0, 3, -w, h, -d, 0, 256);
+
+ POINT(1, 0, w, -h, -d, 0, 0);
+ POINT(1, 1, w, -h, d, 256, 0);
+ POINT(1, 2, w, h, d, 256, 256);
+ POINT(1, 3, w, h, -d, 0, 256);
+
+ POINT(2, 0, w, -h, d, 0, 0);
+ POINT(2, 1, -w, -h, d, 256, 0);
+ POINT(2, 2, -w, h, d, 256, 256);
+ POINT(2, 3, w, h, d, 0, 256);
+
+ POINT(3, 0, -w, -h, d, 0, 0);
+ POINT(3, 1, -w, -h, -d, 256, 0);
+ POINT(3, 2, -w, h, -d, 256, 256);
+ POINT(3, 3, -w, h, d, 0, 256);
+
+ POINT(4, 0, -w, -h, d, 0, 0);
+ POINT(4, 1, w, -h, d, 256, 0);
+ POINT(4, 2, w, -h, -d, 256, 256);
+ POINT(4, 3, -w, -h, -d, 0, 256);
+
+ POINT(5, 0, -w, h, -d, 0, 0);
+ POINT(5, 1, w, h, -d, 256, 0);
+ POINT(5, 2, w, h, d, 256, 256);
+ POINT(5, 3, -w, h, d, 0, 256);
+
+ return c;
+}
+
+static void
+_cube_pos(Cube *c,
+ Evas_Coord x, Evas_Coord y, Evas_Coord z,
+ double dx, double dy, double dz)
+{
+ static Evas_Map *m = NULL;
+ int i, j, order[6], sorted;
+ Evas_Coord mz[6];
+
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Coord tz[4];
+
+ for (j = 0; j < 4; j++)
+ {
+ evas_map_point_coord_set(m, j,
+ c->side[i].pt[j].x + x,
+ c->side[i].pt[j].y + y,
+ c->side[i].pt[j].z + z);
+ evas_map_point_image_uv_set(m, j,
+ c->side[i].pt[j].u,
+ c->side[i].pt[j].v);
+ evas_map_point_color_set(m, j, 255, 255, 255, 128);
+ }
+ evas_map_util_3d_rotate(m, dx, dy, dz, x, y, z);
+ evas_map_util_3d_lighting(m, -1000, -1000, -1000,
+ 255, 255, 255,
+ 20, 20, 20);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), 0, 512);
+ evas_object_map_enable_set(c->side[i].o, 1);
+ evas_object_map_set(c->side[i].o, m);
+
+ order[i] = i;
+ for (j = 0; j < 4; j++)
+ evas_map_point_coord_get(m, j, NULL, NULL, &(tz[j]));
+ mz[i] = (tz[0] + tz[1] + tz[2] + tz[3]) / 4;
+ }
+ sorted = 0;
+ do
+ {
+ sorted = 1;
+ for (i = 0; i < 5; i++)
+ {
+ if (mz[order[i]] > mz[order[i + 1]])
+ {
+ j = order[i];
+ order[i] = order[i + 1];
+ order[i + 1] = j;
+ sorted = 0;
+ }
+ }
+ }
+ while (!sorted);
+
+ evas_object_raise(c->side[order[0]].o);
+ for (i = 1; i < 6; i++)
+ evas_object_stack_below(c->side[order[i]].o, c->side[order[i - 1]].o);
+}
+
+static void
+_cube_free(Cube *c)
+{
+ int i;
+
+ for (i = 0; i < 6; i++) evas_object_del(c->side[i].o);
+ free(c);
+}
+
+/* setup */
+static void _setup(void)
+{
+ cubes[0] = _cube_new(128, 128, 256);
+ cubes[1] = _cube_new(256, 128, 128);
+ cubes[2] = _cube_new(256, 256, 128);
+ cubes[3] = _cube_new(128, 256, 128);
+ cubes[4] = _cube_new(256, 256, 256);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ _cube_free(cubes[0]);
+ _cube_free(cubes[1]);
+ _cube_free(cubes[2]);
+ _cube_free(cubes[3]);
+ _cube_free(cubes[4]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ _cube_pos(cubes[0],
+ (win_w / 2) - 640, (win_h / 2) - 256, 512,
+ f / 2.0, f, f / 3.0);
+ _cube_pos(cubes[1],
+ (win_w / 2) + 512, (win_h / 2) - 128, 384,
+ f / 3.0, f / 2.0, f / 4.0);
+ _cube_pos(cubes[2],
+ (win_w / 2) - 384, (win_h / 2) + 128, 256,
+ f / 2.0, f / 3.0, f);
+ _cube_pos(cubes[3],
+ (win_w / 2) + 256, (win_h / 2) + 64, 128,
+ f, f / 5.0, f / 2.0);
+ _cube_pos(cubes[4],
+ (win_w / 2), (win_h / 2), 0,
+ f / 4.0, f / 3.0, f / 5.0);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_4_start
+#define NAME "Image Map 3D 4"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+typedef struct _Point
+{
+ Evas_Coord x, y, z, u, v;
+} Point;
+
+typedef struct _Side
+{
+ Evas_Object *o;
+ Point pt[4];
+} Side;
+
+typedef struct _Cube
+{
+ Side side[6];
+} Cube;
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Cube *cubes[5];
+
+#define POINT(n, p, xx, yy, zz, uu, vv) \
+ c->side[n].pt[p].x = xx; \
+ c->side[n].pt[p].y = yy; \
+ c->side[n].pt[p].z = zz; \
+ c->side[n].pt[p].u = uu; \
+ c->side[n].pt[p].v = vv
+
+static Cube *
+_cube_new(Evas_Coord w, Evas_Coord h, Evas_Coord d)
+{
+ Cube *c;
+ int i;
+
+ w -= (w / 2);
+ h -= (h / 2);
+ d -= (d / 2);
+ c = calloc(1, sizeof(Cube));
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Object *o;
+ char buf[256];
+ o = evas_object_image_add(evas);
+ c->side[i].o = o;
+ snprintf(buf, sizeof(buf), "cube%i.png", i + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 256, 256);
+ evas_object_resize(o, 256, 256);
+ evas_object_show(o);
+ }
+ POINT(0, 0, -w, -h, -d, 0, 0);
+ POINT(0, 1, w, -h, -d, 256, 0);
+ POINT(0, 2, w, h, -d, 256, 256);
+ POINT(0, 3, -w, h, -d, 0, 256);
+
+ POINT(1, 0, w, -h, -d, 0, 0);
+ POINT(1, 1, w, -h, d, 256, 0);
+ POINT(1, 2, w, h, d, 256, 256);
+ POINT(1, 3, w, h, -d, 0, 256);
+
+ POINT(2, 0, w, -h, d, 0, 0);
+ POINT(2, 1, -w, -h, d, 256, 0);
+ POINT(2, 2, -w, h, d, 256, 256);
+ POINT(2, 3, w, h, d, 0, 256);
+
+ POINT(3, 0, -w, -h, d, 0, 0);
+ POINT(3, 1, -w, -h, -d, 256, 0);
+ POINT(3, 2, -w, h, -d, 256, 256);
+ POINT(3, 3, -w, h, d, 0, 256);
+
+ POINT(4, 0, -w, -h, d, 0, 0);
+ POINT(4, 1, w, -h, d, 256, 0);
+ POINT(4, 2, w, -h, -d, 256, 256);
+ POINT(4, 3, -w, -h, -d, 0, 256);
+
+ POINT(5, 0, -w, h, -d, 0, 0);
+ POINT(5, 1, w, h, -d, 256, 0);
+ POINT(5, 2, w, h, d, 256, 256);
+ POINT(5, 3, -w, h, d, 0, 256);
+
+ return c;
+}
+
+static void
+_cube_pos(Cube *c,
+ Evas_Coord x, Evas_Coord y, Evas_Coord z,
+ double dx, double dy, double dz)
+{
+ static Evas_Map *m = NULL;
+ int i, j, order[6], sorted;
+ Evas_Coord mz[6];
+
+ if (!m) m = evas_map_new(4);
+
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Coord tz[4];
+
+ for (j = 0; j < 4; j++)
+ {
+ evas_map_point_coord_set(m, j,
+ c->side[i].pt[j].x + x,
+ c->side[i].pt[j].y + y,
+ c->side[i].pt[j].z + z);
+ evas_map_point_image_uv_set(m, j,
+ c->side[i].pt[j].u,
+ c->side[i].pt[j].v);
+ evas_map_point_color_set(m, j, 255, 255, 255, 128);
+ }
+ evas_map_util_3d_rotate(m, dx, dy, dz, x, y, z);
+ evas_map_util_3d_lighting(m, -1000, -1000, -1000,
+ 255, 255, 255,
+ 20, 20, 20);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), 0, 512);
+ evas_object_map_enable_set(c->side[i].o, 1);
+ evas_object_map_set(c->side[i].o, m);
+
+ order[i] = i;
+ for (j = 0; j < 4; j++)
+ evas_map_point_coord_get(m, j, NULL, NULL, &(tz[j]));
+ mz[i] = (tz[0] + tz[1] + tz[2] + tz[3]) / 4;
+ }
+ sorted = 0;
+ do
+ {
+ sorted = 1;
+ for (i = 0; i < 5; i++)
+ {
+ if (mz[order[i]] > mz[order[i + 1]])
+ {
+ j = order[i];
+ order[i] = order[i + 1];
+ order[i + 1] = j;
+ sorted = 0;
+ }
+ }
+ }
+ while (!sorted);
+
+ evas_object_raise(c->side[order[0]].o);
+ for (i = 1; i < 6; i++)
+ evas_object_stack_below(c->side[order[i]].o, c->side[order[i - 1]].o);
+}
+
+static void
+_cube_free(Cube *c)
+{
+ int i;
+
+ for (i = 0; i < 6; i++) evas_object_del(c->side[i].o);
+ free(c);
+}
+
+/* setup */
+static void _setup(void)
+{
+ cubes[0] = _cube_new(128, 128, 256);
+ cubes[1] = _cube_new(256, 128, 128);
+ cubes[2] = _cube_new(256, 256, 128);
+ cubes[3] = _cube_new(128, 256, 128);
+ cubes[4] = _cube_new(256, 256, 256);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ _cube_free(cubes[0]);
+ _cube_free(cubes[1]);
+ _cube_free(cubes[2]);
+ _cube_free(cubes[3]);
+ _cube_free(cubes[4]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ _cube_pos(cubes[0],
+ (win_w / 2) - 640, (win_h / 2) - 256, 512,
+ f / 2.0, f, f / 3.0);
+ _cube_pos(cubes[1],
+ (win_w / 2) + 512, (win_h / 2) - 128, 384,
+ f / 3.0, f / 2.0, f / 4.0);
+ _cube_pos(cubes[2],
+ (win_w / 2) - 384, (win_h / 2) + 128, 256,
+ f / 2.0, f / 3.0, f);
+ _cube_pos(cubes[3],
+ (win_w / 2) + 256, (win_h / 2) + 64, 128,
+ f, f / 5.0, f / 2.0);
+ _cube_pos(cubes[4],
+ (win_w / 2), (win_h / 2), 0,
+ f / 4.0, f / 3.0, f / 5.0);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_5_start
+#define NAME "Image Map 3D 5"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+typedef struct _Point
+{
+ Evas_Coord x, y, z, u, v;
+} Point;
+
+typedef struct _Side
+{
+ Evas_Object *o;
+ Point pt[4];
+} Side;
+
+typedef struct _Cube
+{
+ Side side[6];
+} Cube;
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Cube *cubes[1];
+
+#define POINT(n, p, xx, yy, zz, uu, vv) \
+ c->side[n].pt[p].x = xx; \
+ c->side[n].pt[p].y = yy; \
+ c->side[n].pt[p].z = zz; \
+ c->side[n].pt[p].u = uu; \
+ c->side[n].pt[p].v = vv
+
+static Cube *
+_cube_new(Evas_Coord w, Evas_Coord h, Evas_Coord d)
+{
+ Cube *c;
+ int i;
+
+ w -= (w / 2);
+ h -= (h / 2);
+ d -= (d / 2);
+ c = calloc(1, sizeof(Cube));
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Object *o;
+ char buf[256];
+ o = evas_object_image_add(evas);
+ c->side[i].o = o;
+ snprintf(buf, sizeof(buf), "im%i.png", (i % 2) + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ POINT(0, 0, -w, -h, -d, 0, 0);
+ POINT(0, 1, w, -h, -d, 720, 0);
+ POINT(0, 2, w, h, -d, 720, 420);
+ POINT(0, 3, -w, h, -d, 0, 420);
+
+ POINT(1, 0, w, -h, -d, 0, 0);
+ POINT(1, 1, w, -h, d, 720, 0);
+ POINT(1, 2, w, h, d, 720, 420);
+ POINT(1, 3, w, h, -d, 0, 420);
+
+ POINT(2, 0, w, -h, d, 0, 0);
+ POINT(2, 1, -w, -h, d, 720, 0);
+ POINT(2, 2, -w, h, d, 720, 420);
+ POINT(2, 3, w, h, d, 0, 420);
+
+ POINT(3, 0, -w, -h, d, 0, 0);
+ POINT(3, 1, -w, -h, -d, 720, 0);
+ POINT(3, 2, -w, h, -d, 720, 420);
+ POINT(3, 3, -w, h, d, 0, 420);
+
+ POINT(4, 0, -w, -h, d, 0, 0);
+ POINT(4, 1, w, -h, d, 720, 0);
+ POINT(4, 2, w, -h, -d, 720, 420);
+ POINT(4, 3, -w, -h, -d, 0, 420);
+
+ POINT(5, 0, -w, h, -d, 0, 0);
+ POINT(5, 1, w, h, -d, 720, 0);
+ POINT(5, 2, w, h, d, 720, 420);
+ POINT(5, 3, -w, h, d, 0, 420);
+
+ return c;
+}
+
+static void
+_cube_pos(Cube *c,
+ Evas_Coord x, Evas_Coord y, Evas_Coord z,
+ double dx, double dy, double dz)
+{
+ static Evas_Map *m = NULL;
+ int i, j, order[6], sorted;
+ Evas_Coord mz[6];
+
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Coord tz[4];
+
+ for (j = 0; j < 4; j++)
+ {
+ evas_map_point_coord_set(m, j,
+ c->side[i].pt[j].x + x,
+ c->side[i].pt[j].y + y,
+ c->side[i].pt[j].z + z);
+ evas_map_point_image_uv_set(m, j,
+ c->side[i].pt[j].u,
+ c->side[i].pt[j].v);
+ evas_map_point_color_set(m, j, 255, 255, 255, 255);
+ }
+ evas_map_util_3d_rotate(m, dx, dy, dz, x, y, z);
+ evas_map_util_3d_lighting(m, -1000, win_h / 2, -1000,
+ 255, 255, 255,
+ 20, 20, 20);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), -360, 720);
+ if (evas_map_util_clockwise_get(m))
+ {
+ evas_object_map_enable_set(c->side[i].o, 1);
+ evas_object_map_set(c->side[i].o, m);
+ evas_object_show(c->side[i].o);
+ }
+ else
+ evas_object_hide(c->side[i].o);
+
+ order[i] = i;
+ for (j = 0; j < 4; j++)
+ evas_map_point_coord_get(m, j, NULL, NULL, &(tz[j]));
+ mz[i] = (tz[0] + tz[1] + tz[2] + tz[3]) / 4;
+ }
+ sorted = 0;
+ do
+ {
+ sorted = 1;
+ for (i = 0; i < 5; i++)
+ {
+ if (mz[order[i]] > mz[order[i + 1]])
+ {
+ j = order[i];
+ order[i] = order[i + 1];
+ order[i + 1] = j;
+ sorted = 0;
+ }
+ }
+ }
+ while (!sorted);
+
+ evas_object_raise(c->side[order[0]].o);
+ for (i = 1; i < 6; i++)
+ evas_object_stack_below(c->side[order[i]].o, c->side[order[i - 1]].o);
+}
+
+static void
+_cube_free(Cube *c)
+{
+ int i;
+
+ for (i = 0; i < 6; i++) evas_object_del(c->side[i].o);
+ free(c);
+}
+
+/* setup */
+static void _setup(void)
+{
+ cubes[0] = _cube_new(720, 420, 720);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ _cube_free(cubes[0]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ _cube_pos(cubes[0],
+ (win_w / 2), (win_h / 2), 0,
+ 0, f, 0);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_6_start
+#define NAME "Image Map 3D 6"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+typedef struct _Point
+{
+ Evas_Coord x, y, z, u, v;
+} Point;
+
+typedef struct _Side
+{
+ Evas_Object *o;
+ Point pt[4];
+} Side;
+
+typedef struct _Cube
+{
+ Side side[6];
+} Cube;
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Cube *cubes[1];
+
+#define POINT(n, p, xx, yy, zz, uu, vv) \
+ c->side[n].pt[p].x = xx; \
+ c->side[n].pt[p].y = yy; \
+ c->side[n].pt[p].z = zz; \
+ c->side[n].pt[p].u = uu; \
+ c->side[n].pt[p].v = vv
+
+static Cube *
+_cube_new(Evas_Coord w, Evas_Coord h, Evas_Coord d)
+{
+ Cube *c;
+ int i;
+
+ w -= (w / 2);
+ h -= (h / 2);
+ d -= (d / 2);
+ c = calloc(1, sizeof(Cube));
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Object *o;
+ char buf[256];
+ o = evas_object_image_add(evas);
+ c->side[i].o = o;
+ snprintf(buf, sizeof(buf), "im%i.png", (i % 2) + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ POINT(0, 0, -w, -h, -d, 0, 0);
+ POINT(0, 1, w, -h, -d, 720, 0);
+ POINT(0, 2, w, h, -d, 720, 420);
+ POINT(0, 3, -w, h, -d, 0, 420);
+
+ POINT(1, 0, w, -h, -d, 0, 0);
+ POINT(1, 1, w, -h, d, 720, 0);
+ POINT(1, 2, w, h, d, 720, 420);
+ POINT(1, 3, w, h, -d, 0, 420);
+
+ POINT(2, 0, w, -h, d, 0, 0);
+ POINT(2, 1, -w, -h, d, 720, 0);
+ POINT(2, 2, -w, h, d, 720, 420);
+ POINT(2, 3, w, h, d, 0, 420);
+
+ POINT(3, 0, -w, -h, d, 0, 0);
+ POINT(3, 1, -w, -h, -d, 720, 0);
+ POINT(3, 2, -w, h, -d, 720, 420);
+ POINT(3, 3, -w, h, d, 0, 420);
+
+ POINT(4, 0, -w, -h, d, 0, 0);
+ POINT(4, 1, w, -h, d, 720, 0);
+ POINT(4, 2, w, -h, -d, 720, 420);
+ POINT(4, 3, -w, -h, -d, 0, 420);
+
+ POINT(5, 0, -w, h, -d, 0, 0);
+ POINT(5, 1, w, h, -d, 720, 0);
+ POINT(5, 2, w, h, d, 720, 420);
+ POINT(5, 3, -w, h, d, 0, 420);
+
+ return c;
+}
+
+static void
+_cube_pos(Cube *c,
+ Evas_Coord x, Evas_Coord y, Evas_Coord z,
+ double dx, double dy, double dz)
+{
+ static Evas_Map *m = NULL;
+ int i, j, order[6], sorted;
+ Evas_Coord mz[6];
+
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+
+ for (i = 0; i < 6; i++)
+ {
+ Evas_Coord tz[4];
+
+ for (j = 0; j < 4; j++)
+ {
+ evas_map_point_coord_set(m, j,
+ c->side[i].pt[j].x + x,
+ c->side[i].pt[j].y + y,
+ c->side[i].pt[j].z + z);
+ evas_map_point_image_uv_set(m, j,
+ c->side[i].pt[j].u,
+ c->side[i].pt[j].v);
+ evas_map_point_color_set(m, j, 255, 255, 255, 255);
+ }
+ evas_map_util_3d_rotate(m, dx, dy, dz, x, y, z);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), -360, 720);
+ if (evas_map_util_clockwise_get(m))
+ {
+ evas_object_map_enable_set(c->side[i].o, 1);
+ evas_object_map_set(c->side[i].o, m);
+ evas_object_show(c->side[i].o);
+ }
+ else
+ evas_object_hide(c->side[i].o);
+
+ order[i] = i;
+ for (j = 0; j < 4; j++)
+ evas_map_point_coord_get(m, j, NULL, NULL, &(tz[j]));
+ mz[i] = (tz[0] + tz[1] + tz[2] + tz[3]) / 4;
+ }
+ sorted = 0;
+ do
+ {
+ sorted = 1;
+ for (i = 0; i < 5; i++)
+ {
+ if (mz[order[i]] > mz[order[i + 1]])
+ {
+ j = order[i];
+ order[i] = order[i + 1];
+ order[i + 1] = j;
+ sorted = 0;
+ }
+ }
+ }
+ while (!sorted);
+
+ evas_object_raise(c->side[order[0]].o);
+ for (i = 1; i < 6; i++)
+ evas_object_stack_below(c->side[order[i]].o, c->side[order[i - 1]].o);
+}
+
+static void
+_cube_free(Cube *c)
+{
+ int i;
+
+ for (i = 0; i < 6; i++) evas_object_del(c->side[i].o);
+ free(c);
+}
+
+/* setup */
+static void _setup(void)
+{
+ cubes[0] = _cube_new(720, 420, 720);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ _cube_free(cubes[0]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ _cube_pos(cubes[0],
+ (win_w / 2), (win_h / 2), 0,
+ 0, f, 0);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_3d_flow_start
+#define NAME "Image Map 3D Flow"
+#define ICON "3d.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+#define CNUM 48
+
+/* private data */
+static Evas_Object *o_images[CNUM];
+static Evas_Object *o_reflec[CNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < CNUM; i++)
+ {
+ char buf[256];
+
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ snprintf(buf, sizeof(buf), "cube%i.png", (i % 6) + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 256, 256);
+ evas_object_resize(o, 256, 256);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+
+ o = evas_object_image_add(evas);
+ o_reflec[i] = o;
+ snprintf(buf, sizeof(buf), "cube%i.png", (i % 6) + 1);
+ evas_object_image_file_set(o, build_path(buf), NULL);
+ evas_object_image_fill_set(o, 0, 0, 256, 256);
+ evas_object_resize(o, 256, 256);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < CNUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < CNUM; i++) evas_object_del(o_reflec[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, xx, yy, w, h, c, z;
+ int center = 150;
+ double ang, n;
+
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+
+ for (i = 0; i < CNUM; i++)
+ {
+ x = (win_w / 2);
+ y = (win_h / 2);
+ w = 256;
+ h = 256;
+
+ c = (i - (CNUM / 2)) * (w / 4);
+ c += (f % (6 * (w / 4)));
+
+ ang = (double)c / (double)center;
+ if (ang > 0.0) ang = ang * ang;
+ else ang = -ang * ang;
+ ang *= -90.0;
+ if (ang > 90.0) ang = 90.0;
+ else if (ang < -90.0) ang = -90.0;
+
+ if ((c > (-center)) && (c <= (center)))
+ {
+ n = (double)c / (double)center;
+ if (c > 0)
+ {
+ n = 1.0 - n;
+ n = 1.0 - (n * n);
+ }
+ else
+ {
+ n = -(-1.0 - n);
+ n = -(1.0 - (n * n));
+ }
+ c = n * center * 2.0;
+ }
+ else if (c <= (-center))
+ c = (c + center) - (center * 2);
+ else if (c > (center))
+ c = (c - center) + (center * 2);
+
+ z = 0;
+ if ((c > (-center)) && (c <= (center)))
+ {
+ z = (c * (w / 2)) / center;
+ if (z < 0) z = -z;
+ z = (w / 2) - z;
+ }
+
+ x += c;
+
+ x -= (w / 2);
+ xx = x + w;
+
+ y -= (h / 2);
+ yy = y + h;
+
+ if (c <= 0)
+ {
+ evas_object_raise(o_images[i]);
+ evas_object_raise(o_reflec[i]);
+ }
+ else
+ {
+ evas_object_lower(o_images[i]);
+ evas_object_lower(o_reflec[i]);
+ }
+
+ evas_map_point_coord_set (m, 0, x, y, -z);
+ evas_map_point_image_uv_set(m, 0, 0, 0);
+ evas_map_point_color_set (m, 0, 255, 255, 255, 255);
+
+ evas_map_point_coord_set (m, 1, xx, y, -z);
+ evas_map_point_image_uv_set(m, 1, 256, 0);
+ evas_map_point_color_set (m, 1, 255, 255, 255, 255);
+
+ evas_map_point_coord_set (m, 2, xx, yy, -z);
+ evas_map_point_image_uv_set(m, 2, 256, 256);
+ evas_map_point_color_set (m, 2, 255, 255, 255, 255);
+
+ evas_map_point_coord_set (m, 3, x, yy, -z);
+ evas_map_point_image_uv_set(m, 3, 0, 256);
+ evas_map_point_color_set (m, 3, 255, 255, 255, 255);
+
+ evas_map_util_3d_rotate(m, 0, ang, 0,
+ x + (w / 2), y + (h / 2), 0);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), -256, 512);
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+
+ evas_map_point_coord_set (m, 0, x, yy, -z);
+ evas_map_point_image_uv_set(m, 0, 0, 256);
+ evas_map_point_color_set (m, 0, 128, 128, 128, 128);
+
+ evas_map_point_coord_set (m, 1, xx, yy, -z);
+ evas_map_point_image_uv_set(m, 1, 256, 256);
+ evas_map_point_color_set (m, 1, 128, 128, 128, 128);
+
+ evas_map_point_coord_set (m, 2, xx, yy + h, -z);
+ evas_map_point_image_uv_set(m, 2, 256, 0);
+ evas_map_point_color_set (m, 2, 0, 0, 0, 0);
+
+ evas_map_point_coord_set (m, 3, x, yy + h, -z);
+ evas_map_point_image_uv_set(m, 3, 0, 0);
+ evas_map_point_color_set (m, 3, 0, 0, 0, 0);
+
+ evas_map_util_3d_rotate(m, 0, ang, 0,
+ x + (w / 2), y + (h / 2), 0);
+ evas_map_util_3d_perspective(m, (win_w / 2), (win_h / 2), -256, 512);
+
+ evas_object_map_enable_set(o_reflec[i], 1);
+ evas_object_map_set(o_reflec[i], m);
+ }
+
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_alpha_nearest_rotate_start
+#define NAME "Image Map Color Alpha Nearest Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 0, 0, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_alpha_nearest_solid_rotate_start
+#define NAME "Image Map Color Alpha Nearest Solid Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 0, 0, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_alpha_rotate_start
+#define NAME "Image Map Color Alpha Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 0, 0, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_alpha_solid_rotate_start
+#define NAME "Image Map Color Alpha Solid Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 0, 0, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_nearest_rotate_start
+#define NAME "Image Map Color Nearest Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 255, 0, 255);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_nearest_solid_rotate_start
+#define NAME "Image Map Color Nearest Solid Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 255, 0, 255);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_rotate_start
+#define NAME "Image Map Color Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 255, 0, 255);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_color_solid_rotate_start
+#define NAME "Image Map Color Solid Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_point_color_set(m, 0, 255, 255, 255, 255);
+ evas_map_point_color_set(m, 1, 255, 0, 0, 255);
+ evas_map_point_color_set(m, 2, 0, 0, 255, 255);
+ evas_map_point_color_set(m, 3, 0, 255, 0, 255);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_nearest_rotate_start
+#define NAME "Image Map Nearest Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_nearest_solid_rotate_start
+#define NAME "Image Map Nearest Solid Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ evas_map_smooth_set(m, 0);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_rotate_start
+#define NAME "Image Map Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_map_solid_rotate_start
+#define NAME "Image Map Solid Rotate"
+#define ICON "map.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < (OBNUM / 2); i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < (OBNUM / 2); i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+
+ evas_map_util_points_populate_from_geometry(m, x, y, w, h, 0);
+
+ evas_map_util_rotate(m, f, x + (w / 2), y + (h / 2));
+
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask
+#define NAME "Image Mask"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i+= 2)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("image.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+
+ o = evas_object_image_add(evas);
+ o_images[i + 1] = o;
+ evas_object_image_file_set(o, build_path("e-logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ evas_object_clip_set(o_images[i],o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i+= 2)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_images[i + 1], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_10
+#define NAME "Image Mask 10"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[1];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < 1; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("texture.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, win_w * 4, win_h * 4);
+ evas_object_resize(o, win_w * 4, win_h * 4);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < 1; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ if (!m) m = evas_map_new(4);
+ for (i = 0; i < 1; i++)
+ {
+ w = win_w * 4;
+ h = win_h * 4;
+ x = (win_w / 2) - (w / 2);
+ y = (win_h / 2) - (h / 2);
+ evas_map_util_points_populate_from_geometry(m,
+ -win_w, -win_h,
+ win_w * 4, win_h * 4, 0);
+ evas_map_util_rotate(m, f, win_w / 2, win_h / 2);
+ evas_object_map_enable_set(o_images[i], 1);
+ evas_object_map_set(o_images[i], m);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_11
+#define NAME "Image Mask 11"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ if (!m) m = evas_map_new(4);
+ evas_map_util_points_populate_from_geometry(m,
+ (win_w - 720) / 2,
+ (win_h - 420) / 2,
+ 720, 420, 0);
+ evas_map_util_rotate(m, f, win_w / 2, win_h / 2);
+ evas_object_map_enable_set(o_mask, 1);
+ evas_object_map_set(o_mask, m);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_12
+#define NAME "Image Mask 12"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_text_add(evas);
+ o_mask = o;
+ evas_object_text_font_set(o, "Vera-Bold", 150);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("texture.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 500, 444);
+ evas_object_resize(o, win_w * 4, win_h * 4);
+// evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ const char *strs[] = {
+ "Big", "Smelly", "Fish", "Pants", "Octopus", "Garden", "There", "I",
+ "Am", "You", "Are", "Erogenous", "We", "Stick", "Wet", "Fishy",
+ "Fiddly", "Family", "Lair", "Monkeys", "Magazine"
+ };
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = win_w * 4;
+ h = win_h * 4;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (500 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (444 / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ evas_object_text_text_set(o_mask, strs[rnd() % (sizeof(strs) / sizeof(char *))]);
+ evas_object_color_set(o_mask, 255, 255, 255, 255);
+ evas_object_geometry_get(o_mask, NULL, NULL, &w, &h);
+ evas_object_move(o_mask, (win_w - w) / 2, (win_h - h) / 2);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_13
+#define NAME "Image Mask 13"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_text_add(evas);
+ o_mask = o;
+ evas_object_text_font_set(o, "Vera-Bold", 150);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ evas_object_clip_set(o, o_mask);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ const char *strs[] = {
+ "Big", "Smelly", "Fish", "Pants", "Octopus", "Garden", "There", "I",
+ "Am", "You", "Are", "Erogenous", "We", "Stick", "Wet", "Fishy",
+ "Fiddly", "Family", "Lair", "Monkeys", "Magazine"
+ };
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ evas_object_text_text_set(o_mask, strs[rnd() % (sizeof(strs) / sizeof(char *))]);
+ evas_object_color_set(o_mask, 255, 255, 255, 255);
+ evas_object_geometry_get(o_mask, NULL, NULL, &w, &h);
+ evas_object_move(o_mask, (win_w - w) / 2, (win_h - h) / 2);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_14
+#define NAME "Image Mask 14"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 1);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 5 + ((1.0 + cos((double)(f + (i * 10)) / (7.4 * SLOW) )) * w0 * 2);
+ h = 5 + ((1.0 + sin((double)(f + (i * 19)) / (12.6 * SLOW) )) * h0 * 2);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_15
+#define NAME "Image Mask 15"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_smooth_scale_set(o, 0);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 5 + ((1.0 + cos((double)(f + (i * 10)) / (7.4 * SLOW) )) * w0 * 2);
+ h = 5 + ((1.0 + sin((double)(f + (i * 19)) / (12.6 * SLOW) )) * h0 * 2);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ evas_object_image_fill_set(o_images[i], 0, 0, w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_2
+#define NAME "Image Mask 2"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i+= 2)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("e-logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+
+ o = evas_object_image_add(evas);
+ o_images[i + 1] = o;
+ evas_object_image_file_set(o, build_path("e-logo-2.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ evas_object_clip_set(o_images[i], o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i+= 2)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_images[i + 1], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_3
+#define NAME "Image Mask 3"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < OBNUM; i+= 2)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("e-logo-2.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+
+ o = evas_object_image_add(evas);
+ o_images[i + 1] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ evas_object_clip_set(o_images[i], o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i+= 2)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_images[i + 1], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_4
+#define NAME "Image Mask 4"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_5
+#define NAME "Image Mask 5"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-2.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_move(o, (win_w - 120) / 2, (win_h - 160) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_6
+#define NAME "Image Mask 6"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120 / 2, 160 / 2);
+ evas_object_resize(o, 120 / 2, 160 / 2);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120 / 2;
+ h = 160 / 2;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_7
+#define NAME "Image Mask 7"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-2.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_move(o, (win_w - 120) / 2, (win_h - 160) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ w = 10 + (110 + (110 * sin((double)(f) / (14.3 * SLOW))));
+ h = 10 + (150 + (150 * sin((double)(f) / (21.7 * SLOW))));
+ evas_object_image_fill_set(o_mask, 0, 0, w, h);
+ evas_object_resize(o_mask, w, h);
+ evas_object_move(o_mask, (win_w - w) / 2, (win_h - h) / 2);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_8
+#define NAME "Image Mask 8"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[1];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < 1; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("texture.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 500, 444);
+ evas_object_resize(o, win_w * 4, win_h * 4);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < 1; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < 1; i++)
+ {
+ w = win_w * 4;
+ h = win_h * 4;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (500 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (444 / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_mask_9
+#define NAME "Image Mask 9"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[1];
+static Evas_Object *o_mask;
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+
+ o = evas_object_image_add(evas);
+ o_mask = o;
+ evas_object_image_file_set(o, build_path("e-logo-mask.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 720, 420);
+ evas_object_resize(o, 720, 420);
+ evas_object_move(o, (win_w - 720) / 2, (win_h - 420) / 2);
+ evas_object_show(o);
+
+ for (i = 0; i < 1; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path("texture.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 500, 444);
+ evas_object_resize(o, win_w * 4, win_h * 4);
+ evas_object_clip_set(o, o_mask);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < 1; i++) evas_object_del(o_images[i]);
+ evas_object_del(o_mask);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ static Evas_Map *m = NULL;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < 1; i++)
+ {
+ w = win_w * 4;
+ h = win_h * 4;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (500 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (444 / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ if (!m) m = evas_map_new(4);
+
+ evas_map_util_points_populate_from_geometry(m,
+ (win_w - 720) / 2,
+ (win_h - 420) / 2,
+ 720, 420, 0);
+ evas_map_util_rotate(m, f, win_w / 2, win_h / 2);
+ evas_object_map_enable_set(o_mask, 1);
+ evas_object_map_set(o_mask, m);
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME image_quality_scale_start
#define NAME "Image Quality Scale"
-#define ICON "mushroom.png"
+#define ICON "data.png"
#ifndef PROTO
# ifndef UI
#include "main.h"
Evas *evas = NULL;
+const char *profile = "n800";
int win_w = 720, win_h = 420;
+const char *engine = NULL;
+int loops = LOOPS;
+int fullscreen = 0;
static char *datadir = NULL;
static int go = 1;
static void (*loop_func) (void) = NULL;
+static void (*shutdown_func) (void) = NULL;
/* this guarantees that "random" numbers will always be the same set regardless
* of what os/system/etc we are on - as often i need just some "random" set of
int
engine_abort(void)
{
- fprintf(stderr, "go: %i\n", go);
go = 0;
return go;
}
loop_func();
}
+void
+engine_shutdown(void)
+{
+ shutdown_func();
+}
+
static int
_engine_go(void)
{
return go;
}
+static const Expedite_Engine engines[] = {
+#if HAVE_EVAS_SOFTWARE_XLIB
+ { "xlib", engine_software_xlib_args, engine_software_xlib_loop, engine_software_xlib_shutdown },
+#endif
+#if HAVE_EVAS_XRENDER_X11
+ { "xr", engine_xrender_x11_args, engine_xrender_x11_loop, engine_xrender_x11_shutdown },
+#endif
+#if HAVE_EVAS_OPENGL_X11
+ { "gl", engine_gl_x11_args, engine_gl_x11_loop, engine_gl_x11_shutdown },
+#endif
+#if HAVE_EVAS_SOFTWARE_XCB
+ { "xcb", engine_software_xcb_args, engine_software_xcb_loop, engine_software_xcb_shutdown },
+#endif
+#if HAVE_EVAS_XRENDER_XCB
+ { "xrxcb", engine_xrender_xcb_args, engine_xrender_xcb_loop, engine_xrender_xcb_shutdown },
+#endif
+#if HAVE_EVAS_SOFTWARE_GDI
+ { "gdi", engine_software_gdi_args, engine_software_gdi_loop, engine_software_gdi_shutdown },
+#endif
+#if HAVE_EVAS_SOFTWARE_DDRAW
+ { "ddraw", engine_software_ddraw_args, engine_software_ddraw_loop, engine_software_ddraw_shutdown },
+#endif
+#if HAVE_EVAS_DIRECT3D
+ { "direct3d",engine_direct3d_args, engine_direct3d_loop, engine_direct3d_shutdown },
+#endif
+#if BUILD_SDL
+ { "sdl", engine_software_sdl_args, engine_software_sdl_loop, engine_software_sdl_shutdown },
+#endif
+#if HAVE_EVAS_OPENGL_SDL
+ { "gl-sdl",engine_gl_sdl_args, engine_gl_sdl_loop, engine_gl_sdl_shutdown },
+#endif
+#if HAVE_EVAS_FB
+ { "fb", engine_fb_args, engine_fb_loop, engine_fb_shutdown },
+#endif
+#if HAVE_EVAS_DIRECTFB
+ { "directfb",engine_directfb_args, engine_directfb_loop, engine_directfb_shutdown },
+#endif
+#if HAVE_EVAS_OPENGL_COCOA
+ { "gl-cocoa", engine_gl_cocoa_args, engine_gl_cocoa_loop, engine_gl_cocoa_shutdown },
+#endif
+#if HAVE_EVAS_PSL1GHT
+ { "psl1ght", engine_psl1ght_args, engine_psl1ght_loop, engine_psl1ght_shutdown },
+#endif
+#if HAVE_EVAS_SOFTWARE_16_X11
+ { "x11-16",engine_software_16_x11_args, engine_software_16_x11_loop, engine_software_16_x11_shutdown },
+#endif
+#if HAVE_EVAS_SOFTWARE_16_DDRAW
+ { "ddraw-16",engine_software_16_ddraw_args, engine_software_16_ddraw_loop, engine_software_16_ddraw_shutdown },
+#endif
+#if HAVE_EVAS_SOFTWARE_16_WINCE
+ { "wince", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
+ { "wince-fb", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
+ { "wince-gapi", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
+ { "wince-ddraw", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
+ { "wince-gdi", engine_software_16_wince_args, engine_software_16_wince_loop, engine_software_16_wince_shutdown },
+#endif
+ { NULL, NULL, NULL, NULL }
+};
+
+static const Expedite_Resolution resolutions[] = {
+ { "qvga", 320 , 240 },
+ { "qvga-p", 240 , 320 },
+ { "hvga", 320 , 480 },
+ { "hvga-p", 480 , 320 },
+ { "vga", 640 , 480 },
+ { "vga-p", 480 , 640 },
+ { "wvga", 800 , 480 },
+ { "wvga-p", 480 , 800 },
+ { "svga", 800 , 600 },
+ { "svga-p", 600 , 800 },
+ { "xga", 1024, 768 },
+ { "xga-p", 768 , 1024},
+ { "wxga", 1280, 768 },
+ { "wxga-p", 768 , 1280},
+ { "n800", 720 , 420 },
+ { "pal", 720 , 576 },
+ { "480p", 720 , 480 },
+ { "720p", 1280, 720 },
+ { "1080p", 1920, 1080},
+ { "wsvga", 1024, 600 },
+ { "wsvga-p", 600 , 1024},
+ { NULL, 0, 0 }
+};
+
+static void
+_help(void)
+{
+ int i;
+
+ fprintf(stderr,
+ "No engine selected.\n"
+ "\n"
+ "Options:\n"
+ " -datadir path/to/data\n"
+ " -a (autorun all tests)\n"
+ " -c NUM (loop count for test)\n"
+ " -l (list tests)\n"
+ " -t TEST-NUM\n"
+ " -e ENGINE\n"
+ " -p PROFILE\n"
+ " -f use netwm fullscreen request (requires x11 + wm)\n"
+ "\n"
+ "Where ENGINE can be one of:\n");
+ for (i = 0; engines[i].name; ++i)
+ fprintf(stderr, " %s", engines[i].name);
+
+ fprintf(stderr,
+ "\n"
+ "Where PROFILE can be one of:\n");
+
+ for (i = 0; resolutions[i].name; ++i)
+ fprintf(stderr, " %s", resolutions[i].name);
+
+ fprintf(stderr, "\n");
+ exit(-1);
+}
static int
_profile_parse(int argc, char **argv)
{
- int i;
+ int i, j;
for (i = 1; i < argc; i++)
{
if ((!strcmp(argv[i], "-p")) && (i < (argc - 1)))
{
i++;
- if (!strcmp(argv[i], "qvga")) {win_w = 320 ; win_h = 240 ;}
- else if (!strcmp(argv[i], "qvga-p")) {win_w = 240 ; win_h = 320 ;}
- else if (!strcmp(argv[i], "vga")) {win_w = 640 ; win_h = 480 ;}
- else if (!strcmp(argv[i], "vga-p")) {win_w = 480 ; win_h = 640 ;}
- else if (!strcmp(argv[i], "wvga")) {win_w = 800 ; win_h = 480 ;}
- else if (!strcmp(argv[i], "wvga-p")) {win_w = 480 ; win_h = 800 ;}
- else if (!strcmp(argv[i], "svga")) {win_w = 800 ; win_h = 600 ;}
- else if (!strcmp(argv[i], "svga-p")) {win_w = 600 ; win_h = 800 ;}
- else if (!strcmp(argv[i], "xga")) {win_w = 1024; win_h = 768 ;}
- else if (!strcmp(argv[i], "xga-p")) {win_w = 768 ; win_h = 1024;}
- else if (!strcmp(argv[i], "wxga")) {win_w = 1280; win_h = 768 ;}
- else if (!strcmp(argv[i], "wxga-p")) {win_w = 768 ; win_h = 1280;}
- else if (!strcmp(argv[i], "n800")) {win_w = 720 ; win_h = 420 ;}
- else if (!strcmp(argv[i], "pal")) {win_w = 720 ; win_h = 576 ;}
- else if (!strcmp(argv[i], "720p")) {win_w = 1280; win_h = 720 ;}
- else
- {
- printf("Invalid profile: %s\n", argv[i]);
- return 0;
- }
+ for (j = 0; resolutions[j].name; ++j)
+ if (!strcmp(argv[i], resolutions[j].name))
+ {
+ profile = resolutions[j].name;
+ win_w = resolutions[j].width;
+ win_h = resolutions[j].height;
+ break;
+ }
+
+ if (!resolutions[j].name)
+ _help();
}
+ else if ((!strcmp(argv[i], "-c")) && (i < (argc - 1)))
+ {
+ i++;
+ loops = atoi(argv[i]);
+ }
+ else if (!strcmp(argv[i], "-f"))
+ {
+ fullscreen = 1;
+ }
}
return 1;
}
char buf[4096];
char *prefix;
int profile_ok;
+ int i, j;
/* FIXME: parse args for geometry, engine etc. */
profile_ok = _profile_parse(argc, argv);
-#if HAVE_EVAS_SOFTWARE_X11
- if (engine_software_x11_args(argc, argv))
- loop_func = engine_software_x11_loop;
-#endif
-#if HAVE_EVAS_XRENDER_X11
- if (engine_xrender_x11_args(argc, argv))
- loop_func = engine_xrender_x11_loop;
-#endif
-#if HAVE_EVAS_OPENGL_X11
- if (engine_gl_x11_args(argc, argv))
- loop_func = engine_gl_x11_loop;
-#endif
-#if HAVE_EVAS_SOFTWARE_XCB
- if (engine_software_xcb_args(argc, argv))
- loop_func = engine_software_xcb_loop;
-#endif
-#if HAVE_EVAS_SOFTWARE_DDRAW
- if (engine_software_ddraw_args(argc, argv))
- loop_func = engine_software_ddraw_loop;
-#endif
-#if HAVE_EVAS_DIRECT3D
- if (engine_direct3d_args(argc, argv))
- loop_func = engine_direct3d_loop;
-#endif
-#if HAVE_EVAS_OPENGL_GLEW
- if (engine_gl_glew_args(argc, argv))
- loop_func = engine_gl_glew_loop;
-#endif
-#if HAVE_EVAS_SOFTWARE_SDL
- if (engine_software_sdl_args(argc, argv))
- loop_func = engine_software_sdl_loop;
-#endif
-#if HAVE_EVAS_FB
- if (engine_fb_args(argc, argv))
- loop_func = engine_fb_loop;
-#endif
-#if HAVE_EVAS_DIRECTFB
- if (engine_directfb_args(argc, argv))
- loop_func = engine_directfb_loop;
-#endif
-#if HAVE_EVAS_SOFTWARE_16_X11
- if (engine_software_16_x11_args(argc, argv))
- loop_func = engine_software_16_x11_loop;
-#endif
-#if HAVE_EVAS_SOFTWARE_16_DDRAW
- if (engine_software_16_ddraw_args(argc, argv))
- loop_func = engine_software_16_ddraw_loop;
-#endif
-#if HAVE_EVAS_SOFTWARE_16_WINCE
- if (engine_software_16_wince_args(argc, argv))
- loop_func = engine_software_16_wince_loop;
-#endif
+
+ evas_output_size_set(evas, win_w, win_h);
+ evas_output_viewport_set(evas, 0, 0, win_w, win_h);
+
+ for (i = 1; i < argc; ++i)
+ if ((!strcmp(argv[i], "-e")) && (i < (argc - 1)))
+ {
+ ++i;
+
+ for (j = 0; engines[j].name; ++j)
+ if (!strcmp(argv[i], engines[j].name))
+ {
+ engine = engines[j].name;
+ if (engines[j].init(engines[j].name, win_w, win_h))
+ {
+ loop_func = engines[j].loop;
+ shutdown_func = engines[j].shutdown;
+ }
+ break;
+ }
+ }
+
if ((!loop_func) || (!profile_ok))
- {
- fprintf(stderr,
- "No engine selected.\n"
- "\n"
- "Options:\n"
- " -datadir path/to/data\n"
- " -a (autorun all tests)\n"
- " -e ENGINE\n"
- " -p PROFILE\n"
- "\n"
- "Where ENGINE can be one of:\n"
- " "
-#if HAVE_EVAS_SOFTWARE_X11
- " x11"
-#endif
-#if HAVE_EVAS_XRENDER_X11
- " xr"
-#endif
-#if HAVE_EVAS_OPENGL_X11
- " gl"
-#endif
-#if HAVE_EVAS_SOFTWARE_XCB
- " xcb"
-#endif
-#if HAVE_EVAS_SOFTWARE_DDRAW
- " ddraw"
-#endif
-#if HAVE_EVAS_DIRECT3D
- " direct3d"
-#endif
-#if HAVE_EVAS_OPENGL_GLEW
- " gl-glew"
-#endif
-#if HAVE_EVAS_SOFTWARE_SDL
- " sdl sdl-16"
-#endif
-#if HAVE_EVAS_FB
- " fb"
-#endif
-#if HAVE_EVAS_DIRECTFB
- " directfb"
-#endif
-#if HAVE_EVAS_SOFTWARE_16_X11
- " x11-16"
-#endif
-#if HAVE_EVAS_SOFTWARE_16_DDRAW
- " ddraw-16"
-#endif
-#if HAVE_EVAS_SOFTWARE_16_WINCE
- " wince"
- " wince-fb"
- " wince-gapi"
- " wince-ddraw"
-#endif
- "\n"
- "Where PROFILE can be one of:\n"
- " qvga qvga-p vga vga-p wvga wvga-p svga svga-p xga xga-p wxga wxga-p\n"
- " n800 pal 720p\n"
- );
- exit(-1);
- }
+ _help();
datadir = _datadir_parse(argc, argv);
snprintf(buf, 4096, "%s", prefix);
- evas_output_size_set(evas, win_w, win_h);
- evas_output_viewport_set(evas, 0, 0, win_w, win_h);
evas_key_modifier_add(evas, "Shift");
evas_key_modifier_add(evas, "Control");
evas_key_modifier_add(evas, "Alt");
evas_key_lock_add(evas, "Num_Lock");
evas_key_lock_add(evas, "Scroll_Lock");
evas_font_path_append(evas, buf);
- evas_image_cache_set(evas, 0 * 1024 * 1024);
- evas_font_cache_set(evas, 0 * 1024 * 1024);
+// BLAH
+// evas_image_cache_set(evas, 4 * 1024 * 1024);
+// evas_font_cache_set(evas, 1 * 1024 * 1024);
}
int
main(int argc, char **argv)
{
+#if defined (HAVE_EVAS_SOFTWARE_XLIB) || defined (HAVE_EVAS_XRENDER_X11) ||defined (HAVE_EVAS_OPENGL_X11) || defined (HAVE_EVAS_SOFTWARE_16_X11)
+ XInitThreads();
+#endif
+
evas_init();
evas = evas_new();
ui_args(argc, argv);
evas_font_hinting_set(evas, EVAS_FONT_HINTING_AUTO);
-
+
while (_engine_go())
{
- ui_loop();
engine_loop();
+ ui_loop();
evas_render(evas);
}
+
evas_free(evas);
+ engine_shutdown();
evas_shutdown();
return 0;
}
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <unistd.h>
#include <math.h>
-#include <sys/time.h>
#include <time.h>
+#if defined (HAVE_EVAS_SOFTWARE_XLIB) || defined (HAVE_EVAS_XRENDER_X11) ||defined (HAVE_EVAS_OPENGL_X11) || defined (HAVE_EVAS_SOFTWARE_16_X11)
+#include <X11/Xlib.h>
+#endif
+
+#ifndef _MSC_VER
+# include <sys/time.h>
+#endif
+
#ifdef _WIN32
# include <windows.h>
#endif
+#ifdef HAVE_EVIL
+# include <Evil.h>
+#endif
+
#include <Evas.h>
-#if HAVE_EVAS_SOFTWARE_X11
-#include "engine_software_x11.h"
+#if HAVE_EVAS_SOFTWARE_XLIB
+#include "engine_software_xlib.h"
#endif
#if HAVE_EVAS_XRENDER_X11
#include "engine_xrender_x11.h"
#if HAVE_EVAS_SOFTWARE_XCB
#include "engine_software_xcb.h"
#endif
+#if HAVE_EVAS_XRENDER_XCB
+#include "engine_xrender_xcb.h"
+#endif
+#if HAVE_EVAS_SOFTWARE_GDI
+#include "engine_software_gdi.h"
+#endif
#if HAVE_EVAS_SOFTWARE_DDRAW
#include "engine_software_ddraw.h"
#endif
#if HAVE_EVAS_DIRECT3D
#include "engine_direct3d.h"
#endif
-#if HAVE_EVAS_OPENGL_GLEW
-#include "engine_gl_glew.h"
-#endif
-#if HAVE_EVAS_SOFTWARE_SDL
+#if BUILD_SDL
#include "engine_software_sdl.h"
#endif
+#if HAVE_EVAS_OPENGL_SDL
+#include "engine_gl_sdl.h"
+#endif
#if HAVE_EVAS_FB
#include "engine_fb.h"
#endif
#if HAVE_EVAS_DIRECTFB
#include "engine_directfb.h"
#endif
+#if HAVE_EVAS_OPENGL_COCOA
+#include "engine_gl_cocoa.h"
+#endif
+#if HAVE_EVAS_PSL1GHT
+#include "engine_psl1ght.h"
+#endif
#if HAVE_EVAS_SOFTWARE_16_X11
#include "engine_software_16_x11.h"
#endif
#include "engine_software_16_wince.h"
#endif
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
#include "ui.h"
#include "about.h"
+#define EVAS_FRAME_QUEUING // for test
+
#define OBNUM 128
+#define LOOPS 128
extern Evas *evas;
extern int win_w, win_h;
+extern int loops;
+extern int fullscreen;
+
+typedef struct _Expedite_Resolution Expedite_Resolution;
+typedef struct _Expedite_Engine Expedite_Engine;
+
+struct _Expedite_Resolution
+{
+ const char *name;
+ int width;
+ int height;
+};
+
+struct _Expedite_Engine
+{
+ const char *name;
+ Eina_Bool (*init)(const char *engine, int width, int height);
+ void (*loop)(void);
+ void (*shutdown)(void);
+};
void srnd(void);
unsigned int rnd(void);
void engine_loop(void);
int engine_abort(void);
+#ifdef __cplusplus
+}
+#endif
+
#define KEY_STD \
if ((!strcmp(key, "Escape")) || (!strcmp(key, "q")) || (!strcmp(key, "Q")) || (!strcmp(key, "Return"))) \
{ \
}
#define FPS_STD(x) \
- if ((f >= 32) && (!done)) \
+ if ((f >= loops) && (!done)) \
{ \
double fps; \
fps = (double)f / t; \
/* metadata */
#define FNAME poly_blend_start
#define NAME "Polygon Blend"
-#define ICON "flower.png"
+#define ICON "rect.png"
#ifndef PROTO
# ifndef UI
x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (win_w / 4);
y = (win_h / 2) - (h / 2);
y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (win_h / 4);
- poly(o, i, x, y);
+ evas_object_move(o, x, y);
}
FPS_STD(NAME);
}
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_unscaled_proxy_start
+#define NAME "Image Blend Unscaled Proxy"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_show(o);
+ src = o;
+ o_images[0] = src;
+
+ for (i = 1; i < OBNUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_source_set(o, src);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_fill_set(o, 0,0,120,160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+/**
+ * This tests that proxy works fine if the proxy (of an image) works when
+ * offscreen.
+ */
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME image_blend_unscaled_proxy_start
+#define NAME "Proxy Offscreen"
+#define ICON "blend.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o,*src;
+
+ o = evas_object_image_add(evas);
+ evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_fill_set(o, 0, 0, 120, 160);
+ evas_object_resize(o, 120, 160);
+ evas_object_move(o, -400, -300);
+ src = o;
+
+ for (i = 0; i < OBNUM / 2; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_source_set(o, src);
+ evas_object_resize(o, 120, 160);
+ evas_object_image_fill_set(o, 0,0,120,160);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w = 120;
+ h = 160;
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
+ evas_object_move(o_images[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
+
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME proxy_text_fixed
+#define NAME "Proxy Text Fixed"
+#define ICON "text.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_texts[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i,w,h;
+ Evas_Object *o,*s;
+ Evas_Text_Style_Type st;
+
+ st = EVAS_TEXT_STYLE_SHADOW;
+ for (i = 0; st <= EVAS_TEXT_STYLE_FAR_SOFT_SHADOW; i++)
+ {
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 20);
+ evas_object_text_text_set(o, "This is a test string");
+ evas_object_text_style_set(o, st);
+ evas_object_color_set(o, 255, 255, 255, 255);
+ evas_object_text_shadow_color_set(o, 0, 0, 0, 24);
+ evas_object_text_glow_color_set(o, 100, 80, 40, 100);
+ evas_object_text_glow2_color_set(o, 50, 10, 5, 50);
+ evas_object_text_outline_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ st++;
+ }
+
+ for ( ; i < OBNUM ; i ++)
+ {
+ s = o_texts[i % st];
+ o = evas_object_image_add(evas);
+ o_texts[i] = o;
+ evas_object_image_source_set(o, s);
+ evas_object_geometry_get(s, NULL, NULL, &w, &h);
+ evas_object_resize(o, w, h);
+ evas_object_image_fill_set(o, 0, 0, w, h);
+ evas_object_show(o);
+ }
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h;
+ for (i = 0; i < OBNUM; i++)
+ {
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &w, &h);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (w / 2);
+ evas_object_move(o_texts[i], x, y);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME proxy_text_random
+#define NAME "Proxy Text Random"
+#define ICON "text.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_texts[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i = 0;
+ Evas_Object *o;
+ Evas_Coord x, y, w, h;
+ char buf[1024];
+ const char *strs[] = {
+ "Big", "Smelly", "Fish", "Pants", "Octopus", "Garden", "There", "I",
+ "Am", "You", "Are", "Erogenous", "We", "Stick", "Wet", "Fishy",
+ "Fiddly", "Family", "Lair", "Monkeys", "Magazine"
+ };
+ srnd();
+ o = evas_object_text_add(evas);
+ o_texts[0] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 20);
+ snprintf(buf, sizeof(buf), "%s %s %s %s.",
+ strs[rnd() % (sizeof(strs) / sizeof(char *))],
+ strs[rnd() % (sizeof(strs) / sizeof(char *))],
+ strs[rnd() % (sizeof(strs) / sizeof(char *))],
+ strs[rnd() % (sizeof(strs) / sizeof(char *))]);
+ evas_object_text_text_set(o, buf);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_geometry_get(o, NULL, NULL, &w, &h);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)((i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)((i * 28)) / (43.8 * SLOW)) * (w / 2);
+ evas_object_move(o, x, y);
+ evas_object_show(o);
+ for (i = 1 ; i < OBNUM ; i ++)
+ {
+ o = evas_object_image_add(evas);
+ o_texts[i] = o;
+ evas_object_image_source_set(o, o_texts[0]);
+ evas_object_geometry_get(o_texts[0], NULL, NULL, &w, &h);
+ evas_object_resize(o, w, h);
+ evas_object_image_fill_set(o, 0, 0, w, h);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)((i * 13)) / (36.7 * SLOW)) * (w / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)((i * 28)) / (43.8 * SLOW)) * (w / 2);
+ evas_object_move(o, x, y);
+
+ evas_object_show(o);
+ }
+
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i,w,h;
+ char buf[1024];
+ const char *strs[] = {
+ "Big", "Smelly", "Fish", "Pants", "Octopus", "Garden", "There", "I",
+ "Am", "You", "Are", "Erogenous", "We", "Stick", "Wet", "Fishy",
+ "Fiddly", "Family", "Lair", "Monkeys", "Magazine"
+ };
+ snprintf(buf, sizeof(buf), "%s %s %s %s.",
+ strs[rnd() % (sizeof(strs) / sizeof(char *))],
+ strs[rnd() % (sizeof(strs) / sizeof(char *))],
+ strs[rnd() % (sizeof(strs) / sizeof(char *))],
+ strs[rnd() % (sizeof(strs) / sizeof(char *))]);
+ evas_object_text_text_set(o_texts[0], buf);
+ evas_object_geometry_get(o_texts[0], NULL, NULL, &w, &h);
+ for (i = 1; i < OBNUM; i++)
+ {
+ evas_object_resize(o_texts[i],w,h);
+ evas_object_image_fill_set(o_texts[i],0,0,w,h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME rect_blend_start
#define NAME "Rect Blend"
-#define ICON "flower.png"
+#define ICON "rect.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME rect_blend_few_start
#define NAME "Rect Blend Few"
-#define ICON "flower.png"
+#define ICON "rect.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME rect_blend_pow2_start
+#define NAME "Rect Blend Power 2"
+#define ICON "rect.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ srnd();
+ for (i = 0; i < OBNUM; i++)
+ {
+ int r, g, b, a;
+
+ o = evas_object_rectangle_add(evas);
+ o_images[i] = o;
+ a = 256 - (1 << ((rnd() % 8) + 1));
+ if (a < 128) a = 128;
+ r = ((rnd()&0xff) * a) / 255;
+ g = ((rnd()&0xff) * a) / 255;
+ b = ((rnd()&0xff) * a) / 255;
+ evas_object_color_set(o, r, g, b, a);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 5 + ((1.0 + cos((double)(f + (i * 10)) / (7.4 * SLOW) )) * w0 * 2);
+ h = 5 + ((1.0 + sin((double)(f + (i * 19)) / (12.6 * SLOW) )) * h0 * 2);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME rect_blend_pow2_few_start
+#define NAME "Rect Blend Power 2 Few"
+#define ICON "rect.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+#undef OBNUM
+#define OBNUM 3
+
+/* standard var */
+static int done = 0;
+/* private data */
+static Evas_Object *o_images[OBNUM];
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ srnd();
+ for (i = 0; i < OBNUM; i++)
+ {
+ int r, g, b, a;
+
+ o = evas_object_rectangle_add(evas);
+ o_images[i] = o;
+ a = 256 - (1 << ((rnd() % 8) + 1));
+ if (a < 128) a = 128;
+ r = ((rnd()&0xff) * a) / 255;
+ g = ((rnd()&0xff) * a) / 255;
+ b = ((rnd()&0xff) * a) / 255;
+ evas_object_color_set(o, r, g, b, a);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < OBNUM; i++) evas_object_del(o_images[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, w, h, w0, h0;
+ for (i = 0; i < OBNUM; i++)
+ {
+ w0 = 80;
+ h0 = 80;
+ w = 5 + ((1.0 + cos((double)(f + (i * 10)) / (7.4 * SLOW) )) * w0 * 2);
+ h = 5 + ((1.0 + sin((double)(f + (i * 19)) / (12.6 * SLOW) )) * h0 * 2);
+ x = (win_w / 2) - (w / 2);
+ x += sin((double)(f + (i * 113)) / (36.7 * SLOW)) * (w0 / 2);
+ y = (win_h / 2) - (h / 2);
+ y += cos((double)(f + (i * 228)) / (43.8 * SLOW)) * (h0 / 2);
+ evas_object_move(o_images[i], x, y);
+ evas_object_resize(o_images[i], w, h);
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME rect_solid_start
#define NAME "Rect Solid"
-#define ICON "flower.png"
+#define ICON "rect.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME rect_solid_few_start
#define NAME "Rect Solid Few"
-#define ICON "flower.png"
+#define ICON "rect.png"
#ifndef PROTO
# ifndef UI
+#include "widgets_file_icons.c"
+#include "widgets_file_icons_2.c"
+#include "widgets_file_icons_2_grouped.c"
+#include "widgets_file_icons_2_same.c"
+#include "widgets_file_icons_2_same_grouped.c"
+#include "widgets_file_icons_3.c"
+#include "widgets_file_icons_4.c"
+#include "widgets_list_1.c"
+#include "widgets_list_1_grouped.c"
+#include "widgets_list_2.c"
+#include "widgets_list_2_grouped.c"
+#include "widgets_list_3.c"
+#include "widgets_list_3_grouped.c"
+#include "widgets_list_4.c"
+#include "widgets_list_4_grouped.c"
#include "image_blend_unscaled.c"
+#include "image_blend_solid_middle_unscaled.c"
+#include "image_blend_fade_unscaled.c"
+#include "image_blend_fade_pow2_unscaled.c"
#include "image_blend_solid_unscaled.c"
+#include "image_blend_solid_fade_unscaled.c"
+#include "image_blend_solid_fade_pow2_unscaled.c"
#include "image_blend_nearest_scaled.c"
#include "image_blend_nearest_solid_scaled.c"
#include "image_blend_smooth_scaled.c"
#include "image_blend_smooth_solid_scaled.c"
+#include "image_blend_nearest_same_scaled.c"
+#include "image_blend_nearest_solid_same_scaled.c"
+#include "image_blend_smooth_same_scaled.c"
+#include "image_blend_smooth_solid_same_scaled.c"
#include "image_blend_border.c"
+#include "image_blend_solid_middle_border.c"
#include "image_blend_solid_border.c"
#include "image_blend_border_recolor.c"
+#include "image_map_rotate.c"
+#include "image_map_solid_rotate.c"
+#include "image_map_nearest_rotate.c"
+#include "image_map_nearest_solid_rotate.c"
+#include "image_map_color_rotate.c"
+#include "image_map_color_solid_rotate.c"
+#include "image_map_color_nearest_rotate.c"
+#include "image_map_color_nearest_solid_rotate.c"
+#include "image_map_color_alpha_rotate.c"
+#include "image_map_color_alpha_solid_rotate.c"
+#include "image_map_color_alpha_nearest_rotate.c"
+#include "image_map_color_alpha_nearest_solid_rotate.c"
+#include "image_map_3d_1.c"
+#include "image_map_3d_2.c"
+#include "image_map_3d_3.c"
+#include "image_map_3d_4.c"
+#include "image_map_3d_5.c"
+#include "image_map_3d_6.c"
+#include "image_map_3d_flow.c"
#include "image_quality_scale.c"
#include "image_data_argb.c"
#include "image_data_argb_alpha.c"
#include "image_data_ycbcr601pl.c"
#include "image_data_ycbcr601pl_wide_stride.c"
+#include "image_data_ycbcr601pl_map_solid_rotate.c"
+#include "image_data_ycbcr601pl_map_nearest_solid_rotate.c"
#include "image_crossfade.c"
#include "text_basic.c"
#include "text_styles.c"
#include "text_change.c"
#include "textblock_basic.c"
#include "textblock_intl.c"
+#include "textblock_auto_align.c"
+#include "textblock_text_append.c"
#include "rect_blend.c"
+#include "rect_blend_pow2.c"
#include "rect_solid.c"
#include "rect_blend_few.c"
+#include "rect_blend_pow2_few.c"
#include "rect_solid_few.c"
#include "image_blend_occlude1_few.c"
#include "image_blend_occlude2_few.c"
#include "image_blend_occlude2_very_many.c"
#include "image_blend_occlude3_very_many.c"
#include "poly_blend.c"
+#include "proxy_image.c"
+#include "proxy_text_fixed.c"
+#include "proxy_text_random.c"
+#if 0 // test disabled - evas having code disabled
+#include "image_mask.c"
+#include "image_mask_2.c"
+#include "image_mask_3.c"
+#include "image_mask_4.c"
+#include "image_mask_5.c"
+#include "image_mask_6.c"
+#include "image_mask_7.c"
+#include "image_mask_8.c"
+#include "image_mask_9.c"
+#include "image_mask_10.c"
+#include "image_mask_11.c"
+#include "image_mask_12.c"
+#include "image_mask_13.c"
+#include "image_mask_14.c"
+#include "image_mask_15.c"
+#include "filter_object_colors.c"
+#include "filter_object_colors_solid.c"
+#include "filter_object_invert.c"
+#include "filter_object_invert_solid.c"
+#include "filter_object_greyscale.c"
+#include "filter_object_greyscale_solid.c"
+#include "filter_object_brightness.c"
+#include "filter_object_brightness_solid.c"
+#include "filter_object_sepia.c"
+#include "filter_object_sepia_solid.c"
+#include "filter_object_blur.c"
+#include "filter_object_blur_solid.c"
+#endif
/* metadata */
#define FNAME text_basic_start
#define NAME "Text Basic"
-#define ICON "mushroom.png"
+#define ICON "text.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME text_change_start
#define NAME "Text Change"
-#define ICON "mushroom.png"
+#define ICON "text.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME text_styles_start
#define NAME "Text Styles"
-#define ICON "mushroom.png"
+#define ICON "text.png"
#ifndef PROTO
# ifndef UI
/* metadata */
#define FNAME text_styles_different_strings_start
#define NAME "Text Styles Different Strings"
-#define ICON "mushroom.png"
+#define ICON "text.png"
#ifndef PROTO
# ifndef UI
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME textblock_auto_align_start
+#define NAME "Textblock auto align"
+#define ICON "text.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_text;
+
+/* setup */
+static void _setup(void)
+{
+ Evas_Object *o;
+ Evas_Textblock_Style *st;
+
+ o = evas_object_textblock_add(evas);
+ o_text = o;
+ st = evas_textblock_style_new();
+ evas_textblock_style_set
+ (st,
+ "DEFAULT='font=Sans font_size=10 color=#000000 wrap=word'"
+ );
+ evas_object_textblock_style_set(o, st);
+ evas_textblock_style_free(st);
+ evas_object_textblock_clear(o);
+
+ evas_object_textblock_text_markup_set
+ (o,
+ "This is a test of auto alignment in Evas<ps/>"
+ "<br/>"
+ "This text should be left aligned<ps/>"
+ "\xE2\x80\x8FThis text should be right aligned<ps/>"
+ "\xE2\x80\x8FThis text should be right aligned<br/>"
+ "Same as this text.<ps/>"
+ "This text should be left aligned<br/>"
+ "\xE2\x80\x8FSame as this text."
+ "<br/><br/><ps/>"
+ "The word 'זה' should be the rightmost, 'טקסט' after, and 'בעברית' last<br/>"
+ "in the following text:<ps/>"
+ "זה טקסט בעברית<ps/>"
+ "<br/>"
+ "In the next text, the paragraph should be right aligned and the<br/>"
+ "words should appear in the following order: 'דוגמה' first, 'of' second,<br/>"
+ "'טקסט' third, 'english' fourth and 'in' fifth, counting from right to left<ps/>"
+ "דוגמה of טקסט in english."
+ );
+
+ evas_object_show(o);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ evas_object_del(o_text);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ Evas_Coord x, y, w, h, w0, h0;
+ int i = 0;
+
+ evas_object_textblock_size_native_get(o_text, &w0, &h0);
+ w = w0;
+ h = h0;
+ w += fabs(sin((double)(f + (i * 13)) / (31.1 * SLOW))) * (w0);
+ x = (win_w / 2) - (w / 2);
+ y = (win_h / 2) - (h0 / 2);
+ evas_object_move(o_text, x, y);
+ evas_object_resize(o_text, w, h);
+
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
/* metadata */
#define FNAME textblock_basic_start
#define NAME "Textblock Basic"
-#define ICON "mushroom.png"
+#define ICON "text.png"
#ifndef PROTO
# ifndef UI
"red='+ color=#ff0000'"
"p='+ font=Vera,Kochi font_size=10 align=left'"
"/p='- \n'"
- "br='\n'"
- "tab='\t'"
);
evas_object_textblock_style_set(o, st);
evas_textblock_style_free(st);
evas_object_textblock_text_markup_set
(o,
- "<center><h1>Title</h1></center><br>"
+ "<center><h1>Title</h1></center><br/>"
"<p><tab>A pragraph here <red>red text</red> and stuff.</p>"
"<p>And escaping < and > as well as & as <h1>normal.</h1></p>"
- "<p>If you want a newline use <br><br>woo a new line!</p>"
+ "<p>If you want a newline use <br><br/>woo a new line!</p>"
"<right>Right "
"<style=outline color=#fff outline_color=#000>aligned</> "
"<style=shadow shadow_color=#fff8>text</> "
"<color=#00f font_size=12>L</><color=#fff font_size=14>O</>"
"<color=#ff0 font_size=16>R</><color=#0ff font_size=18> Bla Rai</>"
"<color=#f0f font_size=20> Stuff</>.</p>"
+ "<backing=on backing_color=#f00 linesize=20>20 Linesize<br/>"
+ "<backing=on backing_color=#0f0 linesize=40>40 Linesize<br/>"
+ "<backing=on backing_color=#f00 linerelsize=100%>100 percent Linerelsize<br/>"
+ "<backing=on backing_color=#0f0 linerelsize=150%>150 percent Linerelsize<br/>"
+ "<backing=on backing_color=#00f linerelsize=200%>200 percent Linerelsize<br/>"
+ "<backing=off linerelsize=0%>"
"<blockquote>"
"(日本語 カタカナ ひらがな) "
"<style=outline color=#fff outline_color=#000>Round about the cauldron go;</> "
"In the cauldron boil and bake; "
"<style=outline_shadow color=#fff outline_color=#8228 shadow_color=#005>Eye of newt and toe of frog,</> "
"<underline=on underline_color=#00f>Wool of bat and tongue of dog,</> "
- "<backing=on backing_color=#fff8>Adder's fork and blind-worm's sting,</> "
+ "<backing=on backing_color=#ff08>Adder's fork and blind-worm's sting,</> "
"<underline=double underline_color=#f00 underline2_color=#00f>Lizard's leg and owlet's wing,</> "
"<color=#808 font_size=20>For a charm of powerful trouble, "
"Like a hell-broth boil and bubble. "
/* metadata */
#define FNAME textblock_intl_start
#define NAME "Textblock Intl"
-#define ICON "mushroom.png"
+#define ICON "text.png"
#ifndef PROTO
# ifndef UI
evas_textblock_style_set
(st,
"DEFAULT='font=Sans font_size=10 align=left color=#000000 wrap=word'"
- "br='\n'"
);
evas_object_textblock_style_set(o, st);
evas_textblock_style_free(st);
evas_object_textblock_text_markup_set
(o,
- "This is a test of International test rendering in Evas<br>"
- "<br>"
- "Danish: 'Quizdeltagerne spiste jordbær med fløde, mens cirkusklovnen'<br>"
- "German: 'Heizölrückstoßabdämpfung'<br>"
- "Spanish: 'El pingüino Wenceslao hizo kilómetros bajo exhaustiva lluvia y'<br>"
- "French: 'Le cœur déçu mais l'âme plutôt naïve, Louÿs rêva de crapaüter en'<br>"
- "Irish Gaelic: 'D'fhuascail Íosa, Úrmhac na hÓighe Beannaithe, pór Éava agus Ádhaimh'<br>"
- "Hungarian: 'Árvíztűrő tükörfúrógép'<br>"
- "Icelandic: 'Kæmi ný öxi hér ykist þjófum nú bæði víl og ádrepa'<br>"
- "Japanese (hiragana): 'いろはにほへとちりぬるを'<br>"
- "Japanese (katakana): 'イロハニホヘト チリヌルヲ ワカヨタレソ ツネナラム'<br>"
- "Hebrew: '? דג סקרן שט בים מאוכזב ולפתע מצא לו חברה איך הקליטה'<br>"
- "Polish: 'Pchnąć w tę łódź jeża lub ośm skrzyń fig'<br>"
- "Russian: 'В чащах юга жил бы цитрус? Да, но фальшивый экземпляр!'<br>"
- "IPA: 'ˈjunɪˌkoːd'<br>"
- "American Dictionary: 'Ūnĭcōde̽'<br>"
- "Anglo-saxon: 'ᛡᚢᚾᛁᚳᚩᛞ'<br>"
- "Arabic: 'يونِكود'<br>"
- "Armenian: 'Յունիկօդ'<br>"
- "Bengali: 'য়ূনিকোড'<br>"
- "Bopomofo: 'ㄊㄨㄥ˅ ㄧˋ ㄇㄚ˅'<br>"
- "Canadian Syllabics: 'ᔫᗂᑰᑦ'<br>"
- "Cherokee: 'ᏳᏂᎪᏛ'<br>"
- "Chinese: '萬國碼'<br>"
- "Ethiopic: 'ዩኒኮድ'<br>"
- "Georgian: 'უნიკოდი'<br>"
- "Greek: 'Γιούνικοντ'<br>"
+ "This is a test of International test rendering in Evas<br/>"
+ "<br/>"
+ "Danish: 'Quizdeltagerne spiste jordbær med fløde, mens cirkusklovnen'<br/>"
+ "German: 'Heizölrückstoßabdämpfung'<br/>"
+ "Spanish: 'El pingüino Wenceslao hizo kilómetros bajo exhaustiva lluvia y'<br/>"
+ "French: 'Le cœur déçu mais l'âme plutôt naïve, Louÿs rêva de crapaüter en'<br/>"
+ "Irish Gaelic: 'D'fhuascail Íosa, Úrmhac na hÓighe Beannaithe, pór Éava agus Ádhaimh'<br/>"
+ "Hungarian: 'Árvíztűrő tükörfúrógép'<br/>"
+ "Icelandic: 'Kæmi ný öxi hér ykist þjófum nú bæði víl og ádrepa'<br/>"
+ "Japanese (hiragana): 'いろはにほへとちりぬるを'<br/>"
+ "Japanese (katakana): 'イロハニホヘト チリヌルヲ ワカヨタレソ ツネナラム'<br/>"
+ "Hebrew: 'דג סקרן שט בים מאוכזב ולפתע מצא לו חברה איך הקליטה?'<br/>"
+ "Polish: 'Pchnąć w tę łódź jeża lub ośm skrzyń fig'<br/>"
+ "Russian: 'В чащах юга жил бы цитрус? Да, но фальшивый экземпляр!'<br/>"
+ "IPA: 'ˈjunɪˌkoːd'<br/>"
+ "American Dictionary: 'Ūnĭcōde̽'<br/>"
+ "Anglo-saxon: 'ᛡᚢᚾᛁᚳᚩᛞ'<br/>"
+ "Arabic: 'يونِكود'<br/>"
+ "Armenian: 'Յունիկօդ'<br/>"
+ "Bengali: 'য়ূনিকোড'<br/>"
+ "Bopomofo: 'ㄊㄨㄥ˅ ㄧˋ ㄇㄚ˅'<br/>"
+ "Canadian Syllabics: 'ᔫᗂᑰᑦ'<br/>"
+ "Cherokee: 'ᏳᏂᎪᏛ'<br/>"
+ "Chinese: '萬國碼'<br/>"
+ "Ethiopic: 'ዩኒኮድ'<br/>"
+ "Georgian: 'უნიკოდი'<br/>"
+ "Greek: 'Γιούνικοντ'<br/>"
/* also test the html entity stuff a bit */
- "Greek continued: 'τυλθ'<br>"
-
- "Gujarati: 'યૂનિકોડ'<br>"
- "Gurmukhi: 'ਯੂਨਿਕੋਡ'<br>"
- "Hindi: 'यूनिकोड'<br>"
- "Kannada: 'ಯೂನಿಕೋಡ್'<br>"
- "Khmer: 'យូនីគោដ'<br>"
- "Korean: '유니코드'<br>"
- "Malayalam: 'യൂനികോഡ്'<br>"
- "Ogham: 'ᚔᚒᚅᚔᚉᚑᚇ'<br>"
- "Oriya: 'ୟୂନିକୋଡ'<br>"
- "Persian: 'یونیکُد'<br>"
- "Sinhala: 'යණනිකෞද්'<br>"
- "Syriac: 'ܝܘܢܝܩܘܕ'<br>"
- "Tamil:'யூனிகோட்'<br>"
- "Telugu: 'యూనికోడ్'<br>"
- "Thai: 'ยูนืโคด'<br>"
- "Tibetan: 'ཨུ་ནི་ཀོཌྲ།'<br>"
- "Yiddish: 'יוניקאָד'<br>"
+ "Greek continued: 'τυλθ'<br/>"
+
+ "Gujarati: 'યૂનિકોડ'<br/>"
+ "Gurmukhi: 'ਯੂਨਿਕੋਡ'<br/>"
+ "Hindi: 'यूनिकोड'<br/>"
+ "Kannada: 'ಯೂನಿಕೋಡ್'<br/>"
+ "Khmer: 'យូនីគោដ'<br/>"
+ "Korean: '유니코드'<br/>"
+ "Malayalam: 'യൂനികോഡ്'<br/>"
+ "Ogham: 'ᚔᚒᚅᚔᚉᚑᚇ'<br/>"
+ "Oriya: 'ୟୂନିକୋଡ'<br/>"
+ "Persian: 'یونیکُد'<br/>"
+ "Sinhala: 'යණනිකෞද්'<br/>"
+ "Syriac: 'ܝܘܢܝܩܘܕ'<br/>"
+ "Tamil:'யூனிகோட்'<br/>"
+ "Telugu: 'యూనికోడ్'<br/>"
+ "Thai: 'ยูนืโคด'<br/>"
+ "Tibetan: 'ཨུ་ནི་ཀོཌྲ།'<br/>"
+ "Yiddish: 'יוניקאָד'<br/>"
);
evas_object_show(o);
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME textblock_text_append_start
+#define NAME "Textblock text_append"
+#define ICON "text.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+
+/* private data */
+static Evas_Object *o_text;
+
+/* setup */
+static void _setup(void)
+{
+ Evas_Object *o;
+ Evas_Textblock_Style *st;
+
+ o = evas_object_textblock_add(evas);
+ o_text = o;
+ st = evas_textblock_style_new();
+ evas_textblock_style_set
+ (st,
+ "DEFAULT='font=Sans font_size=10 color=#000000 wrap=word'"
+ );
+ evas_object_textblock_style_set(o, st);
+ evas_textblock_style_free(st);
+ evas_object_textblock_clear(o);
+
+ evas_object_textblock_text_markup_set
+ (o,
+ "This test just appends and removes text from different paragraphs, it's "
+ "not a very visual test, it's included for benchmarking purposes."
+"<ps/>"
+"Enlightenment is the flagship and original name bearer for this project. Once it was just a humble window manager for X11 that wanted to do things differently. To do them better, but it has expanded. This can be confusing so when we refer to Enlightenment, we may mean the project as a whole or just the window manager proper. The libraries behind Enlightenment are referred to as EFL collectively, each with a specific name and purpose."
+"<ps/>"
+"The window manager is a lean, fast, modular and very extensible window manager for X11 and Linux. It is classed as a \"desktop shell\" providing the things you need to operate your desktop (or laptop), but is not a whole application suite. This covered launching applications, managing their windows and doing other system tasks like suspending, reboots, managing files etc.<br/>"
+"Platform Support<br/>"
+"Linux BSD Windows Apple"
+"<ps/>"
+"Enlightenment and EFL support several platforms, though Linux is the primary platform of choice for our developers, some make efforts to make things work on FreeBSD and other BSD's, Solaris, MacOS X, Windows (XP, Vista, 7 etc.), Windows CE and more. Compatibility will vary, but most of core EFL support all Linuxes, BSD's, Solaris and other UNIX-like OS's. Mac support should work mostly thanks to the X11 support in OS X, and Windows support exists for most of the core libraries (XP, Vista, 7, CE)."
+"<ps/>"
+"Please contact us for more information if you have problems with support in your platform. Just remember we have limited resources and most of them focus on the core open-source targets.<br/>"
+"Proven effectiveness"
+"<ps/>"
+"Enlightenment libraries already power millions of systems, from mobile phones to set top boxes, desktops, laptops, game systems and more. It is only now being recognized for its forward-thinking approaches, as products and designers want to do more than the boring functional user experiences of the past. This is where EFL excels."
+"<ps/>"
+"Free.fr is shipping millions of set top boxes in France, powered by EFL. The Openmoko Freerunner sold thousands of devices with EFL on them. Yellow Dog Linux for the Sony PS3 ships with Enlightenment as the default. EFL has been used on printers, netbooks and more."
+"<ps/>"
+"Building Blocks"
+"<ps/>"
+"Enlightenment, the window manager is built on top of building blocks known as EFL (the Enlightenment Foundation Libraries). There are more than can be sensibly put into the simple block diagram above, but this covers the essentials.<br/>"
+"Simple E stack"
+"<ps/>"
+"Pretty much any application written using Core EFL libraries will use one or more of these depending on its needs. It may only need the lower level ones or use all of them to the top of the stack. Each library fulfills a purpose, so it may be skipped if not needed.<br/>"
+"Core<ps/>Core EFL components are:<ps/> * Evas<br/>"
+" * Eina<br/>"
+" * Edje<br/>"
+" * Eet<br/>"
+" * Ecore<br/>"
+" * Efreet<br/>"
+" * E_Dbus<br/>"
+" * Embryo<br/>"
+" * Eeze<br/>"
+" * Elementary (window manager will use this in 0.18)<ps/>Binding support exists for several languages such as:<ps/> * Python<br/>"
+" * Javascript<br/>"
+" * Perl<br/>"
+" * C++<br/>"
+" * Ruby<ps/>There are other libraries and applications which build on core EFL and function on other systems too, providing more functionality, examples, and utility:<ps/> * Emotion<br/>"
+" * Ethumb<br/>"
+" * Exquisite<br/>"
+" * Eve<br/>"
+" * Edje Editor<br/>"
+" * E UPnP<br/>"
+" * Enesim<br/>"
+" * Expedite<br/>"
+" * Epdf<br/>"
+" * Exchange<br/>"
+" * Eweather<br/>"
+" * Rage<br/>"
+" * Evil<br/>"
+" * Exalt<ps/> <br/>"
+"Devices<br/>"
+"Laptop<ps/>Enlightenment and EFL use desktop Linux systems as a primary method of development because it is fast and simple to do so, but all of it is written with the express goal in mind of also working on devices from Mobile Phones, to Televisions, Netbooks and more.<br/>"
+"Phone<ps/>We have run and tested on x86-32, x86-64, Atom, Power-PC, ARM (ARM9, ARM11, Cortex-A8 and more), MIPS, Sparc, and many other architectures. The suggested minimum RAM required for a full Linux system + EFL application is 16MB, but you may be able to get by on 8MB. For full functionality 64MB or more is suggested. As little as a 200Mhz ARM core will provide sufficient processing power (depending on needs).<br/>"
+"Various Processors<ps/>Screens from even less than QVGA (320x240 or 240x320) screens all the way up to and beyond full-HD (1920x1080) are covered by EFL. It has the ability to scale user interfaces to almost any sane resolution, as well as adapt to differing input device resolutions, from mouse and stylus to fat fingers. It can draw displays from e-paper through 8-bit paletted displays, 16bit beautifully dithered ones all the way to full 24/32bit OLED beauties.<br/>"
+"Graphics"
+"<ps/>"
+"Enlightenment is built by designers and programmers who want others to be able to do more with less. Some of Enlightenment's libraries do not do anything with graphics at all, but it is the ones that do that are the shining stars of the Enlightenment world.<ps/>Evas is the canvas layer. It is not a drawing library. It is not like OpenGL, Cairo, XRender, GDI, DirectFB etc. It is a scene graph library that retains state of all objects in it. They are created then manipulated until they are no longer needed, at which point they are deleted. This allows the programmer to work in terms that a designer thinks of. It is direct mapping, as opposed to having to convert the concepts into drawing commands in the right order, calculate minimum drawing calls needed to get the job done etc.<ps/>Evas also handles abstracting the rendering mechanism. With zero changes the same application can move from software to OpenGL rendering, as they all use an abstracted scene graph to describe the world (canvas) to Evas. Evas supports multiple targets, but the most useful are the high-speed software rendering engines and OpenGL (as well as OpenGL-ES 2.0).<ps/>Evas not only does quality rendering and compositing, but also can scale, rotate and fully 3D transform objects, allowing for sought-after 3D effects in your interfaces. It supplies these abilities in both software and OpenGL rendering, so you are never caught with unexpected loss of features. The software rendering is even fast enough to provide the 3D without any acceleration on devices for simple uses.<ps/>Edje is a meta-object design library that is somewhere between Flash, PSD, SVG and HTML+CSS. It separates design out from code and into a dynamically loaded data file. This file is compressed and loaded very quickly, along with being cached and shared betweeen instances.<ps/>This allows design to be provided at runtime by different design (EDJ) files, leaving the programmer to worry about overall application implementation and coarse grained UI as opposed to needing to worry about all the little details that the artists may vary even until the day before shipping the product.<br/>"
+ );
+ evas_object_move(o_text, 0, 0);
+ evas_object_resize(o_text, win_w, win_h);
+
+ evas_object_show(o);
+
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ evas_object_del(o_text);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ Evas_Textblock_Cursor *cur;
+ static Evas_Textblock_Cursor *cur2;
+ cur = (Evas_Textblock_Cursor *) evas_object_textblock_cursor_get(o_text);
+ evas_textblock_cursor_text_append(cur, "*");
+ evas_textblock_cursor_char_delete(cur);
+
+ evas_textblock_cursor_paragraph_char_first(cur);
+ if (!cur2)
+ {
+ cur2 = evas_object_textblock_cursor_new(o_text);
+ evas_textblock_cursor_paragraph_last(cur2);
+ evas_textblock_cursor_paragraph_char_first(cur2);
+ }
+ if (!evas_textblock_cursor_compare(cur, cur2))
+ evas_textblock_cursor_paragraph_first(cur);
+ else
+ evas_textblock_cursor_paragraph_next(cur);
+
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
static Evas_Object *o_menu_icon_sel2 = NULL;
static Evas_Object *o_menu_text_sel = NULL;
static Evas_Object *o_menu_title = NULL;
-static Evas_Object *o_menu_title2 = NULL;
-static Evas_List *menu = NULL;
+static Eina_List *menu = NULL;
static int menu_sel = 0;
static int menu_active = 0;
static double menu_anim = 0.0;
static void (*loop_func) (double t, int f) = NULL;
static int run_all = 0;
+static int run_test = 0;
+static int list_test = 0;
+static int exit_after_test = 0;
+
+static double weights[] =
+{
+ 0.0, // no test 0
+
+ 50.4851, // test 1
+ 97.3703, // test 2
+ 10.0000, // test 3
+ 87.3703, // ...
+ 10.0000,
+
+ 150.0000, // test 6
+ 10.0000,
+ 150.0000,
+ 10.0000,
+ 150.0000,
+
+ 10.0000, // test 11
+ 150.0000,
+ 10.0000,
+ 10.6493,
+ 38.4818,
+
+ 40.7314, // test 16
+ 32.0866,
+ 21.3337,
+ 21.2167,
+ 71.6141,
+
+ 64.8893, // test 21
+ 95.0880,
+ 121.0438,
+ 41.2646,
+ 162.7149,
+
+ 89.1650, // test 26
+ 105.3571,
+ 40.9657,
+ 98.4671,
+ 28.4322,
+
+ 60.000, // test 31
+ 75.5507,
+ 51.6601,
+ 135.4753,
+ 38.2705,
+
+ 35.9915, // test 36
+ 31.9500,
+ 22.6752,
+ 38.2702,
+ 37.4459,
+
+ 37.2009, // test 41
+ 34.5459,
+ 38.5043,
+ 50.0000,
+ 37.0282,
+
+ 55.8886, // test 46
+ 17.2535,
+ 23.1457,
+ 36.9874,
+ 37.9336,
+
+ 17.1830, // test 51
+ 20.7521,
+ 29.0141,
+ 131.6784,
+ 13.6851,
+
+ 23.4462, // test 56
+ 14.7573,
+ 36.5261,
+ 5.0000,
+ 5.0000,
+
+ 24.3482, // test 61
+ 10.4611,
+ 86.0290,
+ 82.0735,
+ 18.6459,
+
+ 37.4608, // test 66
+ 32.4417,
+ 11.5449,
+ 5.0000,
+ 11.4172,
+
+ 13.3682, // test 71
+ 10.0324,
+ 10.0584,
+ 10.0170,
+ 5.4029,
+
+ 10.6349, // test 76
+ 21.7728,
+ 12.7933,
+ 19.4177,
+ 34.4192,
+
+ 23.9110, // test 81
+ 22.8287,
+ 41.2399,
+ 30.1383,
+ 22.0342,
+
+ 38.2952, // test 86
+ 5.5560,
+ 0.5000,
+ 1.000,
+ 10.000,
+
+ 5.000, // test 91
+ 20.000, // MASK
+ 20.000, // MASK 2
+ 20.000, // MASK 3
+ 20.000, // MASK 4
+
+ 20.000, // test 96
+ 20.000, // MASK 6
+ 20.000, // MASK 7
+ 20.000, // MASK 8
+ 20.000, // MASK 9
+
+ 20.000, // test 101
+ 20.000, // MASK 11
+ 20.000, // MASK 12
+ 20.000, // MASK 13
+ 20.000, // MASK 14
+
+ 20.000, // test 106 MASK 15
+ 1.000,
+ 2.000,
+ 1.000,
+ 2.000,
+
+ 1.000, // test 111
+ 2.000,
+ 1.000,
+ 2.000,
+ 1.000,
+
+ 2.000, // test 116
+ 10.000,
+ 10.000,
+
+ 0.0, // Exit
+
+ 0.0, // no final test - add a 0 at the end anyway to pad
+ 0.0,
+ 0.0,
+ 0.0,
+ 0.0
+};
static void
_ui_exit(void)
{
+ Menu_Item *mi;
+
+ EINA_LIST_FREE(menu, mi)
+ {
+ free(mi->icon);
+ free(mi->text);
+ free(mi);
+ }
engine_abort();
}
+extern const char *profile;
+extern int win_w, win_h;
+extern const char *engine;
+extern int loops;
+extern int fullscreen;
+
static void
_ui_all(void)
{
- Evas_List *l;
+ Eina_List *l;
double fps = 0.0;
- int t_count = 0;
+ double wfps = 0.0;
+ unsigned int t_count = 0;
+ unsigned int i;
+ double avgw = 0.0;
+ evas_object_hide(o_menu_logo);
+ evas_object_hide(o_menu_title);
+ evas_object_hide(o_menu_icon);
+ evas_object_hide(o_menu_icon_sel);
+ evas_object_hide(o_menu_icon_sel2);
+ evas_object_hide(o_menu_text_sel);
+ evas_object_hide(o_title);
+ evas_object_hide(o_byline);
for (l = menu; l; l = l->next)
{
- Menu_Item *mi;
-
- mi = l->data;
- if ((mi->func == about_start) ||
- (mi->func == _ui_exit) ||
- (mi->func == _ui_all))
- continue;
- if (mi->func) mi->func();
- while (p_fps == 0.0)
- {
- ui_loop();
- engine_loop();
- evas_render(evas);
- }
- /* This give time to delete the objects of the previous test and make
- the result of next test more accurate. Draw back, some time is not
- counted at all. */
- evas_render(evas);
- t_count++;
- fps += p_fps;
- key_func("Escape");
+ Menu_Item *mi;
+
+ mi = l->data;
+ if ((mi->func == about_start) ||
+ (mi->func == _ui_exit) ||
+ (mi->func == _ui_all))
+ continue;
+ if (mi->func) mi->func();
+ evas_object_hide(o_title);
+ evas_object_hide(o_byline);
+ while (p_fps == 0.0)
+ {
+ engine_loop();
+ ui_loop();
+ evas_render(evas);
+ }
+ /* This give time to delete the objects of the previous test and make
+ the result of next test more accurate. Draw back, some time is not
+ counted at all. */
+ evas_render(evas);
+ t_count++;
+ fps += p_fps;
+ wfps += (p_fps * weights[t_count]);
+ key_func("Escape");
+ }
+ for (i = 1;
+ (i < (1 + t_count)) &&
+ (weights[i] > 0.0);
+ i++)
+ avgw += weights[i];
+ avgw /= (i - 1);
+ if (t_count > 0)
+ {
+ char datestr[1024];
+ struct tm *tim;
+ time_t now;
+
+ now = time(NULL);
+ tim = localtime(&now);
+ if (tim) strftime(datestr, sizeof(datestr), "%Y-%m-%d %H:%M:%S", tim);
+ else snprintf(datestr, sizeof(datestr), "unknown");
+ printf("\n#####Test Result#####\n"
+ "evas speed: %5.2f\n"
+ "evas speed(weighted): %5.2f\n"
+ "testcase count: %i\n"
+ "date: %s\n"
+ "evas version: %i.%i.%i.%i\n"
+ "profile: %s\n"
+ "window size: %i, %i\n"
+ "loop count: %i\n"
+ "engine: %s\n"
+ "full screen: %i\n",
+ (fps / t_count),
+ (wfps / (t_count * avgw)),
+ t_count,
+ datestr,
+ evas_version->major, evas_version->minor, evas_version->micro,
+ evas_version->revision,
+ profile,
+ win_w, win_h,
+ loops,
+ engine,
+ fullscreen);
+ }
+}
+
+
+static void
+_ui_num(int n)
+{
+ double fps = 0.0;
+ double wfps = 0.0;
+ int t_count = 0;
+ Menu_Item *mi;
+ unsigned int i;
+ double avgw = 0.0;
+
+ evas_object_hide(o_menu_logo);
+ evas_object_hide(o_menu_title);
+ evas_object_hide(o_menu_icon);
+ evas_object_hide(o_menu_icon_sel);
+ evas_object_hide(o_menu_icon_sel2);
+ evas_object_hide(o_menu_text_sel);
+ evas_object_hide(o_title);
+ evas_object_hide(o_byline);
+ mi = eina_list_nth(menu, n);
+ if (mi)
+ {
+ if ((mi->func == about_start) ||
+ (mi->func == _ui_exit) ||
+ (mi->func == _ui_all))
+ goto done;
+ if (mi->func) mi->func();
+ evas_object_hide(o_title);
+ evas_object_hide(o_byline);
+ while (p_fps == 0.0)
+ {
+ ui_loop();
+ engine_loop();
+ evas_render(evas);
+ }
+ /* This give time to delete the objects of the previous test and make
+ the result of next test more accurate. Draw back, some time is not
+ counted at all. */
+ evas_render(evas);
+ t_count++;
+ fps += p_fps;
+ wfps += (p_fps * weights[n]);
+ key_func("Escape");
+ }
+done:
+ for (i = 1; i < ((sizeof(weights) / sizeof(double)) - 1); i++)
+ avgw += weights[i];
+ avgw /= (i - 1);
+ if (t_count > 0)
+ {
+ // printf("%5.2f , EVAS SPEED\n", fps / t_count);
+ printf("%5.2f , EVAS SPEED (WEIGHTED)\n", wfps / (t_count * avgw));
}
- if (t_count > 0) printf("%4.2f , EVAS SPEED\n", fps / t_count);
}
static void
_ui_select(void)
{
- Evas_List *l;
+ Eina_List *l;
int i;
void (*func) (void) = NULL;
evas_object_hide(o_menu_logo);
evas_object_hide(o_menu_title);
- evas_object_hide(o_menu_title2);
evas_object_hide(o_menu_icon);
evas_object_hide(o_menu_icon_sel);
evas_object_hide(o_menu_icon_sel2);
evas_object_hide(o_menu_text_sel);
+ evas_object_hide(o_title);
+ evas_object_hide(o_byline);
for (i = 0, l = menu; l; l = l->next, i++)
{
- Menu_Item *mi;
+ Menu_Item *mi;
- mi = l->data;
- evas_object_hide(mi->o_icon);
- if (i == menu_sel)
- func = mi->func;
+ mi = l->data;
+ evas_object_hide(mi->o_icon);
+ if (i == menu_sel)
+ func = mi->func;
}
menu_active = 0;
if (func) func();
+ evas_object_hide(o_title);
+ evas_object_hide(o_byline);
}
static void
-_ui_key(void *data, Evas *e, Evas_Object *obj, void *event_info)
+_ui_key(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info)
{
Evas_Event_Key_Down *ev;
ev = event_info;
if (key_func)
{
- key_func(ev->keyname);
- return;
+ key_func(ev->keyname);
+ return;
}
if ((!strcmp(ev->keyname, "Escape")) ||
(!strcmp(ev->keyname, "q")) ||
(!strcmp(ev->keyname, "Q")))
{
- engine_abort();
+ _ui_exit();
}
if (menu_active)
{
- if (!strcmp(ev->keyname, "Left")) menu_sel++;
- if (!strcmp(ev->keyname, "Right")) menu_sel--;
- if (menu_sel < 0) menu_sel = 0;
- else if (menu_sel >= evas_list_count(menu)) menu_sel = evas_list_count(menu) - 1;
- menu_anim_sel = menu_sel;
- if (!strcmp(ev->keyname, "Return")) _ui_select();
+ if (!strcmp(ev->keyname, "Left")) menu_sel++;
+ if (!strcmp(ev->keyname, "Right")) menu_sel--;
+ if (menu_sel < 0) menu_sel = 0;
+ else if ((unsigned int)menu_sel >= eina_list_count(menu)) menu_sel = eina_list_count(menu) - 1;
+ menu_anim_sel = menu_sel;
+ if (!strcmp(ev->keyname, "Return")) _ui_select();
}
}
static Evas_Coord down_x, down_y;
-static int down = 0;
static int down_menu_sel = 0;
static void
-_ui_mouse_down(void *data, Evas *e, Evas_Object *obj, void *event_info)
+_ui_mouse_down(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info)
{
Evas_Event_Mouse_Down *ev;
if (ev->button != 1) return;
if (menu_active)
{
- down_x = ev->canvas.x;
- down_y = ev->canvas.y;
- down++;
- down_menu_sel = menu_sel;
- }
- else
- {
+ down_x = ev->canvas.x;
+ down_y = ev->canvas.y;
+ down_menu_sel = menu_sel;
}
}
static void
-_ui_mouse_up(void *data, Evas *e, Evas_Object *obj, void *event_info)
+_ui_mouse_up(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info)
{
Evas_Event_Mouse_Up *ev;
if (ev->button != 1) return;
if (menu_active)
{
- Evas_Coord dx, dy;
-
- dx = ev->canvas.x - down_x;
- dy = ev->canvas.y - down_y;
- if ((((dx * dx) + (dy * dy)) < (20 * 20)) &&
- (menu_sel == down_menu_sel))
- _ui_select();
- down--;
+ Evas_Coord dx, dy;
+
+ dx = ev->canvas.x - down_x;
+ dy = ev->canvas.y - down_y;
+ if ((((dx * dx) + (dy * dy)) < (20 * 20)) &&
+ (menu_sel == down_menu_sel))
+ _ui_select();
}
else
{
- evas_event_feed_key_down(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
- evas_event_feed_key_up(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ evas_event_feed_key_down(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
+ evas_event_feed_key_up(evas, "Escape", "Escape", NULL, NULL, 0, NULL);
}
}
static void
-_ui_mouse_move(void *data, Evas *e, Evas_Object *obj, void *event_info)
+_ui_mouse_move(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info)
{
Evas_Event_Mouse_Move *ev;
ev = event_info;
- if (!down) return;
+ if (ev->buttons != 1) return;
if (menu_active)
{
- menu_sel = down_menu_sel + ((ev->cur.canvas.x - down_x) / 25);
- /* scroll */
- if (menu_sel < 0) menu_sel = 0;
- else if (menu_sel >= evas_list_count(menu)) menu_sel = evas_list_count(menu) - 1;
- menu_anim_sel = menu_sel;
- }
- else
- {
+ menu_sel = down_menu_sel + ((ev->cur.canvas.x - down_x) / 25);
+ /* scroll */
+ if (menu_sel < 0) menu_sel = 0;
+ else if ((unsigned int)menu_sel >= eina_list_count(menu))
+ menu_sel = eina_list_count(menu) - 1;
+ menu_anim_sel = menu_sel;
}
}
mi->icon = strdup(icon);
mi->text = strdup(text);
mi->func = func;
- menu = evas_list_append(menu, mi);
+ menu = eina_list_append(menu, mi);
evas_object_raise(o_menu_icon_sel2);
}
{
Evas_Object *o;
Evas_Coord x, y, w, h;
+ time_t t0, t;
o = evas_object_rectangle_add(evas);
evas_object_move(o, 0, 0);
evas_object_show(o);
o_wallpaper = o;
-/*
- o = evas_object_image_add(evas);
- evas_object_move(o, 0, 0);
- evas_object_image_file_set(o, PACKAGE_DATA_DIR"/data/bg.png", NULL);
- evas_object_image_fill_set(o, 0, 0, win_w, win_h);
- evas_object_image_smooth_scale_set(o, 0);
- evas_object_resize(o, win_w, win_h);
- evas_object_layer_set(o, -99);
- evas_object_show(o);
- o_wallpaper = o;
- */
-
o = evas_object_text_add(evas);
evas_object_text_font_set(o, "Vera-Bold", 10);
evas_object_text_text_set(o, "EXPEDITE");
o = evas_object_image_add(evas);
evas_object_move(o, (win_w - 120) / 2, ((win_h - 160) / 2));
- evas_object_image_file_set(o, build_path("logo.png"), NULL);
+ evas_object_image_file_set(o, build_path("e-logo.png"), NULL);
evas_object_image_fill_set(o, 0, 0, 120, 160);
evas_object_resize(o, 120, 160);
evas_object_layer_set(o, -98);
o = evas_object_image_add(evas);
evas_object_move(o, 0, 0);
evas_object_image_file_set(o, build_path("icon_sel.png"), NULL);
- evas_object_resize(o, 56, 56);
- evas_object_image_fill_set(o, 0, 0, 56, 56);
+ evas_object_resize(o, 48, 48);
+ evas_object_image_fill_set(o, 0, 0, 48, 48);
o_menu_icon_sel = o;
o = evas_object_image_add(evas);
evas_object_image_file_set(o, build_path("text_sel.png"), NULL);
evas_object_resize(o, 96, 32);
evas_object_image_fill_set(o, 0, 0, 96, 32);
- evas_object_image_border_set(o, 8, 8, 8, 8);
+ evas_object_image_border_set(o, 7, 7, 7, 7);
o_menu_text_sel = o;
- o = evas_object_image_add(evas);
- evas_object_move(o, 0, 0);
- evas_object_image_file_set(o, build_path("icon_sel2.png"), NULL);
- evas_object_resize(o, 56, 41);
- evas_object_image_fill_set(o, 0, 0, 56, 41);
- o_menu_icon_sel2 = o;
-
- o = evas_object_text_add(evas);
- evas_object_text_font_set(o, "Vera-Bold", 10);
- evas_object_text_text_set(o, "");
- evas_object_color_set(o, 100, 100, 100, 100);
- evas_object_pass_events_set(o, 1);
- evas_object_geometry_get(o, NULL, NULL, &w, &h);
- x = ((win_w - w) / 2) + 1;
- y = ((win_h - h) / 2) + 1;
- evas_object_move(o, x, y);
- o_menu_title2 = o;
-
o = evas_object_text_add(evas);
- evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_font_set(o, "Vera", 10);
evas_object_text_text_set(o, "");
evas_object_color_set(o, 0, 0, 0, 100);
evas_object_pass_events_set(o, 1);
evas_object_move(o, x, y);
o_menu_title = o;
- _ui_menu_item_add("e.png", "About Enlightenment", about_start);
+ _ui_menu_item_add("e.png", "About", about_start);
_ui_menu_item_add("e.png", "All Tests", _ui_all);
#define UI
#include "tests.h"
#undef UI
_ui_menu_item_add("exit.png", "Exit", _ui_exit);
+#ifdef HAVE_SYNC
+ /* make sure disk io isn't going to turn up unexpectedly */
+ sync();
+ sync();
+ sync();
+#endif
+ /* warm up the cpu with some spinning */
+ if (run_all)
+ {
+ t0 = time(NULL);
+ for (;;)
+ {
+ t = time(NULL);
+ if (t - t0 > 2) break;
+ }
+ }
+
if (run_all)
{
- _ui_all();
- _ui_exit();
+ _ui_all();
+ }
+ else if (run_test > 0)
+ {
+ _ui_num(run_test);
+ }
+ else if (list_test > 0)
+ {
+ Eina_List *l;
+ int i;
+
+ for (l = menu, i = -1; l; l = l->next, i++)
+ {
+ Menu_Item *mi;
+
+ mi = l->data;
+ if (i > 0)
+ printf("%3i - %s (Weight %0.2lf)\n", i, mi->text, weights[i]);
+ }
}
else
{
- menu_active = 1;
+ menu_active = 1;
}
+
+ if (exit_after_test)
+ _ui_exit();
+
}
void
for (i = 1; i < argc; i++)
{
- if (!strcmp(argv[i], "-a"))
- {
- run_all = 1;
- }
+ if (!strcmp(argv[i], "-a"))
+ {
+ run_all = 1;
+ exit_after_test = 1;
+ }
+ else if ((!strcmp(argv[i], "-t")) && (i < (argc - 1)))
+ {
+ run_test = atoi(argv[i + 1]) + 1;
+ exit_after_test = 1;
+ if (run_test < 2) run_test = 2;
+ }
+ else if (!strcmp(argv[i], "-l"))
+ {
+ list_test = 1;
+ }
}
_ui_setup();
start = get_time();
static double pt = 0.0;
double t, t2;
+ evas_object_resize(o_bg, win_w, win_h);
+ evas_object_resize(o_wallpaper, win_w, win_h);
if (loop_func)
{
- t = get_time();
- f_loop++;
- f_start++;
- if ((t - t_loop) >= 1.0)
- {
-// ui_fps((double)f_loop / (t - t_loop));
- t_loop = t;
- f_loop = 0;
- }
- loop_func(t - t_start, f_start);
- return;
+ t = get_time();
+ f_loop++;
+ f_start++;
+ if ((t - t_loop) >= 1.0)
+ {
+ // ui_fps((double)f_loop / (t - t_loop));
+ t_loop = t;
+ f_loop = 0;
+ }
+ loop_func(t - t_start, f_start);
+ return;
}
t2 = get_time();
if (first)
{
- t = 0.1;
- pt = t2;
+ t = 0.1;
+ pt = t2;
}
else
{
- t = t2 - pt;
- pt = t2;
+ t = t2 - pt;
+ pt = t2;
}
first = 0;
/* menu layout */
if (menu_active)
{
- Evas_List *l;
- int i;
- static double tr = 0.0;
- double tt;
-
- tt = t;
- tt += tr;
- while (tt > 0.001)
- {
- menu_anim = (menu_anim * 0.995) + (menu_anim_sel * 0.005);
- tt -= 0.001;
- }
- tr = tt;
- for (i = 0, l = menu; l; l = l->next, i++)
- {
- char buf[4096];
- Menu_Item *mi;
- Evas_Coord x, y, w, h, tw, th;
- Evas_Coord len;
- double a;
- Evas_Object *o;
-
- mi = l->data;
- o = mi->o_icon;
- evas_object_geometry_get(o_menu_logo, NULL, NULL, &w, &h);
- len = ((w * 3) + 10) / 4;
- evas_object_geometry_get(o, NULL, NULL, &w, &h);
- x = (win_w / 2)
- + (sin((menu_anim - (double)i) * 0.33) * len)
- - (w / 2);
- y = (win_h / 2)
- + (cos((menu_anim - (double)i) * 0.33) * len)
- - (h / 2);
- evas_object_move(o, x, y);
- a = menu_anim - (double)i;
- if (a < 0) a = -a;
- a = 255 - (30 * a);
- evas_object_color_set(o, a, a, a, a);
- evas_object_show(o);
-
-
- if (i == menu_sel)
- {
- a = menu_anim - (double)i;
- if (a < 0) a = -a;
- a = 255 - (255 * a);
-
- o = o_menu_icon_sel;
- evas_object_move(o, x - ((56 - w) / 2), y - ((56 - h) / 2));
- evas_object_color_set(o, a, a, a, a);
-
- o = o_menu_icon_sel2;
- evas_object_move(o, (win_w - 56) / 2, (win_h / 2) + len - 4);
-
- o = o_menu_title;
- evas_object_color_set(o, 0, 0, 0, a);
- evas_object_text_text_set(o, mi->text);
- evas_object_geometry_get(o, NULL, NULL, &tw, &th);
- x = (win_w - tw) / 2;
- y = (win_h / 2) + len + 40;
- evas_object_move(o, x, y);
-
- o = o_menu_title2;
- evas_object_color_set(o, a / 2, a / 2, a / 2, a / 2);
- evas_object_text_text_set(o, mi->text);
- evas_object_move(o, x + 1, y + 1);
-
- o = o_menu_text_sel;
- w = tw + 24;
- h = 28;
- x = x - 12;
- y = y + ((th - h) / 2);
- evas_object_move(o, x, y);
- evas_object_resize(o, w, h);
- evas_object_image_fill_set(o, 0, 0, w, h);
- evas_object_color_set(o, a, a, a, a);
-
- o = o_menu_icon;
- snprintf(buf, 4096, "%s%s", data_dir, mi->icon);
- evas_object_image_file_set(o, buf, NULL);
- evas_object_color_set(o, a / 2, a / 2, a / 2, a / 2);
- }
- }
- evas_object_show(o_menu_logo);
- evas_object_show(o_menu_title);
- evas_object_show(o_menu_title2);
- evas_object_show(o_menu_icon);
- evas_object_show(o_menu_icon_sel);
- evas_object_show(o_menu_icon_sel2);
- evas_object_show(o_menu_text_sel);
+ Eina_List *l;
+ int i;
+ static double tr = 0.0;
+ double tt;
+
+ tt = t;
+ tt += tr;
+ while (tt > 0.001)
+ {
+ menu_anim = (menu_anim * 0.995) + (menu_anim_sel * 0.005);
+ tt -= 0.001;
+ }
+ tr = tt;
+ for (i = 0, l = menu; l; l = l->next, i++)
+ {
+ char buf[4096];
+ Menu_Item *mi;
+ Evas_Coord x, y, w, h, tw, th;
+ Evas_Coord len;
+ double a;
+ Evas_Object *o;
+
+ mi = l->data;
+ o = mi->o_icon;
+ evas_object_geometry_get(o_menu_logo, NULL, NULL, &w, &h);
+ len = ((w * 3) + 10) / 4;
+ evas_object_geometry_get(o, NULL, NULL, &w, &h);
+ x = (win_w / 2)
+ + (sin((menu_anim - (double)i) * 0.33) * len)
+ - (w / 2);
+ y = (win_h / 2)
+ + (cos((menu_anim - (double)i) * 0.33) * len)
+ - (h / 2);
+ evas_object_move(o, x, y);
+ a = menu_anim - (double)i;
+ if (a < 0) a = -a;
+ a = 255 - (30 * a);
+ evas_object_color_set(o, a, a, a, a);
+ evas_object_show(o);
+
+ if (i == menu_sel)
+ {
+ a = menu_anim - (double)i;
+ if (a < 0) a = -a;
+ a = 255 - (255 * a);
+
+ o = o_menu_icon_sel;
+ evas_object_move(o, x - ((48 - w) / 2), y - ((48 - h) / 2));
+ evas_object_color_set(o, a, a, a, a);
+
+ o = o_menu_title;
+ evas_object_color_set(o, a, a, a, a);
+ evas_object_text_text_set(o, mi->text);
+ evas_object_geometry_get(o, NULL, NULL, &tw, &th);
+ x = (win_w - tw) / 2;
+ y = (win_h / 2) + len + 48;
+ evas_object_move(o, x, y);
+
+
+ o = o_menu_text_sel;
+ w = tw + 24;
+ h = 28;
+ x = x - 12;
+ y = y + ((th - h) / 2);
+ evas_object_move(o, x, y);
+ evas_object_resize(o, w, h);
+ evas_object_image_fill_set(o, 0, 0, w, h);
+ evas_object_color_set(o, a, a, a, a);
+
+ o = o_menu_icon;
+ snprintf(buf, 4096, "%s%s", data_dir, mi->icon);
+ evas_object_image_file_set(o, buf, NULL);
+ evas_object_color_set(o, a / 2, a / 2, a / 2, a / 2);
+ }
+ }
+ evas_object_move(o_menu_logo, (win_w - 120) / 2, ((win_h - 160) / 2));
+ evas_object_show(o_menu_logo);
+ evas_object_show(o_menu_title);
+ evas_object_show(o_menu_icon);
+ evas_object_show(o_menu_icon_sel);
+ evas_object_show(o_menu_icon_sel2);
+ evas_object_show(o_menu_text_sel);
}
else
{
void
ui_menu(void)
{
- evas_object_text_text_set(o_byline, "LEFT/RIGHT - select, ENTER - select, ESCAPE - exit.");
+ evas_object_show(o_title);
+ evas_object_show(o_byline);
+ evas_object_text_text_set
+ (o_byline, "LEFT/RIGHT - select, ENTER - select, ESCAPE - exit.");
menu_active = 1;
key_func = NULL;
loop_func = NULL;
void
ui_fps(double fps)
{
- char buf[256];
+ /*
+ char buf[256];
- snprintf(buf, sizeof(buf), "ESCAPE - exit, FPS: %4.3f", fps);
- evas_object_text_text_set(o_byline, buf);
+ snprintf(buf, sizeof(buf), "ESCAPE - exit, FPS: %4.3f", fps);
+ evas_object_text_text_set(o_byline, buf);
+ */
p_fps = fps;
}
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_start
+#define NAME "Widgets File Icons"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 13]);
+ evas_object_text_style_set(o, EVAS_TEXT_STYLE_FAR_SOFT_SHADOW);
+ evas_object_color_set(o, 255, 255, 255, 255);
+ evas_object_text_shadow_color_set(o, 0, 0, 0, 24);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_2_start
+#define NAME "Widgets File Icons 2"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 13]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_2_grouped_start
+#define NAME "Widgets File Icons 2 Grouped"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 13]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_images[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ if (i > 13) evas_object_stack_above(o_images[i], o_images[i - 13]);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_2_same_start
+#define NAME "Widgets File Icons 2 Same"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "e.png",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 1]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 1]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_2_same_grouped_start
+#define NAME "Widgets File Icons 2 Same Grouped"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "e.png",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 1]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 1]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_images[i]);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_3_start
+#define NAME "Widgets File Icons 3"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 16
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 13]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_file_icons_4_start
+#define NAME "Widgets File Icons 4"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 96
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_add(evas);
+ o_images[i] = o;
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_image_fill_set(o, 0, 0, ICON_SIZE, ICON_SIZE);
+ evas_object_resize(o, ICON_SIZE, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, icons[i % 13]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x + 8, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE + 16 - tw) / 2;
+ evas_object_move(o_texts[i], x + cent, y + ICON_SIZE + 4);
+ x += ICON_SIZE + 16;
+ if (x > win_w)
+ {
+ x = 0;
+ y += ICON_SIZE + 16;
+ }
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_1_start
+#define NAME "Widgets List"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_1_grouped_start
+#define NAME "Widgets List Grouped"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_images[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_texts[i]);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_2_start
+#define NAME "Widgets List 2"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 32
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_2_grouped_start
+#define NAME "Widgets List 2 Grouped"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_images[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_texts[i]);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_3_start
+#define NAME "Widgets List 3"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_icons[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_image_filled_add(evas);
+ o_icons[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_resize(o, ICON_SIZE - 8, ICON_SIZE - 8);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_icons[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_icons[i], x + 4, y + 4);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8 + ICON_SIZE + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_3_grouped_start
+#define NAME "Widgets List 3 Grouped"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 64
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_icons[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_image_filled_add(evas);
+ o_icons[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_resize(o, ICON_SIZE - 8, ICON_SIZE - 8);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_images[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_icons[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ if (i > 13) evas_object_stack_above(o_icons[i], o_icons[i - 13]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_texts[i]);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_icons[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_icons[i], x + 4, y + 4);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8 + ICON_SIZE + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_4_start
+#define NAME "Widgets List 4"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 32
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_icons[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_image_filled_add(evas);
+ o_icons[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_resize(o, ICON_SIZE - 8, ICON_SIZE - 8);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_icons[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_icons[i], x + 4, y + 4);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8 + ICON_SIZE + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+#undef FNAME
+#undef NAME
+#undef ICON
+
+/* metadata */
+#define FNAME widgets_list_4_grouped_start
+#define NAME "Widgets List 4 Grouped"
+#define ICON "widgets.png"
+
+#ifndef PROTO
+# ifndef UI
+# include "main.h"
+
+/* standard var */
+static int done = 0;
+/* private data */
+#define NUM 512
+#define ICON_SIZE 32
+static Evas_Object *o_images[NUM];
+static Evas_Object *o_icons[NUM];
+static Evas_Object *o_texts[NUM];
+
+static const char *icons[] =
+{
+ "bug.png",
+ "bulb.png",
+ "camera.png",
+ "colorbox.png",
+
+ "e.png",
+ "error.png",
+ "flower.png",
+ "house.png",
+
+ "mushroom.png",
+ "pulse.png",
+ "typewriter.png",
+ "warning.png",
+
+ "watch.png"
+};
+
+static const char *labels[] =
+{
+ "Andrew",
+ "Alex",
+ "Amanda",
+ "Arthur",
+ "Astrid",
+ "Avery",
+
+ "Beethoven",
+ "Billy",
+ "Bob",
+ "Bundy",
+
+ "Candy",
+ "Carsten",
+
+ "Danny",
+ "Dennis",
+ "Dirk",
+ "Doug",
+
+ "Edmond",
+ "Erik",
+
+ "Fernando",
+ "Frank",
+ "Frederick",
+
+ "Gabby",
+ "George",
+ "Gilroy",
+ "Goodrich",
+ "Gumby",
+};
+
+/* setup */
+static void _setup(void)
+{
+ int i;
+ Evas_Object *o;
+ for (i = 0; i < NUM; i++)
+ {
+ o = evas_object_image_filled_add(evas);
+ o_images[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path("pan.png"), NULL);
+ evas_object_resize(o, win_w, ICON_SIZE);
+ evas_object_show(o);
+
+ o = evas_object_image_filled_add(evas);
+ o_icons[i] = o;
+ evas_object_image_border_set(o, 2, 2, 2, 2);
+ evas_object_image_file_set(o, build_path(icons[i % 13]), NULL);
+ evas_object_resize(o, ICON_SIZE - 8, ICON_SIZE - 8);
+ evas_object_show(o);
+
+ o = evas_object_text_add(evas);
+ o_texts[i] = o;
+ evas_object_text_font_set(o, "Vera-Bold", 10);
+ evas_object_text_text_set(o, labels[i % 26]);
+ evas_object_color_set(o, 0, 0, 0, 255);
+ evas_object_show(o);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_images[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_icons[i]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ if (i > 13) evas_object_stack_above(o_icons[i], o_icons[i - 13]);
+ }
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_raise(o_texts[i]);
+ }
+ done = 0;
+}
+
+/* cleanup */
+static void _cleanup(void)
+{
+ int i;
+ for (i = 0; i < NUM; i++) evas_object_del(o_images[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_icons[i]);
+ for (i = 0; i < NUM; i++) evas_object_del(o_texts[i]);
+}
+
+/* loop - do things */
+static void _loop(double t, int f)
+{
+ int i;
+ Evas_Coord x, y, tw, th, cent;
+ x = 0;
+ y = 0 - f;
+ for (i = 0; i < NUM; i++)
+ {
+ evas_object_move(o_images[i], x, y);
+ evas_object_move(o_icons[i], x + 4, y + 4);
+ evas_object_geometry_get(o_texts[i], NULL, NULL, &tw, &th);
+ cent = (ICON_SIZE - th) / 2;
+ evas_object_move(o_texts[i], x + 8 + ICON_SIZE + 8, y + cent);
+ y += ICON_SIZE;
+ }
+ FPS_STD(NAME);
+}
+
+/* prepend special key handlers if interactive (before STD) */
+static void _key(char *key)
+{
+ KEY_STD;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+/* template stuff - ignore */
+# endif
+#endif
+
+#ifdef UI
+_ui_menu_item_add(ICON, NAME, FNAME);
+#endif
+
+#ifdef PROTO
+void FNAME(void);
+#endif
+
+#ifndef PROTO
+# ifndef UI
+void FNAME(void)
+{
+ ui_func_set(_key, _loop);
+ _setup();
+}
+# endif
+#endif
+#undef FNAME
+#undef NAME
+#undef ICON
--- /dev/null
+@echo off\r
+\r
+rem Set external libraries directory.\r
+set EXT_DIR=%cd%\..\..\..\extern\r
+\r
+if not exist %EXT_DIR% (\r
+ set EXT_DIR=\r
+ echo ERROR: External libs dir is not set.\r
+ pause\r
+ goto END\r
+)\r
+\r
+rem Add installation directory pathes.\r
+set INCLUDE=%EXT_DIR%\include;%INCLUDE%\r
+set LIB=%EXT_DIR%\lib;%LIB%\r
+\r
+rem Add Evil lib path\r
+set EvilInclude=%cd%\..\..\evil\src\lib\r
+set EvilCommon=%cd%\..\..\evil\win32\common\r
+set EvilOut=%cd%\..\..\evil\win32\%PROJECT_TYPE%\out\r
+\r
+rem Add Evas lib path\r
+set EvasOut=%cd%\..\..\evas\win32\%PROJECT_TYPE%\out\r
+set EvasDirect3DInclude=%cd%\..\..\evas\src\modules\engines\direct3d\r
+set EvasGLGlewInclude=%cd%\..\..\evas\src\modules\engines\gl_glew\r
+set EvasDDrawInclude=%cd%\..\..\evas\src\modules\engines\software_ddraw\r
+set EvasGDIInclude=%cd%\..\..\evas\src\modules\engines\software_gdi\r
+set EvasInclude=%EvasGDIInclude%;%EvasDDrawInclude%;%EvasGLGlewInclude%;%EvasDirect3DInclude%;%cd%\..\..\evas\src\lib\r
+\r
+rem Add Eina lib path\r
+set EinaInclude=%cd%\..\..\eina\src\include\r
+set EinaCommon=%cd%\..\..\eina\win32\common\r
+set EinaOut=%cd%\..\..\eina\win32\%PROJECT_TYPE%\out\r
+\r
+\r
+set INCLUDE=%EvasInclude%;%EvilCommon%;%EvilInclude%;%EvilInclude%\dlfcn;%EvilInclude%\mman;%INCLUDE%\r
+set INCLUDE=%EinaCommon%;%EinaInclude%;%INCLUDE%\r
+set LIB=%EinaOut%;%EvasOut%;%EvilOut%;%LIB%\r
+\r
+if "%DXSDK_DIR%" == "" (\r
+ echo WARNING: Microsoft DirectX SDK is not installed.\r
+ pause\r
+ goto END\r
+)\r
+\r
+rem Add DirectX includes and libraries dirs.\r
+set INCLUDE="%DXSDK_DIR%Include";%INCLUDE%\r
+set LIB="%DXSDK_DIR%Lib\x86";%LIB%\r
+\r
+\r
+:END\r
--- /dev/null
+\r
+Microsoft Visual Studio Solution File, Format Version 9.00\r
+# Visual Studio 2005\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "expedite", "expedite.vcproj", "{5C640EA7-6E65-46FF-A1FE-EB0955B0CC5A}"\r
+EndProject\r
+Global\r
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
+ Debug|Win32 = Debug|Win32\r
+ Release|Win32 = Release|Win32\r
+ EndGlobalSection\r
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
+ {5C640EA7-6E65-46FF-A1FE-EB0955B0CC5A}.Debug|Win32.ActiveCfg = Debug|Win32\r
+ {5C640EA7-6E65-46FF-A1FE-EB0955B0CC5A}.Debug|Win32.Build.0 = Debug|Win32\r
+ {5C640EA7-6E65-46FF-A1FE-EB0955B0CC5A}.Release|Win32.ActiveCfg = Release|Win32\r
+ {5C640EA7-6E65-46FF-A1FE-EB0955B0CC5A}.Release|Win32.Build.0 = Release|Win32\r
+ EndGlobalSection\r
+ GlobalSection(SolutionProperties) = preSolution\r
+ HideSolutionNode = FALSE\r
+ EndGlobalSection\r
+EndGlobal\r
--- /dev/null
+<?xml version="1.0" encoding="windows-1251"?>\r
+<VisualStudioProject\r
+ ProjectType="Visual C++"\r
+ Version="8.00"\r
+ Name="expedite"\r
+ ProjectGUID="{5C640EA7-6E65-46FF-A1FE-EB0955B0CC5A}"\r
+ RootNamespace="expedite"\r
+ Keyword="Win32Proj"\r
+ >\r
+ <Platforms>\r
+ <Platform\r
+ Name="Win32"\r
+ />\r
+ </Platforms>\r
+ <ToolFiles>\r
+ </ToolFiles>\r
+ <Configurations>\r
+ <Configuration\r
+ Name="Debug|Win32"\r
+ OutputDirectory="$(DebugOutputDirectory)"\r
+ IntermediateDirectory="$(TemporaryDirectory)\$(TargetName)\$(ConfigurationName)"\r
+ ConfigurationType="1"\r
+ CharacterSet="0"\r
+ >\r
+ <Tool\r
+ Name="VCPreBuildEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCCustomBuildTool"\r
+ />\r
+ <Tool\r
+ Name="VCXMLDataGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCWebServiceProxyGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCMIDLTool"\r
+ />\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ Optimization="0"\r
+ AdditionalIncludeDirectories="$(INCLUDE)"\r
+ PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;HAVE_EVIL;__CRT_INLINE=__inline;inline=__inline;snprintf=_snprintf_c;PACKAGE_DATA_DIR=;HAVE_EVAS_DIRECT3D;HAVE_EVAS_SOFTWARE_GDI;_CRT_SECURE_NO_DEPRECATE"\r
+ MinimalRebuild="true"\r
+ BasicRuntimeChecks="3"\r
+ RuntimeLibrary="3"\r
+ UsePrecompiledHeader="0"\r
+ WarningLevel="3"\r
+ Detect64BitPortabilityProblems="true"\r
+ DebugInformationFormat="4"\r
+ />\r
+ <Tool\r
+ Name="VCManagedResourceCompilerTool"\r
+ />\r
+ <Tool\r
+ Name="VCResourceCompilerTool"\r
+ />\r
+ <Tool\r
+ Name="VCPreLinkEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCLinkerTool"\r
+ AdditionalDependencies="eina.lib libevas.lib d3d9.lib d3dx9.lib ddraw.lib gdi32.lib user32.lib"\r
+ OutputFile="$(OutDir)\expedite.exe"\r
+ LinkIncremental="2"\r
+ AdditionalLibraryDirectories="$(LIB); $(DebugLibraryDirectory)"\r
+ GenerateDebugInformation="true"\r
+ SubSystem="1"\r
+ TargetMachine="1"\r
+ />\r
+ <Tool\r
+ Name="VCALinkTool"\r
+ />\r
+ <Tool\r
+ Name="VCManifestTool"\r
+ />\r
+ <Tool\r
+ Name="VCXDCMakeTool"\r
+ />\r
+ <Tool\r
+ Name="VCBscMakeTool"\r
+ />\r
+ <Tool\r
+ Name="VCFxCopTool"\r
+ />\r
+ <Tool\r
+ Name="VCAppVerifierTool"\r
+ />\r
+ <Tool\r
+ Name="VCWebDeploymentTool"\r
+ />\r
+ <Tool\r
+ Name="VCPostBuildEventTool"\r
+ />\r
+ </Configuration>\r
+ <Configuration\r
+ Name="Release|Win32"\r
+ OutputDirectory="$(ReleaseOutputDirectory)"\r
+ IntermediateDirectory="$(TemporaryDirectory)\$(TargetName)\$(ConfigurationName)"\r
+ ConfigurationType="1"\r
+ CharacterSet="0"\r
+ WholeProgramOptimization="1"\r
+ >\r
+ <Tool\r
+ Name="VCPreBuildEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCCustomBuildTool"\r
+ />\r
+ <Tool\r
+ Name="VCXMLDataGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCWebServiceProxyGeneratorTool"\r
+ />\r
+ <Tool\r
+ Name="VCMIDLTool"\r
+ />\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ AdditionalIncludeDirectories="$(INCLUDE)"\r
+ PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;HAVE_EVIL;__CRT_INLINE=__inline;inline=__inline;snprintf=_snprintf_c;PACKAGE_DATA_DIR=;HAVE_EVAS_DIRECT3D;HAVE_EVAS_SOFTWARE_GDI;_CRT_SECURE_NO_DEPRECATE"\r
+ RuntimeLibrary="2"\r
+ UsePrecompiledHeader="0"\r
+ WarningLevel="3"\r
+ Detect64BitPortabilityProblems="true"\r
+ DebugInformationFormat="3"\r
+ />\r
+ <Tool\r
+ Name="VCManagedResourceCompilerTool"\r
+ />\r
+ <Tool\r
+ Name="VCResourceCompilerTool"\r
+ />\r
+ <Tool\r
+ Name="VCPreLinkEventTool"\r
+ />\r
+ <Tool\r
+ Name="VCLinkerTool"\r
+ AdditionalDependencies="eina.lib libevas.lib d3d9.lib d3dx9.lib ddraw.lib gdi32.lib user32.lib"\r
+ OutputFile="$(OutDir)\expedite.exe"\r
+ LinkIncremental="1"\r
+ AdditionalLibraryDirectories="$(LIB); $(ReleaseLibraryDirectory)"\r
+ GenerateDebugInformation="true"\r
+ SubSystem="1"\r
+ OptimizeReferences="2"\r
+ EnableCOMDATFolding="2"\r
+ TargetMachine="1"\r
+ />\r
+ <Tool\r
+ Name="VCALinkTool"\r
+ />\r
+ <Tool\r
+ Name="VCManifestTool"\r
+ />\r
+ <Tool\r
+ Name="VCXDCMakeTool"\r
+ />\r
+ <Tool\r
+ Name="VCBscMakeTool"\r
+ />\r
+ <Tool\r
+ Name="VCFxCopTool"\r
+ />\r
+ <Tool\r
+ Name="VCAppVerifierTool"\r
+ />\r
+ <Tool\r
+ Name="VCWebDeploymentTool"\r
+ />\r
+ <Tool\r
+ Name="VCPostBuildEventTool"\r
+ />\r
+ </Configuration>\r
+ </Configurations>\r
+ <References>\r
+ </References>\r
+ <Files>\r
+ <Filter\r
+ Name="Source Files"\r
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"\r
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"\r
+ >\r
+ <File\r
+ RelativePath="..\..\src\bin\about.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_direct3d.cpp"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_directfb.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_fb.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_gl_glew.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_gl_sdl.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_gl_x11.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_16_ddraw.cpp"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_16_wince.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_16_x11.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_ddraw.cpp"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_gdi.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_sdl.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_x11.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_xrender_x11.c"\r
+ >\r
+ <FileConfiguration\r
+ Name="Debug|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ <FileConfiguration\r
+ Name="Release|Win32"\r
+ ExcludedFromBuild="true"\r
+ >\r
+ <Tool\r
+ Name="VCCLCompilerTool"\r
+ />\r
+ </FileConfiguration>\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_border.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_border_recolor.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_fade_pow2_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_fade_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_nearest_same_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_nearest_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_nearest_solid_same_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_nearest_solid_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude1.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude1_few.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude1_many.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude1_very_many.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude2.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude2_few.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude2_many.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude2_very_many.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude3.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude3_few.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude3_many.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_occlude3_very_many.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_smooth_same_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_smooth_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_smooth_solid_same_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_smooth_solid_scaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_solid_border.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_solid_fade_pow2_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_solid_fade_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_solid_middle_border.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_solid_middle_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_solid_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_blend_unscaled.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_crossfade.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_data_argb.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_data_argb_alpha.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_data_ycbcr601pl.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_data_ycbcr601pl_wide_stride.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_1.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_2.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_3.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_4.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_5.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_6.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_3d_flow.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_alpha_nearest_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_alpha_nearest_solid_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_alpha_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_alpha_solid_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_nearest_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_nearest_solid_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_color_solid_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_nearest_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_nearest_solid_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_map_solid_rotate.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\image_quality_scale.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\main.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\poly_blend.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\rect_blend.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\rect_blend_few.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\rect_blend_pow2.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\rect_blend_pow2_few.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\rect_solid.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\rect_solid_few.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\text_basic.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\text_change.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\text_styles.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\text_styles_different_strings.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\textblock_basic.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\textblock_intl.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\ui.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\widgets_file_icons.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\widgets_file_icons_2.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\widgets_file_icons_3.c"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\widgets_file_icons_4.c"\r
+ >\r
+ </File>\r
+ </Filter>\r
+ <Filter\r
+ Name="Header Files"\r
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"\r
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"\r
+ >\r
+ <File\r
+ RelativePath="..\..\src\bin\about.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_direct3d.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_directfb.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_fb.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_gl_glew.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_gl_x11.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_16_ddraw.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_16_wince.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_16_x11.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_ddraw.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_gdi.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_sdl.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_software_x11.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\engine_xrender_x11.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\main.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\tests.h"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\bin\ui.h"\r
+ >\r
+ </File>\r
+ </Filter>\r
+ <Filter\r
+ Name="Resource Files"\r
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"\r
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"\r
+ >\r
+ </Filter>\r
+ </Files>\r
+ <Globals>\r
+ </Globals>\r
+</VisualStudioProject>\r
--- /dev/null
+set EVAS_MODULES_DIR=%cd%\r
+start expedite.exe -datadir ..\..\..\data -e direct3d
\ No newline at end of file
--- /dev/null
+@echo off\r
+\r
+set Target=%cd%\r
+set e17=%cd%\..\..\..\..\r
+set Libs=%e17%\r
+set Proto=%e17%\proto\r
+set Extern=%e17%\..\..\extern\r
+\r
+rem Copy externals\r
+cd %Extern%\bin\r
+xcopy freetype6.dll %Target%\ /Q /Y\r
+xcopy jpeg62.dll %Target%\ /Q /Y\r
+xcopy zlib1.dll %Target%\ /Q /Y\r
+xcopy glew32.dll %Target%\ /Q /Y\r
+\r
+rem Copy proto\r
+cd %Proto%\evil\win32\vs8\out\r
+xcopy libdl.dll %Target%\ /Q /Y\r
+xcopy libevil.dll %Target%\ /Q /Y\r
+xcopy libmman.dll %Target%\ /Q /Y\r
+\r
+rem Copy libs\r
+cd %Libs%\eina\win32\vs8\out\r
+xcopy eina.dll %Target%\ /Q /Y\r
+\r
+cd %Libs%\eet\win32\vs8\out\r
+xcopy libeet.dll %Target%\ /Q /Y\r
+\r
+cd %Libs%\evas\win32\vs8\out\r
+xcopy libevas.dll %Target%\ /Q /Y\r
+\r
+set Modules=%Libs%\evas\win32\vs8\out\modules\r
+cd %Modules%\engines\direct3d\r
+xcopy module.dll %Target%\evas\modules\engines\direct3d\mingw32-i686\ /Q /Y\r
+cd %Modules%\engines\software_ddraw\r
+xcopy module.dll %Target%\evas\modules\engines\software_ddraw\mingw32-i686\ /Q /Y\r
+cd %Modules%\engines\software_generic\r
+xcopy module.dll %Target%\evas\modules\engines\software_generic\mingw32-i686\ /Q /Y\r
+cd %Modules%\engines\gl_glew\r
+xcopy module.dll %Target%\evas\modules\engines\gl_glew\mingw32-i686\ /Q /Y\r
+cd %Modules%\loaders\png\r
+xcopy module.dll %Target%\evas\modules\loaders\png\mingw32-i686\ /Q /Y\r
--- /dev/null
+@echo off\r
+rem Warning: environment is set for Win32 platform.\r
+\r
+set PROJECT_TYPE=vs8\r
+\r
+pushd ..\r
+call set_env.bat\r
+popd\r
+\r
+if "%EXT_DIR%" == "" goto END\r
+\r
+rem Setup common Win32 environment variables\r
+\r
+set SolutionDirectory=%cd%\r
+set DebugOutputDirectory=%SolutionDirectory%\out\r
+set ReleaseOutputDirectory=%SolutionDirectory%\out\r
+set DebugLibraryDirectory=%SolutionDirectory%\out\r
+set ReleaseLibraryDirectory=%SolutionDirectory%\out\r
+set TemporaryDirectory=%SolutionDirectory%\temp\r
+\r
+rem Check for basic requirements\r
+if "%VS80COMNTOOLS%" == "" (\r
+ echo ERROR: Microsoft Visual Studio 2005 is not installed.\r
+ pause\r
+ goto END\r
+)\r
+\r
+rem Setting environment for using Microsoft Visual Studio 2005 x86 tools.\r
+call "%VS80COMNTOOLS%vsvars32.bat"\r
+\r
+set EVAS_MODULES_DIR=%cd%\out\r
+\r
+expedite.sln\r
+\r
+:END
\ No newline at end of file