PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

why should i use GapiDraw

Hi guys,

I have been looking for tutorials/material to get me started on writting games on the pocket pc and i came across GapiDraw.

Why should i use GapiDraw to make a game? are there any advandages disadvandages? why not just just pure GAPI?

i apreciate your help?
Look at the GapiDraw overview. If you already know all of these programming techniques + have 3-6 months to spend creating a graphics middleware + have access to all types of PDAs and Smartphones then sure go ahead and use GAPI.
Sbl lays the smackdown!

I havent been programming in a while, gonna jump back into it, but I belive GapiDraw is one of the easiest librarys to use.

Like Sbl said it works on nearly all WinCE platforms with minmal changes, and it is also structured nearly identical to DirectDraw. If you have experience with DirectDraw it will be an easy migration, If not its easy enough to learn in a short period of time.
I know what you are saying but i was wondering if this library has some disadvandages. I have seen some of the library components and it very familiar with what i know and i think it will be easy for me to jump into it.

I will probably start experimenting with gapidraw on my free time.
GapiDraw has been used to create dozens of commercial PocketPC games, and there are dozens more in the works. In my opinion, it is currently the best API available for ppc development.

As for disadvantages, the lack of sound mixer is the only one I can think of. I don't know that that is really a disadvantage, because even those mixers available from 3rd parties have problems on one device or another.

-- GR
My only problem so far is the limited font and text features. For instance colorizing text. The only methods that are available AFAIK are a lot less efficient than if it were done during the text draw. For instance drawing the text to a scrap surface, then blit the scrap to your final surface with any of the various alpha or colorizing effects.
Still, the time you save by having GapiDraw tested on most platforms is *invaluable*, even if you have to create a custom DrawText function yourself (or any other feature for that matter).

As far as I'm concerned since GapiDraw is free, it doesn't "lack" any feature, if you get my meaning ;)

--Eric
Sm!rk

This issue could be easily fixed at the GapiDraw level.
I assume that fonts are basically drawn using blitFast with key set to the background color of the font surface.

All it needs to be changed is to modify CGapiSurface::DrawText to use dwColor also for bitmapped fonts and if it is set then simply use BitBlit fast with GDBLTFAST_COLORFILL | GDBLTFAST_KEYSRC.
warmi wrote:
All it needs to be changed is to modify CGapiSurface::DrawText to use dwColor also for bitmapped fonts and if it is set then simply use BitBlit fast with GDBLTFAST_COLORFILL | GDBLTFAST_KEYSRC.


I figure that is the case, but I can't add that to CGapiSurface. So my options are to rewrite my own text drawing taking into account the need of colorizing text, or using the non-optimum method I described above. I haven't yet decided which route to take since its not essential yet, and also sbl has mentioned that some font features are slated for the new release or one of them, so I'm just waiting to see what happens.

I don't know if any other libraries have that function, but one of the helpers does (ie the full source add-ins, the name escapes me), but at the same time it doesn't offer the cross platform and native intel compiling that you get with GapiDraw, those are the features that allow me to overlook the minor features I want from DrawText.
Sm!rk: Please email me all your suggestions at johan.sanneblad@home.se