|
??????????????
D3DXVECTOR3 dir(1.0f, -0.0f, 0.25f);
D3DXCOLOR c = d3d::WHITE;
D3DLIGHT9 dirLight = d3d::InitDirectionalLight(&dir, &c);
//
// Set and Enable the light.
//
Device->SetLight(0, &dirLight);
Device->LightEnable(0, true);
//
// Set lighting related render states.
//
Device->SetRenderState(D3DRS_NORMALIZENORMALS, true);
Device->SetRenderState(D3DRS_SPECULARENABLE, false);
???????????????????????????
??WHITE?InitDirectionalLight??D3D??
??????????????????? |
|