leetvr / hotham

Hotham is a tool for creating incredible standalone VR games.
Apache License 2.0
396 stars 28 forks source link

Simplify quadrics in custom rendering example #407

Closed rasmusgo closed 2 years ago

rasmusgo commented 2 years ago

The code gets easier to read and possibly faster to run by doing less in the vertex shader and consolidate the logic in the fragment shader. It was also possible to simplify the fragment shader. The amount of data passed from the vertex shader to the fragment shader is greatly reduced. This makes vertices cheaper which is a bit funny when the point of this rendering technique is to enable perfectly curved geometry with very few vertices.