Friday, 7 November 2014

Tangents and Shades

Tangent Space (Texture Space)

-Tangent Space, Like World, Object and Camera space is a co-ordinate system. It is a very specific co-ordinate system that works specifically with textures. It is here that you declared where your textures on you model are laid out. It works in an xyz axis system where X = U, Y = V and Z = N(or W). We use this system specifically for lighting and most other shaders such as normal mapping. If we were to declare all our normals in our world space then we would have to translate or rotate every normal on an object when it moves. Instead using this method we can simply move the light into our tangent space.

If you look below you can see a shaded sphere, the U and V axis are forming a plane along the tangent line and our W is being used to calculate the shading on the specific point. This calculation is done on each individual polygon meaning that if we did not have to move hundreds of normals but instead one light, in a major scene which a lot of objects what would be easier? Moving thousands of normals for our scene or a dozen or so lights a few times.
^ Above Image from www.sedris.org



Bi-Tangents

A bi-tangent is a line that serves as a tangent for two different points, it is mainly used in normal mapping and bump mapping in order to calculate lighting to be smoother and more realistic


Bitangent
^ Above Image from http://mathworld.wolfram.com/Bitangent.html


Batches

A back is a large amount of information that we send to the render at once that is set to run to completion. This reduces our system overhead by running a program once for multiple processes instead of running the program once per set of instructions. This also allows for the process to shift with the usage of computer resources for smoother execution.



Deferred Shading

Defered shading is a screen space shading technique. It is called deferred because all of the lighting calculations are done last. For our first pass we collect all the necessary information needed for shading as well as doing our drawing pass for our geometry. After that we calculate our lighting. The lighting is specifically calculated for only the areas that it effects. This method however does not work with transparency and it is common when working with transparency to render the pransparent portions of your scene last.

No comments:

Post a Comment