Merge changes to enable building host libraries using GCC with work to get basic EGL going. bug235_bringup_0
authorMatt Plumtree <matt.plumtree@nokia.com>
Tue, 02 Nov 2010 09:46:02 +0000
branchbug235_bringup_0
changeset 72 fd0a704154b9
parent 71 243bbc1d70db (diff)
parent 66 07904b9e3bd7 (current diff)
child 73 11fc086941ac
Merge changes to enable building host libraries using GCC with work to get basic EGL going.
build.bat
--- a/CMakeLists.txt	Fri Oct 22 16:32:41 2010 +0100
+++ b/CMakeLists.txt	Tue Nov 02 09:46:02 2010 +0000
@@ -72,8 +72,7 @@
     if (SIMULATOR_EXTENSIONS)
         add_subdirectory(vghwinterface/vghwapiwrapper)	# Simulator serialization (host)
         add_dependencies(KhronosAPIWrapper libEGL libGLESv1 libGLESv2)
-        add_dependencies(syborg-graphicswrapper libEGL libGLESv1 libGLESv2)
-        set(ALL_TARGETS libEGL libOpenVG libGLESv1 libGLESv2 KhronosAPIWrapper syborg-graphicswrapper)
+        set(ALL_TARGETS libEGL libOpenVG libGLESv1 libGLESv2 KhronosAPIWrapper)
     else(SIMULATOR_EXTENSIONS)
         set(ALL_TARGETS libEGL libOpenVG libGLESv1 libGLESv2)
     endif(SIMULATOR_EXTENSIONS)
--- a/build.bat	Fri Oct 22 16:32:41 2010 +0100
+++ b/build.bat	Tue Nov 02 09:46:02 2010 +0000
@@ -10,6 +10,7 @@
 set CMAKE_BUILD_TARGET=Release
 set VISUAL_STUDIO_SOLUTION=OFF
 set BUILD=ON
+set CLEANBUILD=OFF
 set EPOCROOTX=%EPOCROOT:\=/%
 
 :PARSECOMMANDLINE
@@ -26,6 +27,8 @@
 IF '%1'=='/DEBUG' goto ENABLEDEBUG
 IF '%1'=='/nobuild' goto DISABLEBUILD
 IF '%1'=='/NOBUILD' goto DISABLEBUILD
+IF '%1'=='/clean' goto CLEANBUILD
+IF '%1'=='/CLEAN' goto CLEANBUILD
 
 if "%VISUAL_STUDIO_SOLUTION%"=="ON" (
 	set GENERATOR=Visual Studio 8 2005
@@ -41,13 +44,14 @@
 echo GENERATOR            = %GENERATOR%
 echo CMAKE_BUILD_TARGET   = %CMAKE_BUILD_TARGET%
 echo BUILD                = %BUILD%
+echo CLEANBUILD           = %CLEANBUILD%
 echo EPOCROOT (modified)  = %EPOCROOTX%
 echo.
 
 rem Execute
 echo on
-rmdir /s /q build
-mkdir build
+if '%CLEANBUILD%'=='ON' rmdir /s /q build
+if '%CLEANBUILD%'=='ON' mkdir build
 cd build
 cmake -DEPOCROOT=%EPOCROOTX% -DSIMULATOR_EXTENSIONS:Bool=%SIMULATOR_EXTENSIONS% -DTOOLCHAIN_VARIANT:String=%TOOLCHAIN_VARIANT% -DCMAKE_BUILD_TYPE=%CMAKE_BUILD_TARGET% -G "%GENERATOR%" ..
 @echo off
@@ -74,6 +78,7 @@
 echo     [/DEBUG]            configure for debug build (default: release)
 echo     [/NOBUILD]          call cmake but do not call nmake
 echo                             note: has no effect if /SOLUTION is specified
+echo     [/CLEAN]            perform a clean build by deleting the ./build directory.
 echo.
 echo Note: EPOCROOT must be defined to be the directory containing the epoc32 tree.
 goto END
@@ -104,4 +109,9 @@
 shift
 goto PARSECOMMANDLINE
 
+:CLEANBUILD
+set CLEANBUILD=ON
+shift
+goto PARSECOMMANDLINE
+
 :END
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/hostsupport/hostbuild/flm/hostbuild.flm	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,154 @@
+# Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+# All rights reserved.
+# This component and the accompanying materials are made available
+# under the terms of the License "Eclipse Public License v1.0"
+# which accompanies this distribution, and is available
+# at the URL "http://www.eclipse.org/legal/epl-v10.html".
+#
+# Initial Contributors:
+# Nokia Corporation - initial contribution.
+#
+# Contributors:
+#
+# Description:
+# FLM to build x86 exes, libs and dlls
+#
+
+include $(FLMHOME)/flmtools.mk
+include $(FLMHOME)/metaflm.mk
+
+CREATABLEPATHS:=
+CLEANTARGETS:=
+
+# Handle Window/Linux differences
+ifeq ($(OSTYPE),cygwin)
+  DOTDLL:=.dll
+  WIN32:=1
+  GCOVDIR:=$(if $(CODE_COVERAGE),$(EPOCROOT)/epoc32/gcc_mingw/libgcc/mingw32/3.4.5/)
+else
+  DOTDLL:=.so
+endif
+
+# Product include files are different for S60
+ifdef S60_BUILD
+  PRODUCT_INCLUDE:=$(EPOCROOT)/epoc32/include/oem/bldvariant.hrh
+else
+  PRODUCT_INCLUDE:=$(EPOCROOT)/epoc32/include/variant/Symbian_OS.hrh
+endif
+
+# Define macros we need
+CXXDEFS:=$(foreach def,$(MACROS),-D$(def)) -D__GCC32__ -D__EPOC32__ -D__X86__ -D_UNICODE -D__SUPPORT_CPP_EXCEPTIONS__ -D__TOOLS2__ -D'__PRODUCT_INCLUDE__="$(PRODUCT_INCLUDE)"'
+ifeq ($(CFG_PATH),deb)
+  CXXDEFS+= -D_DEBUG
+endif
+
+# Setup the command line options for the compiler
+OPTIMISE:=-fdefer-pop -fmerge-constants -fthread-jumps -floop-optimize -fif-conversion -fif-conversion2 -fguess-branch-probability -fcprop-registers -fforce-mem -foptimize-sibling-calls -fstrength-reduce -fcse-follow-jumps -fcse-skip-blocks -frerun-cse-after-loop -frerun-loop-opt -fgcse -fgcse-lm -fgcse-sm -fgcse-las -fdelete-null-pointer-checks -fexpensive-optimizations -fregmove -fschedule-insns -fschedule-insns2 -fsched-interblock -fsched-spec -fcaller-saves -fpeephole2 -freorder-blocks -freorder-functions -fstrict-aliasing -funit-at-a-time -falign-functions -falign-jumps -falign-loops -falign-labels -fcrossjumping
+
+PREINC=$(EPOCROOT)/epoc32/include/tools/hostbuild.h
+ifeq ($(CFG_PATH),deb)
+  CXXOPT:=-fshort-wchar -x c++ -O0 -g3 -Wall -c -fmessage-length=0 -include $(PREINC)
+else
+  CXXOPT:=-fshort-wchar -x c++ -Wall -c -fmessage-length=0 -include $(PREINC) $(if $(CODE_COVERAGE),-O0,$(OPTIMISE))
+endif
+
+# Allow specification of additional build include file
+ifdef BUILDINC
+  CXXOPT+= -include $(BUILDINC)
+endif
+
+# Extra options needed for cia files
+ASMOPT:=-fomit-frame-pointer -masm=intel
+
+# Linker options for DLL
+ifndef DLL_WIN_LINKER_OPTS
+  DLL_WIN_LINKER_OPTS:=$(if $(CODE_COVERAGE),-lgcov) -Wl,-export-all-symbols -Wl,--enable-auto-import
+endif
+ifndef DLL_LIN_LINKER_OPTS
+  DLL_LIN_LINKER_OPTS:=$(if $(CODE_COVERAGE),-lgcov) -Wl,-export-all-symbols -ldl
+endif
+
+# Source files to scan for in a directory
+# Note that CPP and cpp will match on the same files - so a sort is necessary on wildcard results
+SOURCE_EXT:=CPP cpp c cia
+
+# Source code assumed to be all cpp/cia files in supplied directories
+SOURCE_FILES:=$(foreach dir,$(SOURCE_DIRS),$(sort $(foreach ext,$(SOURCE_EXT),$(wildcard $(EXTENSION_ROOT)/$(dir)/*.$(ext))))) \
+  $(foreach src,$(SOURCE),$(EXTENSION_ROOT)/$(if $(SOURCE_FOLDER),$(SOURCE_FOLDER)/)$(src))
+
+# Include folders
+CXXINC:=$(foreach inc,$(INCLUDES) $(SOURCE_DIRS),-I$(EXTENSION_ROOT)/$(inc)) \
+  $(foreach inc,$(SYS_INCLUDES),-I$(EPOCROOT)/$(inc)) -I$(EXTENSION_ROOT)
+
+# Add standard include paths?
+ifndef NO_STD_INCLUDE
+  CXXINC+= -I$(EPOCROOT)/epoc32/include
+endif
+
+# Generate target folder names
+TARGET_DIR:=$(EPOCROOT)/epoc32/release/tools2$(TOOLPLATFORMDIR)/$(CFG_PATH)/
+OUTPUTPATH:=$(EPOCROOT)/epoc32/build/x86tools/$(CFG_PATH)/$(TARGET_NAME)/
+
+# Target names differ depending on what we're building
+ifeq ($(TARGET_TYPE),lib)
+  TARGET_FULLNAME:=$(TARGET_DIR)$(TARGET_NAME)$(if $(findstring .,$(TARGET_NAME)),,.a)
+endif
+ifeq ($(TARGET_TYPE),exe)
+  TARGET_FULLNAME:=$(TARGET_DIR)$(TARGET_NAME)$(if $(findstring .,$(TARGET_NAME)),,$(DOTEXE))
+endif
+ifeq ($(TARGET_TYPE),dll)
+  TARGET_FULLNAME:=$(TARGET_DIR)$(TARGET_NAME)$(if $(findstring .,$(TARGET_NAME)),,$(DOTDLL))
+endif
+
+# Object files are the same name as the source files with a .o extension
+OBJECTFILES:=$(foreach src,$(SOURCE_FILES),$(OUTPUTPATH)$(subst $(EPOCROOT),,$(src)).o)
+
+# Remember what we're going to create for later
+CLEANTARGETS:=$(TARGET_FULLNAME) $(OBJECTFILES)
+RELEASEABLES:=$(TARGET_FULLNAME)
+CREATABLEPATHS:=$(dir $(OBJECTFILES))
+
+# Standard targets
+$(ALLTARGET):: $(RELEASEABLES)
+TARGET:: $(RELEASEABLES)
+
+# ***
+# hosttargets
+# 
+define hosttargets
+  # Compile
+  $(OBJECTFILES) : $(PREINC) $(SOURCE_FILES)
+		$(call startrule,compile) \
+		$(CXX) $(CXXDEFS) $(CXXINC) -I$(EPOCROOT)$$(subst $(OUTPUTPATH),,$$(dir $$@)) $(CXXOPT) $$(if $$(findstring .cia,$$@),$(ASMOPT),$(if $(CODE_COVERAGE),-fprofile-arcs -ftest-coverage)) $(COMPILE_OPTIONS) -o$$@ $(EPOCROOT)$$(subst $(OUTPUTPATH),,$$(basename $$@)) \
+		$(call endrule,compile)
+
+  # Link
+  $(TARGET_FULLNAME) : $(OBJECTFILES) $(foreach lib,$(LIBS),$(TARGET_DIR)$(lib).a) $(foreach lib,$(SHARED_LIBS),$(TARGET_DIR)$(lib)$(DOTDLL))
+  ifeq ($(TARGET_TYPE),lib)
+		$(call startrule,linklib) \
+		$(AR) -r $$@ $(OBJECTFILES) \
+		$(call endrule,linklib)
+  endif
+  ifeq ($(TARGET_TYPE),exe)
+		$(call startrule,linkexe) \
+		$(CXX) -L$(TARGET_DIR) $(if $(GCOVDIR),-L$(GCOVDIR)) -o$$@ $(OBJECTFILES) $(foreach lib,$(LIBS),$(TARGET_DIR)$(lib).a) $(foreach slib,$(SHARED_LIBS),$(TARGET_DIR)$(slib)$(DOTDLL)) $(if $(CODE_COVERAGE),-lgcov) $(if $(WIN32),-Wl$(CHAR_COMMA)--enable-auto-import,-ldl) \
+		$(call endrule,linkexe)
+  endif
+  ifeq ($(TARGET_TYPE),dll)
+		$(call startrule,linkdll) \
+		$(CXX) -L$(TARGET_DIR) $(if $(GCOVDIR),-L$(GCOVDIR)) -shared -o$$@ $(OBJECTFILES) $(foreach lib,$(LIBS),$(TARGET_DIR)$(lib).a) $(foreach slib,$(SHARED_LIBS),$(TARGET_DIR)$(slib)$(DOTDLL)) $(if $(WIN32),$(DLL_WIN_LINKER_OPTS),$(DLL_LIN_LINKER_OPTS)) \
+		$(call endrule,linkdll)
+  endif
+endef
+
+# Generate the rules
+$(eval $(hosttargets))
+
+# Create folders we need
+$(call makepath,$(CREATABLEPATHS))
+
+# Cleanup after ourselves
+$(eval $(call GenerateStandardCleanTarget,$(CLEANTARGETS),$(CREATABLEPATHS)))
+
+# Tell SBS what we're building
+$(eval $(call whatmacro,$(RELEASEABLES),WHATTOOLS2))
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/hostsupport/hostbuild/flm/hostbuild.xml	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<build xmlns="http://symbian.com/xml/build"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://symbian.com/xml/build http://symbian.com/xml/build/2_0.xsd">
+
+	<interface name="graphics_simulator.hostbuild" extends="Symbian.UserFLM" flm="hostbuild.flm">
+		<param name="OUTPUTPATH" /> 
+		<param name="TARGET_NAME" /> 
+		<param name="TARGET_TYPE" /> 
+		<param name="MACROS" default="" /> 
+		<param name="INCLUDES" default="" /> 
+		<param name="SOURCE_DIRS" default="" /> 
+		<param name="SOURCE_FOLDER" default="" /> 
+		<param name="SOURCE" default="" /> 
+		<param name="NO_STD_INCLUDE" default="" /> 
+		<param name="LIBS" default="" />
+		<param name="SHARED_LIBS" default="" />
+		<param name="CODE_COVERAGE" default="" />
+		<param name="COMPILE_OPTIONS" default="" />
+		<param name="BUILDINC" default="" />
+		<param name="DLL_WIN_LINKER_OPTS" default="" />
+		<param name="DLL_LIN_LINKER_OPTS" default="" />
+		<param name="SYS_INCLUDES" default="" />
+	</interface>
+
+</build>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/hostsupport/hostbuild/group/bld.inf	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,23 @@
+// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// All rights reserved.
+// This component and the accompanying materials are made available
+// under the terms of the License "Eclipse Public License v1.0"
+// which accompanies this distribution, and is available
+// at the URL "http://www.eclipse.org/legal/epl-v10.html".
+//
+// Initial Contributors:
+// Nokia Corporation - initial contribution.
+//
+// Contributors:
+//
+// Description:
+// Host build extensions
+
+PRJ_PLATFORMS
+TOOLS2
+
+PRJ_EXPORTS
+
+../inc/hostbuild.h          OS_LAYER_PUBLIC_EXPORT_PATH(tools/hostbuild.h)
+../flm/hostbuild.xml        /epoc32/tools/makefile_templates/graphics_simulator/hostbuild.xml
+../flm/hostbuild.flm        /epoc32/tools/makefile_templates/graphics_simulator/hostbuild.flm
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/hostsupport/hostbuild/inc/hostbuild.h	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,112 @@
+// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// All rights reserved.
+// This component and the accompanying materials are made available
+// under the terms of the License "Eclipse Public License v1.0"
+// which accompanies this distribution, and is available
+// at the URL "http://www.eclipse.org/legal/epl-v10.html".
+//
+// Initial Contributors:
+// Nokia Corporation - initial contribution.
+//
+// Contributors:
+//
+// Description:
+// This is the preinclude file for hostbuild
+// 
+//
+
+/**
+ @file
+ @publishedAll
+ @released
+*/
+
+// compiler and STLport things first 
+#define _STLP_THREADS
+#define _STLP_DESIGNATED_DLL
+
+// Pick up relevant macros under __GCC32__, since __GCC32__ is not a valid macro for TOOLS2
+
+#define __NO_CLASS_CONSTS__
+#define __NORETURN__  __attribute__ ((noreturn))
+
+#ifdef __GCCV3__
+#define __NORETURN_TERMINATOR()
+#else
+#define __NORETURN_TERMINATOR()		abort()
+#endif
+
+#define IMPORT_C
+#define IMPORT_D
+#ifdef _WIN32
+#define EXPORT_C __declspec(dllexport)
+#define EXPORT_D __declspec(dllexport)
+#else
+#define EXPORT_C 
+#define EXPORT_D
+#endif
+
+#define NONSHARABLE_CLASS(x) class x
+#define NONSHARABLE_STRUCT(x) struct x
+
+#ifndef __TOOLS2__
+#define __NO_THROW
+#else
+#include <new>
+#ifndef _WIN32
+#include <exception>
+#endif
+#define __NO_THROW throw(std::bad_alloc)
+#endif
+
+typedef long long Int64;
+typedef unsigned long long Uint64;
+#define	I64LIT(x)	x##LL
+#define	UI64LIT(x)	x##ULL
+#define TEMPLATE_SPECIALIZATION template<>
+#define __TText_defined
+#ifdef __TOOLS2__
+#ifndef _WIN32
+#include <stddef.h>  // Linux definition of wchar_t
+#endif
+#endif
+
+typedef wchar_t __TText;
+
+// Symbian things next ///////////////////////////////////////////////////////
+
+#ifdef __PRODUCT_INCLUDE__
+#include __PRODUCT_INCLUDE__
+#endif
+
+// Do not use inline new in e32cmn.h
+#define __PLACEMENT_NEW_INLINE
+#define __PLACEMENT_VEC_NEW_INLINE
+// avoid e32tools/filesystem/include/mingw.inl nonsense
+#ifdef _WIN32
+#define _MINGW_INL
+#endif
+
+// Varargs
+typedef __builtin_va_list va_list;
+#define va_start(v, l) __builtin_va_start(v, l)
+#define va_arg(v, l) __builtin_va_arg(v, l)
+#define va_end(v) __builtin_va_end(v)
+#define VA_LIST va_list
+#define _VA_LIST_DEFINED //To deal with stdarg.h
+#define __VA_LIST_defined //To deal with e32def.h
+#define VA_START(ap,pn) va_start(ap, pn)
+#define VA_ARG(ap,type) va_arg(ap,type)
+#define VA_END(ap)      va_end(ap)
+
+#ifdef __TOOLS2__
+#ifndef _WIN32
+	#define asm(EXPR) __asm(".intel_syntax noprefix\n\t" EXPR)
+#else
+	#define asm __asm
+#endif
+#endif
+
+
+// the end of the pre-include
+
--- a/hostsupport/hostegl/group/bld.inf	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/group/bld.inf	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,54 @@
+/* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and /or associated documentation files
+ * (the "Materials "), to deal in the Materials without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Materials,
+ * and to permit persons to whom the Materials are furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Materials.
+ *
+ * THE MATERIALS ARE 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 OR COPYRIGHT HOLDERS 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 MATERIALS OR
+ * THE USE OR OTHER DEALINGS IN THE MATERIALS.
+ *
+ * Initial Contributors:
+ * Nokia Corporation - initial contribution.
+ *
+ * Contributors:
+ *
+ * Description:
+ * Build information for host EGL
+ */
+
+PRJ_PLATFORMS
+TOOLS2
+
+PRJ_EXPORTS
+
+../inc/EGL/egl.h            OS_LAYER_PUBLIC_EXPORT_PATH(tools/EGL/egl.h)
+../inc/EGL/eglext.h         OS_LAYER_PUBLIC_EXPORT_PATH(tools/EGL/eglext.h)
+../inc/EGL/eglplatform.h    OS_LAYER_PUBLIC_EXPORT_PATH(tools/EGL/eglplatform.h)
+
+../inc/KHR/khrplatform.h    OS_LAYER_PUBLIC_EXPORT_PATH(tools/KHR/khrplatform.h)
+
+PRJ_EXTENSIONS
+
+// Dynamic library.
+start extension graphics_simulator/hostbuild
+option TARGET_NAME libEGL
+option TARGET_TYPE dll
+option SOURCE_DIRS ../src ../src/win32
+option INCLUDES ../inc ../../../inc
+option SYS_INCLUDES OS_LAYER_PUBLIC_EXPORT_PATH(tools)
+option MACROS KHRONOS_APICALL_EXPORT EGLI_USE_SIMULATOR_EXTENSIONS
+option COMPILE_OPTIONS -msse2 -mfpmath=sse -march=pentium4
+option NO_STD_INCLUDE ON
+end
--- a/hostsupport/hostegl/inc/EGLConfig.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLConfig.h	Tue Nov 02 09:46:02 2010 +0000
@@ -117,4 +117,4 @@
 
     CTransparentColor  m_transparentColor;
 };
-#endif //_EGLCONFIG_H_
\ No newline at end of file
+#endif //_EGLCONFIG_H_
--- a/hostsupport/hostegl/inc/EGLContext.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLContext.h	Tue Nov 02 09:46:02 2010 +0000
@@ -73,4 +73,4 @@
     struct EGLINativeGLFunctions*   m_nativeGLFunctions;
 };
 
-#endif //_EGLCONTEXT_H_
\ No newline at end of file
+#endif //_EGLCONTEXT_H_
--- a/hostsupport/hostegl/inc/EGLDisplay.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLDisplay.h	Tue Nov 02 09:46:02 2010 +0000
@@ -79,4 +79,4 @@
     std::vector<CEGLImage*>     m_images;
     EGLint                      m_processId;
 };
-#endif //_EGLDISPLAY_H_
\ No newline at end of file
+#endif //_EGLDISPLAY_H_
--- a/hostsupport/hostegl/inc/EGLOs.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLOs.h	Tue Nov 02 09:46:02 2010 +0000
@@ -77,4 +77,4 @@
     static IEGLtoGLES2Interface* LoadGLES2Interface( EGLILibraryHandle& libraryHandle );
 };
 
-#endif //_EGLOS_H_
\ No newline at end of file
+#endif //_EGLOS_H_
--- a/hostsupport/hostegl/inc/EGLProcess.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLProcess.h	Tue Nov 02 09:46:02 2010 +0000
@@ -59,4 +59,4 @@
     std::vector<CEGLThread*>    m_threads;
     CEGLThread*                 m_currentThread;
 };
-#endif //_EGLPROCESS_H_
\ No newline at end of file
+#endif //_EGLPROCESS_H_
--- a/hostsupport/hostegl/inc/EGLStructs.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLStructs.h	Tue Nov 02 09:46:02 2010 +0000
@@ -76,4 +76,4 @@
 	EGLContext	context;
 	};
 
-#endif // _EGLSTRUCTS_H_
\ No newline at end of file
+#endif // _EGLSTRUCTS_H_
--- a/hostsupport/hostegl/inc/EGLThread.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLThread.h	Tue Nov 02 09:46:02 2010 +0000
@@ -75,4 +75,4 @@
     // on thread specific API calls.
     EGLint          m_supportedApis; 
 };
-#endif //_EGLTHREAD_H_
\ No newline at end of file
+#endif //_EGLTHREAD_H_
--- a/hostsupport/hostegl/inc/EGLUtils.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLUtils.h	Tue Nov 02 09:46:02 2010 +0000
@@ -73,4 +73,4 @@
 extern  void DestroyPointerVector( std::vector<T*>& vector );
 
 
-#endif //_EGLUTILS_H_
\ No newline at end of file
+#endif //_EGLUTILS_H_
--- a/hostsupport/hostegl/inc/EGLWindowSurface.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/EGLWindowSurface.h	Tue Nov 02 09:46:02 2010 +0000
@@ -59,4 +59,4 @@
     EGLint              m_swapInterval;
     EGLIOsWindowContext* m_osContext;
 };
-#endif //_EGLWINDOWSURFACE_H_
\ No newline at end of file
+#endif //_EGLWINDOWSURFACE_H_
--- a/hostsupport/hostegl/inc/TransparentColor.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/TransparentColor.h	Tue Nov 02 09:46:02 2010 +0000
@@ -59,4 +59,4 @@
     EGLint  m_greenValue;
     EGLint  m_blueValue;
 };
-#endif // _TRANSPARENTCOLOR_H_
\ No newline at end of file
+#endif // _TRANSPARENTCOLOR_H_
--- a/hostsupport/hostegl/inc/eglDefinitions.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/inc/eglDefinitions.h	Tue Nov 02 09:46:02 2010 +0000
@@ -73,13 +73,13 @@
 #   if defined(_DEBUG)
 #       define EGLI_ASSERT assert
 #   else
-#      define EGLI_ASSERT
+#      define EGLI_ASSERT (void)
 #   endif //_DEBUG
 #else
 #   if !defined(NDEBUG)
 #       define EGLI_ASSERT assert
 #   else
-#       define EGLI_ASSERT
+#       define EGLI_ASSERT (void)
 #   endif
 #endif
 
--- a/hostsupport/hostegl/src/EGLConfig.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/EGLConfig.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -37,7 +37,7 @@
 const int KPbufferPixels = KPbufferHeight * KPbufferWidth;
 
 CEGLConfig::CEGLConfig(void) :
-    m_nativeVisualId( NULL )
+    m_nativeVisualId( 0 )
     {
     }
 
@@ -72,7 +72,7 @@
     m_maxSwapInterval( maxSwapInterval ),
     m_minSwapInterval( minSwapInterval ),
     m_nativeRenderable( nativeRenderable ),
-    m_nativeVisualId( NULL ),
+    m_nativeVisualId( 0 ),
     m_nativeVisualType( nativeVisualType ),
     m_renderableType( renderableType ),
     m_sampleBuffers( samples > 1 ? 1 : 0 ),
@@ -814,9 +814,9 @@
     
     if( m_colorDescriptor.AlphaMaskSize() < filter.m_colorDescriptor.AlphaMaskSize() ) return false;
     
-    if( filter.m_bindToTexRGB != EGL_DONT_CARE && (m_bindToTexRGB != filter.m_bindToTexRGB) ) return false;
+    if( (EGLint)filter.m_bindToTexRGB != EGL_DONT_CARE && (m_bindToTexRGB != filter.m_bindToTexRGB) ) return false;
     
-    if( filter.m_bindToTexRGBA != EGL_DONT_CARE && (m_bindToTexRGBA != filter.m_bindToTexRGBA) ) return false;
+    if( (EGLint)filter.m_bindToTexRGBA != EGL_DONT_CARE && (m_bindToTexRGBA != filter.m_bindToTexRGBA) ) return false;
     
     if( filter.m_colorDescriptor.Format() != EGL_DONT_CARE )
         {
@@ -825,7 +825,7 @@
         if( thisBufType != filterBufType ) return false;
         }
 
-    if( filter.m_configCaveat != EGL_DONT_CARE && (m_configCaveat != filter.m_configCaveat) ) return false;
+    if( (EGLint)filter.m_configCaveat != EGL_DONT_CARE && (m_configCaveat != filter.m_configCaveat) ) return false;
 
     if( m_configId == filter.m_configId ) return false;
     
@@ -839,7 +839,7 @@
 
     if( filter.m_minSwapInterval != EGL_DONT_CARE && (m_minSwapInterval != filter.m_minSwapInterval) ) return false;
 
-    if( filter.m_nativeRenderable != EGL_DONT_CARE && (m_nativeRenderable != filter.m_nativeRenderable) ) return false;
+    if( (EGLint)filter.m_nativeRenderable != EGL_DONT_CARE && (m_nativeRenderable != filter.m_nativeRenderable) ) return false;
 
     if( filter.m_nativeVisualType != EGL_DONT_CARE && (m_nativeVisualType != filter.m_nativeVisualType) ) return false;
 
--- a/hostsupport/hostegl/src/EGLDisplay.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/EGLDisplay.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -38,7 +38,6 @@
 #include "ColorDescriptor.h"
 #include "EGLOs.h"
 #include "EGLUtils.h"
-#include "EGLState.h"
 #include "EGLProcess.h"
 #include "EGLThread.h"
 
@@ -186,8 +185,6 @@
     bool ret = true;
     std::vector<CEGLSurface*> boundSurfaces;
     std::vector<CEGLSurface*>::iterator sIter = m_surfaces.begin();
-    CEGLState* state = getState();
-    CEGLThread* thread = state->GetCurrentProcess()->CurrentThread();
     while( sIter != m_surfaces.end() )
         {
         if( (*sIter)->IsTerminated() || !((*sIter)->RemoveRef()) )
--- a/hostsupport/hostegl/src/EGLImage.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/EGLImage.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -38,8 +38,8 @@
 
 CEGLImage::CEGLImage( EGLenum target, EGLClientBuffer buffer, 
                       SurfaceDescriptor desc, void* data) :
+    m_target( target ),
     m_buffer( buffer ),
-    m_target( target ),
 	m_data(data)
     {
     m_siblings = EGLI_NEW EGLImageSibling;
@@ -115,8 +115,6 @@
             case EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_KHR:
                 {
                 // GLES
-                IEGLtoGLES2Interface* iFace = (IEGLtoGLES2Interface*)state->GLESInterface(2);
-                //iFace->UpdateBuffers(
                 }
                 break;
             default:
--- a/hostsupport/hostegl/src/EGLState.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/EGLState.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -53,7 +53,7 @@
     m_GLES2Interface( NULL ),
 	m_hostGL( NULL ),
     m_supportedApis( 0 ),
-	m_defaultDisplay( NULL ),
+	m_defaultDisplay( 0 ),
 	m_dummyWindow( NULL )
     {
 
@@ -446,9 +446,6 @@
 				{
 				if( surface != currentGLESReadSurface )
 					{
-					EGLINativeContextType glesCopyContext = NULL;
-                    EGLINativeDisplayType glesCopyDisplay = NULL;
-                    EGLINativeGLFunctions* funcs = NULL;
 					bool pbuffer = ( surface->Type() == CEGLSurface::PBUFFER_SURFACE );
 					if( pbuffer )
 						{
@@ -461,12 +458,7 @@
 						}
 					else if( surface->Type() == CEGLSurface::WINDOW_SURFACE )
 						{
-						// \todo Remove this or handle window surface sync properly
-						/*
-						funcs = thread->CurrentGLESContext()->NativeGLFunctions();
-						glesCopyContext = thread->CurrentGLESContext()->NativeContext();
-						glesCopyDisplay = ((CEGLWindowSurface*)surface)->OsContext()->glesDisplay;
-						*/
+						// \todo Handle window surface sync properly
 						}
 					if( !(GLESInterface(glesVersion)->CopyBuffers(surface->GLESColorBuffer(), surface->Descriptor())) )
 						{
--- a/hostsupport/hostegl/src/EGLSurface.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/EGLSurface.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -108,7 +108,6 @@
     EGLint blueSize = colorDesc->BlueSize();
     EGLint greenSize = colorDesc->GreenSize();
     EGLint redSize = colorDesc->RedSize();
-    EGLint luminanceSize = colorDesc->LuminanceSize();
 
     if( colorDesc->isLuminance() )
         {
--- a/hostsupport/hostegl/src/EGLThread.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/EGLThread.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -123,4 +123,4 @@
     {
     if( read ) *read = m_currentGLESReadSurface;
     if( draw ) *draw = m_currentGLESDrawSurface;
-    }
\ No newline at end of file
+    }
--- a/hostsupport/hostegl/src/eglapi.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/eglapi.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -57,7 +57,9 @@
 #endif
 
 static CEGLState* g_eglState = NULL;
+#if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
 static bool g_lockInitialized = false;
+#endif
 EGLI_LOCK g_eglLock;
 
 CEGLState* getState()
@@ -457,14 +459,14 @@
     colorDesc->SetAttribute( EGL_COLOR_BUFFER_TYPE, EGL_RGB_BUFFER );
     CEGLConfig* filter = EGLI_NEW CEGLConfig(
                     *colorDesc,
-                    EGL_DONT_CARE,  
-                    EGL_DONT_CARE,
-                    EGL_DONT_CARE,
+                    (EGLBoolean)EGL_DONT_CARE,  
+                    (EGLBoolean)EGL_DONT_CARE,
+                    (EGLenum)EGL_DONT_CARE,
                     EGL_DONT_CARE,
                     0, 0, 0,
                     EGL_DONT_CARE,
                     EGL_DONT_CARE,
-                    EGL_DONT_CARE,
+                    (EGLBoolean)EGL_DONT_CARE,
                     EGL_DONT_CARE,
                     EGL_OPENGL_ES_BIT,
                     0, 0, 0,
@@ -906,7 +908,6 @@
         }
 
     // \note EGLI_ENTER_RET macro will fail if thread allocation didn't succeed
-    CEGLThread* thread = getThread();
 
     surface->Lock();
     //TODO: client apis
@@ -1206,9 +1207,8 @@
         state->RemoveProcess( process->Id() );
         process = NULL;
         }
-#else
+#endif
     releaseState();
-#endif
     return EGL_TRUE;
     }
 
@@ -1940,8 +1940,8 @@
                         }
                     context->SetNativeGLFucntions( nativeFuncs );
                     }
-                EGLINativeDisplayType drawDC = NULL;
-                EGLINativeDisplayType readDC = NULL;
+                EGLINativeDisplayType drawDC = 0;
+                EGLINativeDisplayType readDC = 0;
                 if( drawSurface->Type() == CEGLSurface::PBUFFER_SURFACE ) 
                     {
                     drawDC = ((CEGLPbufferSurface*)drawSurface)->NativeDisplay();
--- a/hostsupport/hostegl/src/win32/EGLOs.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostegl/src/win32/EGLOs.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -184,8 +184,8 @@
 EGLINativeContextType CEGLOs::CreateNativeContext( const CEGLConfig& config, EGLINativeDisplayType display, EGLINativeContextType shareContext )
     {
     EGLINativeContextType ret = NULL;
+#if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
     DWORD error = ERROR_SUCCESS;
-#if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
     PIXELFORMATDESCRIPTOR pfd;
     memset(&pfd, 0, sizeof(PIXELFORMATDESCRIPTOR));
     CEGLOs::ConfigToNativePixelFormat( config, &pfd );
@@ -216,7 +216,11 @@
 
 EGLINativeContextType CEGLOs::CurrentNativeContext()
     {
+#if defined(EGLI_USE_SIMULATOR_EXTENSIONS)
+    return 0;
+#else
     return wglGetCurrentContext();
+#endif
     }
 
 EGLINativeDisplayType CEGLOs::CurrentNativeSurface()
@@ -224,7 +228,7 @@
 #if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
     return wglGetCurrentDC();
 #else
-    return NULL;
+    return 0;
 #endif
     }
 
@@ -277,8 +281,8 @@
 bool CEGLOs::InitializeNativeGLFunctions( struct EGLINativeGLFunctions* func, EGLINativeDisplayType display, EGLINativeContextType context )
     {
     bool ret = true;
+#if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
     DWORD error = ERROR_SUCCESS;
-#if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
     HDC currentDC = wglGetCurrentDC();
     HGLRC currentContext = wglGetCurrentContext();
     
@@ -490,7 +494,7 @@
     //return (EGLINativeDisplayType)CreateDC(TEXT("DISPLAY"), TEXT("DISPLAY")/*NULL*/, NULL, NULL);
     //return (EGLINativeDisplayType)GetDC(NULL);
     //return GetWindowDC(NULL);
-    return NULL;
+    return 0;
     }
 
 void CEGLOs::DestroyDefaultDisplay( EGLINativeDisplayType display )
@@ -504,11 +508,6 @@
 
 EGLINativeWindowType CEGLOs::CreateNativeWindow( int width, int height )
     {
-    int xBorder = GetSystemMetrics( SM_CXBORDER );
-    int yBorder = GetSystemMetrics( SM_CYBORDER );
-    int caption = GetSystemMetrics( SM_CYCAPTION );
-    
-
     WNDCLASS wndclass;
     wndclass.style		   = 0;
     wndclass.lpfnWndProc   = WndProc;
@@ -618,8 +617,8 @@
         return NULL;
         }
     ctx->window = wnd;
-    ctx->vgDisplay = NULL;
-    ctx->glesDisplay = NULL;
+    ctx->vgDisplay = 0;
+    ctx->glesDisplay = 0;
     ctx->pixmap = NULL;
     ctx->osBuffer = NULL;
     ctx->width = 0;
@@ -742,11 +741,13 @@
 
 void* CEGLOs::GetGLProcAddress(EGLILibraryHandle& libraryHandle, const char* proc)
     {
-    void* addr = GetProcAddress(libraryHandle, proc);
+    void* addr = (void*)GetProcAddress(libraryHandle, proc);
+#if !defined(EGLI_USE_SIMULATOR_EXTENSIONS)
 	if(!addr)
 		{
-		addr = wglGetProcAddress(proc);
+		addr = (void*)wglGetProcAddress(proc);
 		}
+#endif
 
 	return addr;
     }
--- a/hostsupport/hostopengles11/group/bld.inf	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/group/bld.inf	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,56 @@
+/* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and /or associated documentation files
+ * (the "Materials "), to deal in the Materials without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Materials,
+ * and to permit persons to whom the Materials are furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Materials.
+ *
+ * THE MATERIALS ARE 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 OR COPYRIGHT HOLDERS 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 MATERIALS OR
+ * THE USE OR OTHER DEALINGS IN THE MATERIALS.
+ *
+ * Initial Contributors:
+ * Nokia Corporation - initial contribution.
+ *
+ * Contributors:
+ *
+ * Description:
+ * Build information for host OpenGL ES 1.1
+ */
+
+PRJ_PLATFORMS
+TOOLS2
+
+PRJ_EXPORTS
+
+../inc/GLES/gl.h             OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES/gl.h)
+../inc/GLES/glext.h          OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES/glext.h)
+../inc/GLES/glplatform.h     OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES/glplatform.h)
+../inc/GLES/glextplatform.h  OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES/glextplatform.h)
+
+// Backwards-compatibility support header (includes the real egl.h)
+../inc/GLES/egl.h            OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES/egl.h)
+
+PRJ_EXTENSIONS
+
+// Dynamic library.
+start extension graphics_simulator/hostbuild
+option TARGET_NAME      libGLESv1
+option TARGET_TYPE      dll
+option SOURCE_DIRS      ../src
+option INCLUDES         ../inc ../../../inc
+option SYS_INCLUDES     OS_LAYER_PUBLIC_EXPORT_PATH(tools)
+option MACROS           KHRONOS_APICALL_EXPORT
+option COMPILE_OPTIONS  -msse2 -mfpmath=sse -march=pentium4
+option NO_STD_INCLUDE   ON
+end
--- a/hostsupport/hostopengles11/inc/EGLInterface.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/EGLInterface.h	Tue Nov 02 09:46:02 2010 +0000
@@ -48,6 +48,7 @@
 {
 public:
     EGLtoGLESInterface();
+    virtual ~EGLtoGLESInterface() {}
 
     void SetEGLInterface(IGLEStoEGLInterface* egl);
 	void* CreateContext(void* nativeContext);
@@ -69,4 +70,4 @@
 	std::set<GLESContext*> m_contexts;
 };
 
-#endif // _EGLINTERFACE_H_
\ No newline at end of file
+#endif // _EGLINTERFACE_H_
--- a/hostsupport/hostopengles11/inc/GLES/glextplatform.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/GLES/glextplatform.h	Tue Nov 02 09:46:02 2010 +0000
@@ -121,4 +121,4 @@
 }
 #endif
 
-#endif /* glextplatform_h */
\ No newline at end of file
+#endif /* glextplatform_h */
--- a/hostsupport/hostopengles11/inc/GLESArray.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/GLESArray.h	Tue Nov 02 09:46:02 2010 +0000
@@ -84,4 +84,4 @@
 	const GLESBuffer* m_buffer;
 };
 
-#endif // _GLESARRAY_H_
\ No newline at end of file
+#endif // _GLESARRAY_H_
--- a/hostsupport/hostopengles11/inc/GLESContext.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/GLESContext.h	Tue Nov 02 09:46:02 2010 +0000
@@ -202,4 +202,4 @@
 #define GLES_ERROR_RET(ERROR, RETVAL) GLES_ERROR_IF_RET(true, ERROR, RETVAL)
 #define GLES_ERROR(ERROR) GLES_ERROR_IF(true, ERROR)
 
-#endif // _GLESCONTEXT_H_
\ No newline at end of file
+#endif // _GLESCONTEXT_H_
--- a/hostsupport/hostopengles11/inc/GLESTexture.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/GLESTexture.h	Tue Nov 02 09:46:02 2010 +0000
@@ -64,4 +64,4 @@
 GLenum glesMapCompressedToBaseFormat(GLenum format);
 void* glesUncompressImage(int level, GLenum format, int width, int height, int imageSize, const void* data);
 
-#endif // _GLES_TEXTURE_H_
\ No newline at end of file
+#endif // _GLES_TEXTURE_H_
--- a/hostsupport/hostopengles11/inc/glDefinitions.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/glDefinitions.h	Tue Nov 02 09:46:02 2010 +0000
@@ -34,4 +34,4 @@
 #define GL_VERSION_MAJOR 1
 #define GL_VERSION_MINOR 1
 
-#endif // _gldefinitions_h_
\ No newline at end of file
+#endif // _gldefinitions_h_
--- a/hostsupport/hostopengles11/inc/glesGet.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/glesGet.h	Tue Nov 02 09:46:02 2010 +0000
@@ -48,4 +48,4 @@
 
 bool glesGetParameter(const GLESContext& context, const GLESDesktopGL &dgl, GLenum pname, GLESGetType dstType, void* params);
 
-#endif // _GLESGET_H_
\ No newline at end of file
+#endif // _GLESGET_H_
--- a/hostsupport/hostopengles11/inc/glesInternal.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/inc/glesInternal.h	Tue Nov 02 09:46:02 2010 +0000
@@ -50,7 +50,7 @@
 #if defined(_DEBUG)
 #define GLES_ASSERT assert
 #else // defined(_DEBUG)
-#define GLES_ASSERT
+#define GLES_ASSERT (void)
 #endif // !defined(_DEBUG)
 
 #define GLES_NEW new(std::nothrow)
@@ -133,4 +133,4 @@
 	return r;
 }
 
-#endif // _GLINTERNAL_H_
\ No newline at end of file
+#endif // _GLINTERNAL_H_
--- a/hostsupport/hostopengles11/src/EGLInterface.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/src/EGLInterface.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -273,7 +273,7 @@
 
 int EGLtoGLESInterface::BindTexImage( void* surface, int level, bool generateMipmap, const SurfaceDescriptor* desc, void* buffer )
 {
-    GLES_ENTER_RET(NULL);
+    GLES_ENTER_RET(0);
 
 	GLuint ret = 0;
 
--- a/hostsupport/hostopengles11/src/GLESContext.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/src/GLESContext.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -32,9 +32,9 @@
 #include "GLESTexture.h"
 
 GLESContext::GLESContext(void* nativeContext) :
+	m_initialized(false),
 	m_nativeContext(nativeContext),
-	m_texCoordArray(NULL),
-	m_initialized(false)
+	m_texCoordArray(NULL)
 {
 }
 
@@ -84,7 +84,7 @@
 	// The maximum number of texture units supported by the wrapper depends on the number
 	// of bits in the array state variable (four bits are used by vertex, normal, color
 	// and point size arrays).
-	m_maxTextureUnits = GLES_MIN(maxTextureUnits, sizeof(m_enabledArrays) * 8 - 4);
+	m_maxTextureUnits = GLES_MIN(maxTextureUnits, (int)(sizeof(m_enabledArrays) * 8 - 4));
 	m_maxClipPlanes = maxClipPlanes;
 	m_maxLights = maxLights;
 
@@ -338,4 +338,4 @@
 {
 	void* context = EGLtoGLESInterface::GetEGLInterface()->GetGLESContext();
 	return context;
-}
\ No newline at end of file
+}
--- a/hostsupport/hostopengles11/src/GLESDesktopGL.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/src/GLESDesktopGL.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -192,4 +192,4 @@
 	return success;
 }
 
-#undef LOAD
\ No newline at end of file
+#undef LOAD
--- a/hostsupport/hostopengles11/src/GLESTexture.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/src/GLESTexture.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -334,4 +334,4 @@
 	}
 
 	return uncompressedData;
-}
\ No newline at end of file
+}
--- a/hostsupport/hostopengles11/src/glesapi.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles11/src/glesapi.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -2105,7 +2105,7 @@
 	GLES_ERROR_IF(!isValidPixelFormatEnum(internalformat), GL_INVALID_ENUM);
 	GLES_ERROR_IF(!isValidPixelFormatEnum(format), GL_INVALID_ENUM);
 	GLES_ERROR_IF(!isValidPixelTypeEnum(type), GL_INVALID_ENUM);
-	GLES_ERROR_IF(internalformat != format, GL_INVALID_ENUM);
+	GLES_ERROR_IF(internalformat != (GLint)format, GL_INVALID_ENUM);
 	GLES_ERROR_IF(isPalettedFormat(internalformat), GL_INVALID_OPERATION);
 	
 	ctx->DGL().glTexImage2D (target, level, internalformat, width, height, border, format, type, pixels);
@@ -2224,4 +2224,4 @@
 
 #ifdef __cplusplus
 }
-#endif
\ No newline at end of file
+#endif
--- a/hostsupport/hostopengles20/group/bld.inf	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopengles20/group/bld.inf	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,52 @@
+/* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and /or associated documentation files
+ * (the "Materials "), to deal in the Materials without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Materials,
+ * and to permit persons to whom the Materials are furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Materials.
+ *
+ * THE MATERIALS ARE 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 OR COPYRIGHT HOLDERS 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 MATERIALS OR
+ * THE USE OR OTHER DEALINGS IN THE MATERIALS.
+ *
+ * Initial Contributors:
+ * Nokia Corporation - initial contribution.
+ *
+ * Contributors:
+ *
+ * Description:
+ * Build information for host OpenGL ES 2.0
+ */
+
+PRJ_PLATFORMS
+TOOLS2
+
+PRJ_EXPORTS
+
+../inc/GLES2/gl2.h          OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES2/gl2.h)
+../inc/GLES2/gl2ext.h       OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES2/gl2ext.h)
+../inc/GLES2/gl2platform.h  OS_LAYER_PUBLIC_EXPORT_PATH(tools/GLES2/gl2platform.h)
+
+PRJ_EXTENSIONS
+
+// Dynamic library.
+start extension graphics_simulator/hostbuild
+option TARGET_NAME      libGLESv2
+option TARGET_TYPE      dll
+option SOURCE_DIRS      ../src
+option INCLUDES         ../inc ../../../inc
+option SYS_INCLUDES     OS_LAYER_PUBLIC_EXPORT_PATH(tools)
+option MACROS           KHRONOS_APICALL_EXPORT CONFIG_OFFSCREEN BUILD_GLES2
+option COMPILE_OPTIONS  -msse2 -mfpmath=sse -march=pentium4
+option NO_STD_INCLUDE   ON
+end
--- a/hostsupport/hostopenvg/group/bld.inf	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/group/bld.inf	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,54 @@
+/* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and /or associated documentation files
+ * (the "Materials "), to deal in the Materials without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Materials,
+ * and to permit persons to whom the Materials are furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Materials.
+ *
+ * THE MATERIALS ARE 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 OR COPYRIGHT HOLDERS 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 MATERIALS OR
+ * THE USE OR OTHER DEALINGS IN THE MATERIALS.
+ *
+ * Initial Contributors:
+ * Nokia Corporation - initial contribution.
+ *
+ * Contributors:
+ *
+ * Description:
+ * Build information for host OpenVG
+ */
+
+PRJ_PLATFORMS
+TOOLS2
+
+PRJ_EXPORTS
+
+../inc/VG/openvg.h          OS_LAYER_PUBLIC_EXPORT_PATH(tools/VG/openvg.h)
+../inc/VG/vgext.h           OS_LAYER_PUBLIC_EXPORT_PATH(tools/VG/vgext.h)
+../inc/VG/vgplatform.h      OS_LAYER_PUBLIC_EXPORT_PATH(tools/VG/vgplatform.h)
+../inc/VG/vgu.h             OS_LAYER_PUBLIC_EXPORT_PATH(tools/VG/vgu.h)
+
+PRJ_EXTENSIONS
+
+// Dynamic library.
+start extension graphics_simulator/hostbuild
+option TARGET_NAME      libOpenVG
+option TARGET_TYPE      dll
+option SOURCE_FOLDER    ../src
+option SOURCE           riApi.cpp riContext.cpp riFont.cpp riImage.cpp riMath.cpp riPath.cpp riPixelPipe.cpp riRasterizer.cpp riUtils.cpp riVGU.cpp sfBlitter.cpp sfDynamicBlitter.cpp sfDynamicPixelPipe.cpp sfEGLInterface.cpp
+option INCLUDES         ../inc ../../../inc
+option SYS_INCLUDES     OS_LAYER_PUBLIC_EXPORT_PATH(tools)
+option MACROS           OPENVG_DLL_EXPORTS NOMINMAX USE_FULL_EGL
+option COMPILE_OPTIONS  -msse2 -mfpmath=sse -march=pentium4
+option NO_STD_INCLUDE   ON
+end
--- a/hostsupport/hostopenvg/src/riApi.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/riApi.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -2002,7 +2002,7 @@
          
         //Drawable drawable(Color::formatToDescriptor(VG_A_8), curr->getWidth(), curr->getHeight(), curr->getNumSamples(), 1);    //TODO 0 mask bits (mask buffer is not used)
 
-        Rasterizer& rasterizer = context->m_rasterizer;
+        OpenVGRI::Rasterizer& rasterizer = context->m_rasterizer;
         rasterizer.clear();
 
         rasterizer.setScissoring(context->m_scissoring ? true : false);
@@ -2447,7 +2447,7 @@
     if(!drawable)
         return false;   //no EGL surface is current at the moment
 
-    Rasterizer& rasterizer = context->m_rasterizer;
+    OpenVGRI::Rasterizer& rasterizer = context->m_rasterizer;
     rasterizer.clear();
 
     if(context->m_scissoring)
@@ -3098,7 +3098,7 @@
     p2 *= 1.0f/p2.z;
     p3 *= 1.0f/p3.z;
 
-    Rasterizer& rasterizer = context->m_rasterizer;
+    OpenVGRI::Rasterizer& rasterizer = context->m_rasterizer;
     rasterizer.clear();
 
     rasterizer.setScissoring(context->m_scissoring ? true : false);
@@ -3812,14 +3812,14 @@
     eglvgGetImageDescriptor( image, desc, width, height, stride );
     // There is some error.
     // EGLImage is null or EGLImage target is EGL_VG_PARENT_IMAGE_KHR.
-    RI_IF_ERROR(!width || !height || !stride, VG_ILLEGAL_ARGUMENT_ERROR, NULL);
+    RI_IF_ERROR(!width || !height || !stride, VG_ILLEGAL_ARGUMENT_ERROR, VG_INVALID_HANDLE);
     // Data is created in EGLImage class.
     data = (OpenVGRI::RIuint8*)eglvgGetImageData( image );    
     // Create VGImage
     // allowedQuality = VG_IMAGE_QUALITY_NONANTIALIASED | VG_IMAGE_QUALITY_FASTER | VG_IMAGE_QUALITY_BETTER
     ret = vgCreateImage( desc.vgFormat, width, height, VG_IMAGE_QUALITY_NONANTIALIASED );
     // If VGImage is not created raise error and return null
-    RI_IF_ERROR(!ret, VG_UNSUPPORTED_IMAGE_FORMAT_ERROR, NULL);
+    RI_IF_ERROR(!ret, VG_UNSUPPORTED_IMAGE_FORMAT_ERROR, VG_INVALID_HANDLE);
     // Set data for VGImage.
     // This will copy that data-object.
     vgImageSubData( ret, 
--- a/hostsupport/hostopenvg/src/riDefs.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/riDefs.h	Tue Nov 02 09:46:02 2010 +0000
@@ -153,7 +153,7 @@
 #endif
 
 #if defined(RI_DEBUG)
-#   if defined(_WIN32)
+#   if defined(_WIN32) && !defined(__GNUG__)
 #       define RI_TRACE(...) do { \
         char buf[512]; \
         snprintf(buf, sizeof(buf), __VA_ARGS__); \
--- a/hostsupport/hostopenvg/src/riMath.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/riMath.h	Tue Nov 02 09:46:02 2010 +0000
@@ -246,7 +246,7 @@
     return r;
 }
 
-RI_INLINE RIfloat RI_FLOAT_TO_FX(RIfloat f, unsigned int n) { return (RIfloat)RI_ROUND_TO_INT(f * (RIfloat)RI_SHL(1, n)); }
+RI_INLINE int RI_FLOAT_TO_FX(RIfloat f, unsigned int n) { return RI_ROUND_TO_INT(f * (RIfloat)RI_SHL(1, n)); }
 
 class Matrix3x3;
 class Vector2;
--- a/hostsupport/hostopenvg/src/riPixelPipe.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/riPixelPipe.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -40,9 +40,11 @@
 #ifndef __SFDYNAMICPIXELPIPE_H
 #   include "sfDynamicPixelPipe.h"
 #endif
+#if defined(RI_COMPILE_LLVM_BYTECODE)
 #ifndef __SFCOMPILER_H
 #   include "sfCompiler.h"
 #endif
+#endif
 
 //==============================================================================================
 
@@ -1417,7 +1419,7 @@
 
 void PixelPipe::fillSpans(PPVariants& variants, const Span* spans, int nSpans) const
 {
-#if 1
+#if defined(RI_COMPILE_LLVM_BYTECODE)
     PPCompiler& compiler = PPCompiler::getCompiler();
 
     PPCompiler::PixelPipeHandle handle = compiler.compilePixelPipeline(m_derivedState);
--- a/hostsupport/hostopenvg/src/riRasterizer.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/riRasterizer.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -33,10 +33,12 @@
 
 #include "riRasterizer.h"
 
+#if defined(RI_COMPILE_LLVM_BYTECODE)
 // TEMP!
 #ifndef __SFCOMPILER_H
 #   include "sfCompiler.h"
 #endif
+#endif
 
 
 namespace OpenVGRI
@@ -450,7 +452,12 @@
 #if defined(USE_SSE2)
 RI_INLINE static __m128i mm_mul4x32(const __m128i a, const __m128i b) {
      __m128i res;
-#if (_MSC_VER > 1400 )
+#if defined(__GNUG__)
+     __m128i m0 = _mm_mul_epu32(a, _mm_shuffle_epi32(b, _MM_SHUFFLE(1, 1, 0, 0)));
+     __m128i m1 = _mm_mul_epu32(a, _mm_shuffle_epi32(b, _MM_SHUFFLE(3, 3, 2, 2)));
+
+     res = _mm_cvtps_epi32(_mm_shuffle_ps(_mm_cvtepi32_ps(m0), _mm_cvtepi32_ps(m1), _MM_SHUFFLE(2, 0, 2, 0)));
+#elif (_MSC_VER > 1400)
      // \todo Simpler way to do this on intel?
      __m128i m0 = _mm_mul_epu32(a, _mm_shuffle_epi32(b, _MM_SHUFFLE(1, 1, 0, 0)));
      __m128i m1 = _mm_mul_epu32(a, _mm_shuffle_epi32(b, _MM_SHUFFLE(3, 3, 2, 2)));
@@ -785,8 +792,6 @@
     }
 
 #endif
-    int debugMagic = 0;
-
     m_aet.clear();
 
 #if defined(RI_DEBUG)
--- a/hostsupport/hostopenvg/src/riUtils.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/riUtils.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -131,7 +131,9 @@
     } 
     else
     {
+#if defined(RI_DEBUG)
         int new_ib = (ib + bitSize) & 0x1f;
+#endif
         RI_ASSERT((ib + bitSize == 32) ? new_ib == 0 : true);
         hash[idw] |= (bits << ib);
     }
--- a/hostsupport/hostopenvg/src/sfBlitter.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/sfBlitter.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -20,9 +20,13 @@
  * THE USE OR OTHER DEALINGS IN THE MATERIALS.
  */
 
-#include "sfBlitter.h"
+#ifndef __SFDYNAMICBLITTER_H
+#include "sfDynamicBlitter.h"
+#endif
 
+#if defined(RI_COMPILE_LLVM_BYTECODE)
 #include "sfCompiler.h"
+#endif
 
 namespace OpenVGRI {
 
@@ -108,7 +112,7 @@
 
 void DynamicBlitter::blit()
 {
-#if 1
+#if defined(RI_COMPILE_LLVM_BYTECODE)
     bool compiledBlitter = false;
     {
         PPCompiler& compiler = PPCompiler::getCompiler();
@@ -125,7 +129,7 @@
     if (!compiledBlitter)
 #endif
     {
-        executeBlitter(getSignatureState(), getUniforms());
+        OpenVGRI::executeBlitter(getSignatureState(), getUniforms());
     }
 }
 
--- a/hostsupport/hostopenvg/src/sfEGLInterface.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/sfEGLInterface.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -182,8 +182,6 @@
 
     int w = desc->m_width;
     int h = desc->m_height;
-    int stride = OpenVGRI::Image::descriptorToStride(vgColorDescriptor, w);
-    size_t bufSize = h * stride;
 
     OpenVGRI::RIuint8* dataPtr = NULL;
 
--- a/hostsupport/hostopenvg/src/sfEGLInterface.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/hostsupport/hostopenvg/src/sfEGLInterface.h	Tue Nov 02 09:46:02 2010 +0000
@@ -48,7 +48,7 @@
 {
 public:
     EGLtoVGInterface();
-    ~EGLtoVGInterface();
+    virtual ~EGLtoVGInterface();
 
     void    SetEGLInterface( IVGtoEGLInterface* egl );
     void*   CreateContext( void* shareContext );
--- a/inc/BufferContainer.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/inc/BufferContainer.h	Tue Nov 02 09:46:02 2010 +0000
@@ -41,4 +41,4 @@
     void*   m_maskBuffer;
 };
 
-#endif //_BUFFERCONTAINER_H_
\ No newline at end of file
+#endif //_BUFFERCONTAINER_H_
--- a/inc/GLES2Interface.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/inc/GLES2Interface.h	Tue Nov 02 09:46:02 2010 +0000
@@ -55,4 +55,4 @@
 typedef IEGLtoGLES2Interface* (*fpGetGLES2Interface)(void);
 IEGLtoGLES2Interface* LoadGLES2Interface( void*& libraryHandle );
 
-#endif // _GLES2INTERFACE_H_
\ No newline at end of file
+#endif // _GLES2INTERFACE_H_
--- a/inc/ImageTarget.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/inc/ImageTarget.h	Tue Nov 02 09:46:02 2010 +0000
@@ -42,4 +42,4 @@
 	IMAGE_TARGET_RENDERBUFFER
 };
 
-#endif // _IMAGETARGET_H_
\ No newline at end of file
+#endif // _IMAGETARGET_H_
--- a/vghwinterface/vghwapiwrapper/CMakeLists.txt	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/CMakeLists.txt	Tue Nov 02 09:46:02 2010 +0000
@@ -38,7 +38,7 @@
     ${WRAPPER_INC_DIR}/openvgapiwrapper.h
     ${WRAPPER_INC_DIR}/driverapiwrapper.h
     ${WRAPPER_INC_DIR}/opengles11apiwrapper.h
-    ${WRAPPER_INC_DIR}/syborg-graphicswrapper.h
+    ${WRAPPER_INC_DIR}/simulator_graphicswrapper.h
     ${WRAPPER_INC_DIR}/hostthreadadapter.h
     ${WRAPPER_INC_DIR}/platformthreading.h
     ${WRAPPER_INC_DIR}/platformtypes.h
@@ -56,7 +56,7 @@
     ${WRAPPER_SRC_DIR}/openvgapiwrapper.cpp
     ${WRAPPER_SRC_DIR}/driverapiwrapper.cpp
     ${WRAPPER_SRC_DIR}/opengles11apiwrapper.cpp    
-    ${WRAPPER_SRC_DIR}/syborg-graphicswrapper.cpp
+    ${WRAPPER_SRC_DIR}/simulator_graphicswrapper.cpp
     ${WRAPPER_SRC_DIR}/platformthreading.cpp
 
     ${SERIALIZER_SRC_DIR}/eglrfc.cpp
@@ -77,10 +77,8 @@
 
 link_directories(${GLOBAL_LIB_DIR})
 
-add_definitions(-DKHRONOSAPIWRAPPER_EXPORTS -DSYBORG_GRAPHICSWRAPPER_EXPORTS)
+add_definitions(-DKHRONOSAPIWRAPPER_EXPORTS -DSIMULATOR_GRAPHICSWRAPPER_EXPORTS)
 
 add_library(KhronosAPIWrapper SHARED ${WRAPPER_SRC_FILES})
-add_library(syborg-graphicswrapper SHARED ${WRAPPER_SRC_FILES})
 
 target_link_libraries(KhronosAPIWrapper ${WRAPPER_PLATFORM_LINK_LIBRARIES})
-target_link_libraries(syborg-graphicswrapper ${WRAPPER_PLATFORM_LINK_LIBRARIES})
--- a/vghwinterface/vghwapiwrapper/group/bld.inf	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/group/bld.inf	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,50 @@
+/* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and /or associated documentation files
+ * (the "Materials "), to deal in the Materials without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Materials,
+ * and to permit persons to whom the Materials are furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Materials.
+ *
+ * THE MATERIALS ARE 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 OR COPYRIGHT HOLDERS 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 MATERIALS OR
+ * THE USE OR OTHER DEALINGS IN THE MATERIALS.
+ *
+ * Initial Contributors:
+ * Nokia Corporation - initial contribution.
+ *
+ * Contributors:
+ *
+ * Description:
+ * Build information for host wrapper
+ */
+
+PRJ_PLATFORMS
+TOOLS2
+
+PRJ_EXTENSIONS
+
+// Dynamic library.
+start extension graphics_simulator/hostbuild
+option TARGET_NAME      KhronosAPIWrapper
+option TARGET_TYPE      dll
+option SOURCE_DIRS      ../src
+option SOURCE_FOLDER    ../../vghwserialiser/src
+option SOURCE           eglrfc.cpp remotefunctioncall.cpp serializedfunctioncall.cpp driverrfc.cpp opengles11rfc.cpp openvgrfc.cpp
+option INCLUDES         ../inc ../../inc ../../../inc ../../vghwserialiser/inc
+option SYS_INCLUDES     OS_LAYER_PUBLIC_EXPORT_PATH(tools)
+option MACROS           KHRONOSAPIWRAPPER_EXPORTS SIMULATOR_GRAPHICSWRAPPER_EXPORTS
+option COMPILE_OPTIONS  -msse2 -mfpmath=sse -march=pentium4
+option NO_STD_INCLUDE   ON
+option SHARED_LIBS      libEGL libGLESv1 libOpenVG
+//option SHARED_LIBS libGLESv2   (when ready)
+end
--- a/vghwinterface/vghwapiwrapper/inc/KhronosAPIWrapper.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/inc/KhronosAPIWrapper.h	Tue Nov 02 09:46:02 2010 +0000
@@ -54,7 +54,7 @@
 
         KhronosAPIWrapper( MGraphicsVHWCallback* aServiceIf, void* surfacebuffer,
             void* inputdata, void* outputdata );
-        ~KhronosAPIWrapper();
+        virtual ~KhronosAPIWrapper();
 
         void WorkerThread();
 
--- a/vghwinterface/vghwapiwrapper/inc/platformtypes.h	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/inc/platformtypes.h	Tue Nov 02 09:46:02 2010 +0000
@@ -26,7 +26,7 @@
 #endif
 
 
-#ifdef WIN32
+#if defined(WIN32) && !defined(__GNUG__)
 
 #if !defined(__STDC_CONSTANT_MACROS) && !defined(HAVE_STDINT_H)
 #define __STDC_CONSTANT_MACROS
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vghwinterface/vghwapiwrapper/inc/simulator_graphicswrapper.h	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,47 @@
+#ifndef _SIMULATOR_GRAPHICSWRAPPER_H
+#define _SIMULATOR_GRAPHICSWRAPPER_H
+
+#pragma once
+					  
+#ifdef WIN32
+#ifdef SIMULATOR_GRAPHICSWRAPPER_EXPORTS
+#define SIMULATOR_GRAPHICSWRAPPER_API __declspec(dllexport)
+#else
+#define SIMULATOR_GRAPHICSWRAPPER_API __declspec(dllimport)
+#endif
+#else
+#define SIMULATOR_GRAPHICSWRAPPER_API
+#endif
+
+Psu::PLATFORM_SEMAPHORE_T m_outputBufferSemaphore;
+int (*m_pythonCallBack)(int); 
+KhronosAPIWrapper* m_wrapper;
+														   
+
+// Derived from GraphicsVirtualHW.lisa
+static const int VVHW_BUFFER (0x3000000);
+static const int VVHW_INPUT_BUFFER (0x1000000);
+static const int VVHW_INPUT_BASE(0x0);
+static const int VVHW_OUTPUT_BUFFER (0x1000000);
+static const int VVHW_OUTPUT_BASE(0x1000000);
+static const int VVHW_FRAME_BUFFER (0x1000000);
+static const int VVHW_FRAME_BASE(0x2000000);
+
+class SimulatorGraphicsWrapper : public MGraphicsVHWCallback
+    {
+    public:
+
+        SimulatorGraphicsWrapper();
+        ~SimulatorGraphicsWrapper();
+
+        int Reset( uint32_t *aGraphicsMemBase,  uint32_t *aCommandMemBase );
+
+        virtual void LockOutputBuffer();
+	    virtual void ReleaseOutputBuffer();
+	    virtual void ProcessingDone(int i);
+
+    private:
+    };
+
+
+#endif // _SIMULATOR_GRAPHICSWRAPPER_H
--- a/vghwinterface/vghwapiwrapper/inc/syborg-graphicswrapper.h	Fri Oct 22 16:32:41 2010 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,47 +0,0 @@
-#ifndef _SYBORG_GRAPHICSWRAPPER_H
-#define _SYBORG_GRAPHICSWRAPPER_H
-
-#pragma once
-					  
-#ifdef WIN32
-#ifdef SYBORG_GRAPHICSWRAPPER_EXPORTS
-#define SYBORG_GRAPHICSWRAPPER_API __declspec(dllexport)
-#else
-#define SYBORG_GRAPHICSWRAPPER_API __declspec(dllimport)
-#endif
-#else
-#define SYBORG_GRAPHICSWRAPPER_API
-#endif
-
-Psu::PLATFORM_SEMAPHORE_T m_outputBufferSemaphore;
-int (*m_pythonCallBack)(int); 
-KhronosAPIWrapper* m_wrapper;
-														   
-
-// Derived from GraphicsVirtualHW.lisa
-static const int VVHW_BUFFER (0x3000000);
-static const int VVHW_INPUT_BUFFER (0x1000000);
-static const int VVHW_INPUT_BASE(0x0);
-static const int VVHW_OUTPUT_BUFFER (0x1000000);
-static const int VVHW_OUTPUT_BASE(0x1000000);
-static const int VVHW_FRAME_BUFFER (0x1000000);
-static const int VVHW_FRAME_BASE(0x2000000);
-
-class SyborgGraphicsWrapper : public MGraphicsVHWCallback
-    {
-    public:
-
-        SyborgGraphicsWrapper();
-        ~SyborgGraphicsWrapper();
-
-        int Reset( uint32_t *aGraphicsMemBase,  uint32_t *aCommandMemBase );
-
-        virtual void LockOutputBuffer();
-	    virtual void ReleaseOutputBuffer();
-	    virtual void ProcessingDone(int i);
-
-    private:
-    };
-
-
-#endif // _SYBORG_GRAPHICSWRAPPER_H
\ No newline at end of file
--- a/vghwinterface/vghwapiwrapper/src/driverapiwrapper.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/src/driverapiwrapper.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -245,13 +245,6 @@
 
 	::eglMakeCurrent( m_Dpy, m_DudSurface, m_DudSurface, m_PoolContext );
 
-	//eglCreatePbufferSurface
-	EGLint pbuffer_surface_attribs[] =
-	{
-      EGL_WIDTH,    w,
-	  EGL_HEIGHT,   h,
-      EGL_NONE
-	};
 	VGImageFormat format = getVGColorFormat( pixelformat );
 	img = ::vgCreateImage(format, w, h, VG_IMAGE_QUALITY_NONANTIALIASED);//todo: quality; how to decide (TSgImageInfo only provides w,h, pixelformat)?
 		if( img != VG_INVALID_HANDLE )
--- a/vghwinterface/vghwapiwrapper/src/eglapiwrapper.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/src/eglapiwrapper.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -61,7 +61,9 @@
 {
     TRACE("EGLAPIWrapper::WriteReply()\n");
 #ifdef LOG_ERROR
+#ifdef PRINT_TRACES
 	int operationid = (int)m_currentFunctionCall.Data().Header().iOpCode;
+#endif
 	int eglerror = ::eglSimulatorGetError();
 	if ( m_lastEglError != eglerror )
 	{
@@ -573,7 +575,6 @@
     EGLDisplay dpy;
     EGLConfig config;
     EGLContext share_context;
-	EGLBoolean sgSupporting(EGL_FALSE);
 
     m_currentFunctionCall.GetEGLDisplay( dpy, 0 );
     m_currentFunctionCall.GetEGLConfig( config, 1 );
@@ -926,7 +927,6 @@
 
 	//For storing all the configs
 	EGLConfig*  allConfigs = 0;
-	EGLint      allConfigsSize = 0;//size of the array
 	EGLint      allConfigsCnt = 0;//Number of actually received configurations
 
 	//Allocate temporary storage for the attributes for each config
--- a/vghwinterface/vghwapiwrapper/src/opengles11apiwrapper.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/src/opengles11apiwrapper.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -526,7 +526,9 @@
 int OGLES11Wrapper::WriteReply()
 {
 #ifdef LOG_ERROR
+#ifdef PRINT_TRACES
     int operationid = (int)m_currentFunctionCall.Data().Header().iOpCode;
+#endif
     
     int glerror = ::glGetError();
     if ( m_lastGlError != glerror )
--- a/vghwinterface/vghwapiwrapper/src/openvgapiwrapper.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ b/vghwinterface/vghwapiwrapper/src/openvgapiwrapper.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -2170,4 +2170,4 @@
             break;
     }
     return ret;
-}
\ No newline at end of file
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vghwinterface/vghwapiwrapper/src/simulator_graphicswrapper.cpp	Tue Nov 02 09:46:02 2010 +0000
@@ -0,0 +1,150 @@
+// This is the main DLL file.
+
+#include "platformtypes.h"
+#include <KhronosAPIWrapper.h>
+#include <guestvideodriverinterfaceconstants.h>  //Registers and enums 
+#include <platformthreading.h>  //mutex
+#include <graphicsvhwcallback.h>
+#include "simulator_graphicswrapper.h"
+
+SimulatorGraphicsWrapper::SimulatorGraphicsWrapper()
+    {															
+    }
+
+SimulatorGraphicsWrapper::~SimulatorGraphicsWrapper()
+    {
+    delete m_wrapper;
+    m_wrapper = 0;
+
+    Psu::platform_release_semaphore(m_outputBufferSemaphore);
+    }
+
+int SimulatorGraphicsWrapper::Reset( uint32_t *aGraphicsMemBase,  uint32_t *aCommandMemBase )
+    {
+    int ret = -1;
+    if ( m_wrapper )
+        {
+        delete m_wrapper;
+	    }
+    m_wrapper = NULL;
+
+    uint8_t *cmd_buffer = (uint8_t *)aCommandMemBase;
+    uint8_t *frame_buffer = (uint8_t *)aGraphicsMemBase;
+    if( (cmd_buffer != NULL) && (frame_buffer != NULL) )
+        {
+        m_wrapper = new KhronosAPIWrapper( (MGraphicsVHWCallback*)this,
+            frame_buffer, &cmd_buffer[VVHW_INPUT_BASE], &cmd_buffer[VVHW_OUTPUT_BASE] );
+        //Reset synchronisation mechanisms
+        Psu::platform_release_semaphore(m_outputBufferSemaphore);
+        Psu::platform_create_semaphore(m_outputBufferSemaphore, 1, 1);
+        ret = 0;
+        }
+    else
+        {
+        ret = -1;
+        }
+    return ret;
+    }
+
+void SimulatorGraphicsWrapper::LockOutputBuffer()
+    {
+    #ifdef KHRONOS_API_W_MULTITHREAD
+    Psu::platform_wait_for_signal(m_outputBufferSemaphore);
+    #endif
+    }
+
+void SimulatorGraphicsWrapper::ReleaseOutputBuffer(){}
+
+void SimulatorGraphicsWrapper::ProcessingDone(int i)
+    {
+    m_pythonCallBack( i );
+    }
+
+extern "C"
+    {
+    SIMULATOR_GRAPHICSWRAPPER_API SimulatorGraphicsWrapper* create_SimulatorGraphicsWrapper()
+        {
+        return new SimulatorGraphicsWrapper();
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API int initialize_SimulatorGraphicsWrapper( SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        Psu::platform_create_semaphore(m_outputBufferSemaphore, 1, 1);
+        // Change to proper error handling
+        return 0;
+        }
+
+    SIMULATOR_GRAPHICSWRAPPER_API int set_GraphicsCallBack( SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, int (*aGraphicsCallBack) (int) )
+        {
+        m_pythonCallBack = aGraphicsCallBack;
+        // Change to proper error handling
+        return 0;
+        }
+
+    SIMULATOR_GRAPHICSWRAPPER_API int reset_SimulatorGraphicsWrapper(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, uint32_t *aGraphicsMemBase,  uint32_t *aCommandMemBase )
+        {
+        return aSimulatorGraphicsWrapper->Reset( aGraphicsMemBase, aCommandMemBase );
+        }
+
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_InputBufferTail(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        return m_wrapper->InputBufferTail();
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_InputBufferHead(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        return m_wrapper->InputBufferHead( );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_InputBufferReadCount(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        return m_wrapper->InputBufferReadCount( );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_InputBufferWriteCount(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        return m_wrapper->InputBufferWriteCount( );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_InputMaxTailIndex(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        return m_wrapper->InputMaxTailIndex( );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_cmd_memsize( void )
+        {
+        return (VVI_PARAMETERS_INPUT_MEMORY_SIZE +
+                VVI_PARAMETERS_OUTPUT_MEMORY_SIZE);
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API uint32_t get_framebuffer_memsize( void )
+        {
+        return VVI_SURFACEBUFFER_BASE_ADDRESS;
+        }
+
+    
+    SIMULATOR_GRAPHICSWRAPPER_API unsigned int execute_command(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        return m_wrapper->Execute( );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API void set_InputBufferTail(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, uint32_t aVal )
+        {
+        m_wrapper->SetInputBufferTail( aVal );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API void set_InputBufferHead(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, uint32_t aVal )
+        {
+        m_wrapper->SetInputBufferHead( aVal );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API void set_InputBufferReadCount(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, uint32_t aVal )
+        {
+        m_wrapper->SetInputBufferReadCount( aVal );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API void set_InputBufferWriteCount(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, uint32_t aVal )
+        {
+        m_wrapper->SetInputBufferWriteCount( aVal );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API void set_InputMaxTailIndex(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper, uint32_t aVal )
+        {
+        m_wrapper->SetInputMaxTailIndex( aVal );
+        }
+    SIMULATOR_GRAPHICSWRAPPER_API void signal_outputbuffer_semafore(  SimulatorGraphicsWrapper* aSimulatorGraphicsWrapper )
+        {
+        #ifdef KHRONOS_API_W_MULTITHREAD
+            Psu::platform_signal_semaphore(m_outputBufferSemaphore);
+        #endif
+        }
+
+    }
--- a/vghwinterface/vghwapiwrapper/src/syborg-graphicswrapper.cpp	Fri Oct 22 16:32:41 2010 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,150 +0,0 @@
-// This is the main DLL file.
-
-#include "platformtypes.h"
-#include <KhronosAPIWrapper.h>
-#include <guestvideodriverinterfaceconstants.h>  //Registers and enums 
-#include <platformthreading.h>  //mutex
-#include <graphicsvhwcallback.h>
-#include "syborg-graphicswrapper.h"
-
-SyborgGraphicsWrapper::SyborgGraphicsWrapper()
-    {															
-    }
-
-SyborgGraphicsWrapper::~SyborgGraphicsWrapper()
-    {
-    delete m_wrapper;
-    m_wrapper = 0;
-
-    Psu::platform_release_semaphore(m_outputBufferSemaphore);
-    }
-
-int SyborgGraphicsWrapper::Reset( uint32_t *aGraphicsMemBase,  uint32_t *aCommandMemBase )
-    {
-    int ret = -1;
-    if ( m_wrapper )
-        {
-        delete m_wrapper;
-	    }
-    m_wrapper = NULL;
-
-    uint8_t *cmd_buffer = (uint8_t *)aCommandMemBase;
-    uint8_t *frame_buffer = (uint8_t *)aGraphicsMemBase;
-    if( (cmd_buffer != NULL) && (frame_buffer != NULL) )
-        {
-        m_wrapper = new KhronosAPIWrapper( (MGraphicsVHWCallback*)this,
-            frame_buffer, &cmd_buffer[VVHW_INPUT_BASE], &cmd_buffer[VVHW_OUTPUT_BASE] );
-        //Reset synchronisation mechanisms
-        Psu::platform_release_semaphore(m_outputBufferSemaphore);
-        Psu::platform_create_semaphore(m_outputBufferSemaphore, 1, 1);
-        ret = 0;
-        }
-    else
-        {
-        ret = -1;
-        }
-    return ret;
-    }
-
-void SyborgGraphicsWrapper::LockOutputBuffer()
-    {
-    #ifdef KHRONOS_API_W_MULTITHREAD
-    Psu::platform_wait_for_signal(m_outputBufferSemaphore);
-    #endif
-    }
-
-void SyborgGraphicsWrapper::ReleaseOutputBuffer(){}
-
-void SyborgGraphicsWrapper::ProcessingDone(int i)
-    {
-    m_pythonCallBack( i );
-    }
-
-extern "C"
-    {
-    SYBORG_GRAPHICSWRAPPER_API SyborgGraphicsWrapper* create_SyborgGraphicsWrapper()
-        {
-        return new SyborgGraphicsWrapper();
-        }
-    SYBORG_GRAPHICSWRAPPER_API int initialize_SyborgGraphicsWrapper( SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        Psu::platform_create_semaphore(m_outputBufferSemaphore, 1, 1);
-        // Change to proper error handling
-        return 0;
-        }
-
-    SYBORG_GRAPHICSWRAPPER_API int set_GraphicsCallBack( SyborgGraphicsWrapper* aSyborgGraphicsWrapper, int (*aGraphicsCallBack) (int) )
-        {
-        m_pythonCallBack = aGraphicsCallBack;
-        // Change to proper error handling
-        return 0;
-        }
-
-    SYBORG_GRAPHICSWRAPPER_API int reset_SyborgGraphicsWrapper(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper, uint32_t *aGraphicsMemBase,  uint32_t *aCommandMemBase )
-        {
-        return aSyborgGraphicsWrapper->Reset( aGraphicsMemBase, aCommandMemBase );
-        }
-
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_InputBufferTail(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        return m_wrapper->InputBufferTail();
-        }
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_InputBufferHead(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        return m_wrapper->InputBufferHead( );
-        }
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_InputBufferReadCount(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        return m_wrapper->InputBufferReadCount( );
-        }
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_InputBufferWriteCount(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        return m_wrapper->InputBufferWriteCount( );
-        }
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_InputMaxTailIndex(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        return m_wrapper->InputMaxTailIndex( );
-        }
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_cmd_memsize( void )
-        {
-        return (VVI_PARAMETERS_INPUT_MEMORY_SIZE +
-                VVI_PARAMETERS_OUTPUT_MEMORY_SIZE);
-        }
-    SYBORG_GRAPHICSWRAPPER_API uint32_t get_framebuffer_memsize( void )
-        {
-        return VVI_SURFACEBUFFER_BASE_ADDRESS;
-        }
-
-    
-    SYBORG_GRAPHICSWRAPPER_API unsigned int execute_command(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        return m_wrapper->Execute( );
-        }
-    SYBORG_GRAPHICSWRAPPER_API void set_InputBufferTail(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper, uint32_t aVal )
-        {
-        m_wrapper->SetInputBufferTail( aVal );
-        }
-    SYBORG_GRAPHICSWRAPPER_API void set_InputBufferHead(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper, uint32_t aVal )
-        {
-        m_wrapper->SetInputBufferHead( aVal );
-        }
-    SYBORG_GRAPHICSWRAPPER_API void set_InputBufferReadCount(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper, uint32_t aVal )
-        {
-        m_wrapper->SetInputBufferReadCount( aVal );
-        }
-    SYBORG_GRAPHICSWRAPPER_API void set_InputBufferWriteCount(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper, uint32_t aVal )
-        {
-        m_wrapper->SetInputBufferWriteCount( aVal );
-        }
-    SYBORG_GRAPHICSWRAPPER_API void set_InputMaxTailIndex(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper, uint32_t aVal )
-        {
-        m_wrapper->SetInputMaxTailIndex( aVal );
-        }
-    SYBORG_GRAPHICSWRAPPER_API void signal_outputbuffer_semafore(  SyborgGraphicsWrapper* aSyborgGraphicsWrapper )
-        {
-        #ifdef KHRONOS_API_W_MULTITHREAD
-            Psu::platform_signal_semaphore(m_outputBufferSemaphore);
-        #endif
-        }
-
-    }