We've gotten an ASUS P565 (very nice device!), which has 480*640 as natice screen resolution.
I need to do my renderings in 240*320. Of course I can upscale when I copy into the PocketHAL display buffer, but for performance reasons I'd prefer that PocketHAL would switch into a 240*320 mode.
Is that possible? I've not defined a HI_RES_AWARE flag. Yet, PocketHAL does 480*640.
Any help is highly appreciated.
If you don't specify HI_RES_AWARE, PocketHAL shouldn't use 480x640. That seems like a bug.
Are you using 1.0.5?
Yes, I'm using 1.0.5
I think that have noticed this behavior before on other devices, basically on all I tried.
Is there a way to enfore non-high-res mode?
Daniel
I've just compiled the minimal sample that comes with PocketHAL and something very strange is going on:
The sample runs in low res, but it runs very slow. In portrait it runs in 15fps, and in landscape it runs in 10fps only.
My regular app, which does high-res for unknown reason runs at least very fast. I benchmarked ~6ms for frame flipping, which is still a lot since I target 30fps (yet fast considering 640x480).
BTW: 10-15fps is what I get in my app, if I use GDI instead of PocketHAL on this device.
The behaviour you see is normal. If hires mode isn't selected, PocketHAL reverts to GDI on VGA devices. PocketHAL doesn't do the scaling itself. That's why you see 15 fps. You get better performances in hires mode because PocketHAL optimizations are then fully enabled.
If the samples run in lowres mode, then the question is why is your app going to hires mode? What SDK are you using? VS2005? VS2008? EVC4?
Ok, so now I know why it is so slow in low-res and that I don't want use this mode then.
I am using VS2008 with the PocketPC 5.0 SDK. I used the automatic project file conversion to import the samples.
I believe that if you link with a high level SDK (5.0 and above), the OS will automatically assume the app to be "hi res aware". That flag was a hack in WM2003SE and isn't needed anymore.
I remember that for WM6, but it might apply to WM5 too.
PocketHAL will always initialize with the same resolution as the touch screen (otherwise input isn't going to work).
Ok, thanks for making that clear.