PocketMatrix forums

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

Gd3.5 andPHal

A couple of quick questions about gd and phal.

What needs to be done to enable integration? From a look at the sampels it seems like you just need to link in the phal library.

Is it possible to access the phal objects (specifically the display object) directly?

Is is possible to set the viewport a la phal

Ta
Hi Sean,

What needs to be done to enable integration? From a look at the sampels it seems like you just need to link in the phal library.


You need to link both to the GapiDraw-ppc-arm-phal library and to the PocketHAL library.

Is it possible to access the phal objects (specifically the display object) directly?


No, but all the options for the display object in PocketHAL are presented as switches to the display object in GapiDraw. The following flags are new to OpenDisplay in 3.5:

GDDISPLAY_VSYNC = 0x1000, // (PocketHAL devices and Stationary PCs) Try to use VSync when calling Flip().

GDDISPLAY_DISCARDBACKBUFFER = 0x2000, // (PocketHAL devices) The contents of the backbuffer might be altered to improve performance of Flip()

GDDISPLAY_NOLINEARBACKBUFFER = 0x4000, // (PocketHAL devices) Don't use a linear back buffer for performance improvements (up to 100% on each Flip)

Is is possible to set the viewport a la phal


Not yet, but we will add an inproved Flip() function to the final 3.5 that does this. If you want a viewport before the flip you can simply use SetClipper().
will there be intergration libs for mips, sh3 and xp?
GD + PocketHAL MIPS, SH3 - Yes, they will be in the final 3.5 release.

PocketHAL XP - no, since there is no way to explicitly use the 565 format in full-screen hardware-accelerated mode on some older graphics cards (they will only use 555 mode). In windowed mode on stationary PCs, the back buffer is already always in 565 mode. And you don't really use a rotated display mode on stationary PCs as well...
I have just moved yeti from phal to gd+phal. Everything works except that I can't rotate in XP...
Um. Do you need to rotate in XP?
Not a real requirement, but it is much easier to test rotation specific layout in xp than on the ppc.

Don't do anything about it for my sake, the only thing I am really missing is the SetViewPort, and you should have that implimented well before my game gets anywhere near the public.
Yep...