[fixed] How to clear screen on 16 bit display mode?

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
Paolo
Posts: 12
Joined: Tue Nov 08, 2005 12:34 am

[fixed] How to clear screen on 16 bit display mode?

Post by Paolo »

Hi!
First post here. :)

I'm trying to clear screen using sceGuClear. It works with pixel
format 8888, but with the rest of the display modes it fails.

I'm doing it like this:

Code: Select all

void ClearScreen(u32 uColor) {

    sceKernelDcacheWritebackAll();
    sceGuStart(GU_DIRECT, s_iGuCmdList);
    
    sceGuClearColor(uColor | 0xFF000000);
    sceGuClear(GU_COLOR_BUFFER_BIT);
    
    sceGuFinish(); 
    sceGuSync(0, 0);

}
Should I pass 16bit color data to GU, or something?
What am I missing?

Thanks!


EDIT: Ok, the problem was buggy display mode setting. (Dough!)
User avatar
outtony
Posts: 26
Joined: Thu Oct 13, 2005 2:46 am
Location: Slovakia
Contact:

Post by outtony »

try to call only:

sceGuClearColor(uColor | 0xFF000000);
sceGuClear(GU_COLOR_BUFFER_BIT);
-----------------------------
Tony

www.n3.sk
Post Reply