Skip to content

Make UvCoordinateType a property of WindowQuad instead of RenderNode

Arjen Hiemstra requested to merge work/ahiemstra/uvcoordinate into master

RenderNode is not something an item has control over, while WindowQuads are created by an item, so it can indicate the type of coordinates on creation. Additionally, coordinate type is something that logically belongs with the coordinate, not in an unrelated place.

The second commit makes use of this to calculate normalized coordinates for SurfaceItem geometry. This avoids a nasty precision loss that happens due to multiplying by 1/size instead of just dividing by size directly.

Edited by Arjen Hiemstra

Merge request reports

Loading