adamwulf / DrawUI

A variety of methods for making a drawing canvas UIView for iPhone and iPad. Objective-C.
22 stars 3 forks source link

Rendering idea: 3d transforms of fixed width line #4

Open adamwulf opened 4 years ago

adamwulf commented 4 years ago

Is it possible to define a 3d transform of a fixed width rendered line, so that the end points are tapered to different widths. I think the perspective of a 3d transform should allow for one endpoint to be 'further away' from the other, causing the fixed width line to appear to taper along the path. i'm not sure how that perspective would affect the tangent at each endpoint.

adamwulf commented 4 years ago

I believe I can make the transformed path exactly match the pre-transformed path by sending the control points through the inverse-transform. that way the transformed control points will show in the correct positions after the transform. this should keep the tangents correctly aligned for neighboring segments.