Game Development Reference
In-Depth Information
• OpenGL ES version: The Windows Simulator option Configuration | GL...
allows you to emulate different versions of OpenGL ES, which makes it easy
to see what your game may look like on different types of hardware. It also
allows you to disable OpenGL ES support entirely, which will then force
Marmalade to use its built-in software renderer.
• Screen resolution: Mobile devices have a wide range of supported screen
resolutions, so Configuration | Surface... allows you to select any size for
the screen that you desire.
• Emulation of device suspend and resume: It is easy to forget that the primary
function of many devices is actually that of a telephone rather than of a gaming
platform, which means your application could potentially be interrupted at
any time by an incoming call. Marmalade takes care of most of the fiddly
details of handling this automatically, but there may still be situations when
you need to do something special under such circumstances. The Windows
Simulator allows you to test whether your application responds correctly by
way of Events | Simulate Suspend and Events | Simulate Resume .
Deploying a Marmalade project
We have now managed to create and run our first Marmalade application, but
running it on Windows isn't our ultimate goal. The whole reason for the Marmalade
SDK is to make it easy for us to develop our application once and then deploy it on
a whole range of mobile device platforms.
Of course we might need to alter some of our assets, for example, because we are
targeting a wide range of different screen resolutions and want our application to
look its best at all times, the code itself should need no modification in order to
run successfully.
To illustrate this, we will now take the "Hello World" project and get it running on
a number of different mobile device platforms.
Compiling the "Hello World" project for the
ARM CPU
Running our project in Windows meant we were compiling our code using the
standard Visual C++ compiler and therefore generating Intel x86 code. However, it
is a fact that the vast majority of mobile devices available today contain some version
or other of the ARM processor, so the first thing we need to do is compile our code
for ARM.
 
Search WWH ::




Custom Search