(11-18-2023, 06:16 AM)Lupos Wrote: List<CGVMesh> inputMeshes,
SubArray<CGSpot> inputSpots,
SubArray<CGSpot> outputSpots,
[NotNull] CGVMesh[] outputMeshes,
[NotNull] CGPath path,
bool stretchToEnd,
ThreadPoolWorker<CGSpot> threadPoolWorker
its rather difficult to understand the steps needed to get all this data in my own custom setup. I was hoping you could provide me some steps to get this data.
From my understanding I need to rasterize the spline first, then generate volume spots for it from the game objects I plan to use as well convert the meshes from the gameobjects into CGVMeshes.
Where would you suggest I begin?
If you want to follow the path of scenario B, which I don't recommand, the parameters you listed are commented and have their types commented, but as a small summary:
- CGVMesh is the equivalent of Mesh
- CGSpot is the equivalent of Transform + an index of the object to use the transform on.
- CGPath has no equivalent in vanilla Unity, it's the list of points making a spline, result of its rasterization.
- SubArray<> is part of an array. This class exists to be able to reuse arrays easily instead of creating/destroying them every time.
- ThreadPoolWorker<> handles multi-threading.
To see how spots are created, check the InputSpots module.
To see how CGPath is created, check the InputSplinePath module.
To see how a CGVMesh is converted to a normal mesh, check the CreateMesh module, and especially the WriteVMeshToMesh method.
I hope this helped.
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.