FinishSurfaces(): Difference between revisions

From The DarkMod Wiki
Jump to navigationJump to search
Tels (talk | contribs)
m remove double headline
Tels (talk | contribs)
m add link
 
Line 1: Line 1:
This is a method inside the closed-source part of the idtech4 engine. It '''doubles two-sided surfaces and calculates the shadow hull'''.
This is a method inside the closed-source part of the idtech4 engine. It '''doubles two-sided surfaces and calculates the shadow hull'''.


twosided surfaces are simply get their data doubled, so they get rendered twice, once from front and once from back.
So surfaces with the [[twosided]] keyword in their shader simply get their data doubled, so they get rendered twice, once from front and once from back.


'''FinishSurfaces()''' doubles the data by doubling the entire surface, copying the data (flipped normals, tangents, reverse indices for each tris). and appending the surface at the end.
'''FinishSurfaces()''' doubles the data by doubling the entire surface, copying the data (flipped normals, tangents, reverse indices for each tris). and appending the surface at the end.

Latest revision as of 08:38, 1 July 2011

This is a method inside the closed-source part of the idtech4 engine. It doubles two-sided surfaces and calculates the shadow hull.

So surfaces with the twosided keyword in their shader simply get their data doubled, so they get rendered twice, once from front and once from back.

FinishSurfaces() doubles the data by doubling the entire surface, copying the data (flipped normals, tangents, reverse indices for each tris). and appending the surface at the end.

See also