Description of the problem
I integrated a de Boor algorithm + casteljau (bez segments) Curve toolkit into my system (also I have different R. V. distributions implementation to generate control points smartly), which generates curve points adaptively. Now I want to extrude a shape (a series of points, not what three.js default extras/core/Curve.js defined objects), rectangles for example, along a curve, to draw lanes.
All my geometric level data are generated by parameter server (Topological Level) using Half edge based infrastructure. Hence for some well known reasons, I just use three.js for drawing in browser side, and I cannot use any algorithms provided by three.js, like quickhull, to perform computation.
As far as I know, three.js provides me ExtrudeGeomtry. But it uses three’s Curve. I want to extrude a shape along a curve (a series of points or Vector3 instances) instead of /core/Curve object.
Question
Is it possible to extend a shape from array of points or Vector3 instances?
Features 1
As far as I know, three.js provides me ExtrudeGeomtry. But it uses three’s Curve object. I want to extrude a shape along a curve (a series of points or Vector3 instances) instead of /core/Curve object.
Is it possible to extend a shape from array of points or Vector3 instances? Alternatively, if we can adapt a array of points into a Curve instance. It is good for me.
my current solution is drawing faces from scratch, but I think that it will be better if three makes customer curves easier to use.
Feature 2
Another problem is, I have concepts of curve segments internally. But I use it for navigation and location. What I need is?
(1) In which segment, the target is. Retrieve road info like speed limit, traffic signs, type (express?), etc.
(2) the segment is a whatever linked list, (what ever data structure you use), so that navigation can follow, retrace, and make decisions
Feature 3
If you want to check whether there is a hole in the geometry, simply use Euler-Poincare formula:
V - E + F - ( L - F ) = 2 ( S - G )
Three.js version
- Dev
- r90
- …
Browser
- All of them
- Chrome
- Firefox
- Internet Explorer
OS
- All of them
- Windows
- macOS
- Linux
- Android
- iOS
@yiakwy
Try this: