Why sceGuFrontFace(GU_CW)?

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

Moderators: cheriff, TyRaNiD

Post Reply
lego
Posts: 43
Joined: Fri Oct 17, 2008 1:09 am

Why sceGuFrontFace(GU_CW)?

Post by lego »

Hi, everybody.

Why much code for psp use clockwise instead of counter-clockwise like an OpenGL by default :-)?

Thanks.
jojojoris
Posts: 255
Joined: Sun Mar 30, 2008 4:06 am

Post by jojojoris »

Probably cause the coder wants to.

That's realy the only answer. Iy you want to use GU_CCW you can use GU_CCW.

Code: Select all

int main(){
     SetupCallbacks();
     makeNiceGame();
     sceKernelExitGame();
}
dridri
Posts: 34
Joined: Fri Jul 31, 2009 1:47 am

Post by dridri »

This is the source code :

Code: Select all

void sceGuFrontFace(int order)
{
	if (order)
		sendCommandi(155,0);
	else
		sendCommandi(155,1);
}
Yes its a special way, because if you write GU_CW the GU_CCW mode is used, and if you write GU_CCW the GU_CW mode is used...

I think it's due to the PSPGU's programmer reversed a game to know how the PSPGE is used and next write the PSPGU, maybe this game was in CW mode...
I'm French, and 15 years old, so my English is not good...
User avatar
Jim
Posts: 476
Joined: Sat Jul 02, 2005 10:06 pm
Location: Sydney
Contact:

Post by Jim »

Say you wanted to render an object on a reflective floor.

You would draw object A with CCW, then negate the Y axis in your model view, then draw object A with CW.

Jim
lego
Posts: 43
Joined: Fri Oct 17, 2008 1:09 am

Post by lego »

Thanks for replies.
Post Reply