Omnimaga
Calculator Community => Casio Calculators => Topic started by: MPoupe on May 02, 2011, 04:28:12 am
-
Hello,
I tried to display something (in addin) by something like this:
unsigned short *VRAM = GetVRAMAddress();
int x,y;
for(y = 0;y< HEIGHT;y++)
for(x = 0;x< WIDTH ;x++)
{
*VRAM = x;VRAM++;
}
VRAMtoDD();
GetKey(&x);
When you run this you got image with 2 color columns (alternating black and blue).
But if you press [Menu], it will change (for a fraction of second) to the expected gradient columns, then menu image will be displayed.
So it seems display is somehow "rounding" color (using only the highest bit of the color part, or masking the pixels' color ) so it displays only base 8 color. The Menu handler sets this to true color mode and the it redraws the screen.
Does somebody know how to enable true color mode programatically?
PS: sorry for my poor English.
-
In the hidden diagnostic mode you can actually toggle the color setting between 3 and 16 bit. There is a sample picture included in those test menus that you can see the differences with. So maybe there is a setting somewhere that needs to be changed for 16-bit color to work?
-
So maybe there is a setting somewhere that needs to be changed for 16-bit color to work?
I think there must be such settings, I would expect some port in the display. The Menu displaying routine does it, because my test pattern was displayed in 16 bit colors for very short while.
-
Does somebody know how to enable true color mode programatically?
Try syscall 0x0921 with argument 1.
-
Ah, that bloody menu handler. It's quite annoying, when you get down to it.
-
Or a bit more explanatory:
syscall 0x0921 : int EnableColor( int );
This function seens to enable the display's color mode. Ususally it is called immediately after program-start with parameter 1.
-
Hello,
I tried to display something (in addin) by something like this:
unsigned short *VRAM = GetVRAMAddress();
int x,y;
for(y = 0;y< HEIGHT;y++)
for(x = 0;x< WIDTH ;x++)
{
*VRAM = x;VRAM++;
}
VRAMtoDD();
GetKey(&x);
When you run this you got image with 2 color columns (alternating black and blue).
But if you press [Menu], it will change (for a fraction of second) to the expected gradient columns, then menu image will be displayed.
So it seems display is somehow "rounding" color (using only the highest bit of the color part, or masking the pixels' color ) so it displays only base 8 color. The Menu handler sets this to true color mode and the it redraws the screen.
Does somebody know how to enable true color mode programatically?
PS: sorry for my poor English.
When you mean activate truecolor programmatically, do you mean by conventions made with normally? If so, you can actually do a lot better than truecolor by using a dithering technique ;) if done in the standard %10101010 form, you can make the screen's color look like it was made with a 10-12-10 palette -- which is 32 bits O.o thing is, 24 bits is the most we can really see, but doing it so that it looked like only 24 bit would be a lot slower and memory consuming.
I assume this is what you are trying to accomplish.
-
I always wondered why all current Prizm programs only used 8 colors... I hope it's even possible at all to use 65536 in programs...
-
Try syscall 0x0921 with argument 1.
Thank you, this solved my problem. I used your SDK 1.04 previously, now I used 1.05 with this syscall and it works nicely.
Simon, thank you for your SDK and documentation !