Sign in to follow this  
Baesky

if i use a texture, dx10 will automatically illuminate it?

Recommended Posts


here are some code came from SDK, i didn't found any lighting calc here, but i can see the object.I remeber that in dx9 if i don't set the light state or enable it with shader, i just saw a black screen.
any one could explain it?Thanks!

float4 PS( PS_INPUT input) : SV_Target

{

return txDiffuse.Sample( samLinear, input.Tex )* vMeshColor;

}

Share this post


Link to post
Share on other sites
When using shaders (which you [i]have[/i] to do in DX10), there is no lighting, except what is done in the shader. If you shader doesn't include lighting code, then your objects won't be darkened/brightened by lights... They will be the colour that is output by that [font="Courier New"]return[/font] statement.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this