Small lighting fix.

This commit is contained in:
Christian Costa 2003-09-30 00:29:11 +00:00 committed by Alexandre Julliard
parent bc4f8f980f
commit 0accacecb2
1 changed files with 2 additions and 5 deletions

View File

@ -1320,12 +1320,9 @@ static void draw_primitive_strided(IDirect3DDeviceImpl *This,
}
}
/* Just a hack for now.. Will have to find better algorithm :-/ */
if ((d3dvtVertexType & D3DFVF_POSITION_MASK) != D3DFVF_XYZ) {
if ( ((d3dvtVertexType & D3DFVF_POSITION_MASK) != D3DFVF_XYZ) ||
((d3dvtVertexType & D3DFVF_NORMAL) == 0) )
vertex_lighted = TRUE;
} else {
if ((d3dvtVertexType & D3DFVF_NORMAL) == 0) glNormal3f(0.0, 0.0, 0.0);
}
/* Compute the number of active texture stages and set the various texture parameters */
num_active_stages = draw_primitive_handle_textures(This);