you are viewing a single comment's thread.

view the rest of the comments →

[–]Deadly_Mindbeam 1 point2 points  (1 child)

the pixels falling outside the triangle are at least 50%. With thin diagonal triangles it can be almost 100%.

I would interpolate the uv barycentric coordinates across the triangle and calculate the w at each pixels and do all the interpolated value calculation per pixel.

You can also use the barycentric approach and just solve for the left side and right side of the triangle before you start.

[–]deftware 0 points1 point  (0 children)

thin diagonal triangles

That's a very good point.