Expand description
Tile utilities.
§Coordinates
Tile space coordinates are defined as left-handed^* (row,column) coordinates with the origin in the upper-left corner of the current viewport. Because the origin in 2D world coordinates is relative to the current viewport, it will change depending on the current viewport dimensions.
^*: “left-handed” in the sense of taking the left hand with palm facing down (away) and taking the thumb to be the first coordinate and index finger to be the second coordinate
The tile space vertex shader stages take as input a tile (row,column) and output the 2D world space coordinate for the upper-left corner of the tile. The tile geometry shader will then produce the remaining vertices from this coordinate.
Functions§
- vertices
- Create tile vertices from a string of characters at a given (row,col) position