memononen / nanovg

Antialiased 2D vector drawing library on top of OpenGL for UI and visualizations.
zlib License
5.15k stars 771 forks source link

pixel cropping function #592

Open coollofty opened 3 years ago

coollofty commented 3 years ago

Why not add a clipping function for paths or by drawing pixels? For example, if you draw a picture, you can use it as a Mask, and crop any pixels drawn afterwards. I think it can be achieved by using depth buffer, I am looking forward to such a function