I am having troubles with the lightning. I am pretty new to the whole 3D programming so maybe somebody could shed some light on it?
I have the following Scene (Screenshot from 3ds MAX)
I have a little Exporter for 3d Max that exports selected meshes to the needed format...
On PSP, I am using the following GU Commands:
Code: Select all
vec[0].x = 2.143f;
vec[0].y = -9.339;
vec[0].z = 0.485;
sceGuLightColor(0, GU_DIFFUSE, 0xffc0c0c0);
sceGuLightColor(0, GU_SPECULAR, 0xffffffff);
sceGuSpecular(12.0f);
sceGuAmbient(0xffc0c0c0);
sceGuLight( 0, GU_DIRECTIONAL, GU_DIFFUSE_AND_SPECULAR, &vec[0]);
sceGuEnable(GU_LIGHTING);
sceGuEnable(GU_LIGHT0);
sceGuColor(0xffffff);
sceGumDrawArray(GU_TRIANGLES,
GU_NORMAL_32BITF|GU_VERTEX_32BITF|GU_INDEX_16BIT|GU_TRANSFORM_3D,
BOL_NUMFACES*3, (void *)BOL_idx, (void *)BOL_vtx);
sceGumDrawArray(GU_TRIANGLES,
GU_NORMAL_32BITF|GU_VERTEX_32BITF|GU_INDEX_16BIT|GU_TRANSFORM_3D,
DOME_NUMFACES*3, (void *)DOME_idx, (void *)DOME_vtx);
....
Any help would be greatly appreciated!