问题
I was wondering if it was possible to draw the edges of a rendered polygon with a specific color using a fragment shader, as in this example picture:
Or should I just render those separately?
回答1:
See work related on this page: http://web.archive.org/web/20120527185124/http://cgg-journal.com/2008-2/06/index.html
A vertex shader should render polygons where the distance to each edge is colored.
The difference between coloring each "cell" is explained in much detail.
来源:https://stackoverflow.com/questions/6864748/draw-edges-of-a-polygon-with-opengl-shaders