30 Nov, 2007
Setting up the environment for using OpenGL ES with Visual Studio 2005 in Pocket Pc Development
Posted by: Anca Alimanescu In: OpenGL ES
In order to start the development of an Open GL ES application for the Pocket PC we will need the following:
1.An OpenGL ES implementation(Vincent Mobile 3D Rendering Library,Hybrid’s “Rasteroid” Implementation etc.) 2.Visual Studio 2005 Standard Edition(at least) as it contains the emulator and template projects for mobile development. 3.Pocket PC 2003 SDK.
In the following I am going to present you the steps needed to create an PocketPC application, on VSTO 2005, using OpenGL ES(Vincent implementation).
Steps on setting up the application:
1.Download the Vincent implementation library for Windows.
2.Unzip it and copy the header files and the library files in the Visual Studio directory Microsoft Visual Studio 8\SmartDevices\SDK\PocketPC2003\Include\ and Microsoft Visual Studio 8\SmartDevices\SDK\PocketPC2003\Lib\armv4, in the Pocket PC SDK. Make sure that in the Include folder you create a subfolder named GLES for example, where you include the header files located in the \include\GLES from the Vincent library. In the library Studio 8\SmartDevices\SDK\PocketPC2003\Lib\armv4 copy the content of the \bin\arm\Release folder.
3.Open Visual Studio 2005 and click File→ Create new project. Choose Visual C++ as programming language and select the Smart Device menu. From the project templates available choose Project Smart Device Win32 template. If you want to use Glut ES in implementing your project, you will specify in the wizard that you want a Win32 Console application. If you want to use just OpenGL ES you will choose a Win32 Windows application.
4.In the header file of the main cpp file make sure to include the OpenGl ES headers:
#include GLES/gl.h
#include GLES/egl.h
If you are using Glut Es make sure to add the
#include GLES/glutes.h
You should now link the project as well to the Glut Es library by cliking Project→ Project Properties→Configuration Properties→Linker→Command line. In the Command line here make sure to add glutes.lib library.
5.In order to test the project on the Pocket PC emulator, first you have to copy the libGLES_CM.dll file from the Vincent library in the Windows directory of the emulator(the same thing must be done for the mobile device). If you are using Glut ES, make sure to copy the glutes.dll file to the Windows directory of the emulator/pocket pc.
6.When launching the application you can run it either on the emulator or directy on the mobile device.
