bitangentView
Provides the bitangent vector correctly transformed into View Space, essential for advanced view-dependent lighting calculations.
Core Advantages
Its core advantage is completely encapsulating the extremely complex and error-prone process of transforming the local bitangent to view space using the normal matrix, ensuring mathematical consistency with nodes like `normalView`.
Common Uses
Building the TBN matrix in view space to apply normal maps.
Enabling advanced, view-dependent rim lighting effects when combined with normal maps.
Providing accurate surface detail information for screen-space effects like SSAO.
Debugging view-dependent vector transformations by visualizing it as a color.
How to adjust
The node's value is determined by the model's UVs, object transform, and camera view; it cannot be adjusted directly. Its view-dependent nature is best observed by comparing its visualization to `bitangentLocal`: when rotating the object, the color from `bitangentLocal` 'sticks' to the model, while the color from `bitangentView` changes.
Code Examples
1// Build the TBN matrix in view space
2const tbn = tbnView( normalView, tangentView, bitangentView );
3
4// Transform the normal from a normal map from tangent space to view space
5const detailNormal = tbn.mul( normalMapNode );