Sign in to follow this  

tangent space lighting in a DF renderer?

This topic is 4106 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

yes i think it is possible but you'd have to write the binormal,tangent and the normal to rendertargets and it wouldn't give you any advantage.

If you mean usual normalmapping then i guess you directly apply the normalmap when rendering to the rendertarget which contains the normals for every pixel.

Share this post


Link to post
Share on other sites
I believe there is nothing special about using a tangent space coordinate system in a deferred shading renderer. You just use it to convert the normal map from tangent to world space.
... you can even generate the tangent space system on the fly in a pixel shader with the ddx() and ddy() instructions. Christian Schueler showed this in a ShaderX5 article.

Share this post


Link to post
Share on other sites
Yeah nothing special: it usually makes sense to do your lighting calculation in world space (just the easiest) so in the G-buffer rendering pass you simply output all of your values in world space.

i.e. transform your normal from tangent space into world space on the first pass.

Share this post


Link to post
Share on other sites

This topic is 4106 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

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