Polygon to Toxi WETriangleMesh --> shading / lights / subdivision
in
Contributed Library Questions
•
1 year ago
Hello,
i have some questions and im looking for some advise for a smart approach …
what i want to build is something like this.
i the beginning there should be a plane.
this plane should be intersectable by a line (ray?), imagine the plane would be a sheet of paper and the intersectionlines are the bends where you folded the sheet.
one very simple option could be that there is a line in the middle of the plane, dividing it into 2 quads (2 planes/shapes).
those shapes should be able to turn on the bend (like if you would fold a sheet of paper in the middle)
if you have more intersections (lines) you probably would get some polygons that can turn but are all connected on the bending edge
now what im looking for is a very fine color gradient from the light in the shapes, based on their angle and direction to the light.
i was thinking that the toxiclibs WETriangleMesh would do a good job, since i comes with gouraud shading and is able to use different subdivision modes.
so the questions are:
is this in general a good approach?
how to i divide the plane (or maybe terrain) into polygons by intersection lines (rays)?
what is the difference between plane and terrain?
is there a way to get a WETriangleMesh from polygons?
what is the difference between a WETriangleMesh and a TriangleMesh?
if i want to "fold"(put them in different angles to eachother) those different shapes, but want them to be subdivided in tiny peaces, would it make sense to transform those polygons first, make a mesh of the shapes, and subdivide then?
its really a buch of questions, i know, but i would be so thankful if someone would read this and has a idea to this …
i have the feeling that this could be a lot easier if someone knows what the toxi stuff is capable of.
thanks!
1