Ok guys, anyone that saw my previous post knows this already, for the rest... I'm putting double-buffering into my modest (read: crappy!) little graphics library, but I'm facing a problem...
I've done the following during initialization:
This is my back-buffer.
Now then, all I do is I draw my frame onto the back-buffer using what we would call standard GAPI drawing functions (i.e., I treat this pointer just like the pointer GAPI returns and I draw to it as such with the proper pitches and all).
Anyway, when the frame is drawn, I do the following:
Now... on the emulator, using the GAPI DLL floating around the web, it works just fine, no problems whatsoever. Therefore, I'm assuming my basic technique is correct.
The problem is that when I execute this on my real Casio E-125, I get a blank screen, nothing at all. I'm totally at a loss to explain this, but I'm betting it's some absolutely stupid little thing I just don't know.
If anyone has the slightest clue, I'd appreciate hearing it because I'm completely stumped (not too tough to do these days).
Thanks all!
I've done the following during initialization:
- Code:
unsigned short int* GX_pScreenBuffer = NULL;
GX_pScreenBuffer = (unsigned short int*)malloc(154000);
This is my back-buffer.
Now then, all I do is I draw my frame onto the back-buffer using what we would call standard GAPI drawing functions (i.e., I treat this pointer just like the pointer GAPI returns and I draw to it as such with the proper pitches and all).
Anyway, when the frame is drawn, I do the following:
- Code:
unsigned short int* pVidMem = (unsigned short int*)GXBeginDraw();
memcpy(pVidMem, GX_pScreenBuffer, 153600);
GXEndDraw();
Now... on the emulator, using the GAPI DLL floating around the web, it works just fine, no problems whatsoever. Therefore, I'm assuming my basic technique is correct.
The problem is that when I execute this on my real Casio E-125, I get a blank screen, nothing at all. I'm totally at a loss to explain this, but I'm betting it's some absolutely stupid little thing I just don't know.
If anyone has the slightest clue, I'd appreciate hearing it because I'm completely stumped (not too tough to do these days).
Thanks all!
- Code: