POV-Ray : Newsgroups : povray.general : Connecting cylinders with chunks of a torus vs. sphere_sweep point cloud. : Connecting cylinders with chunks of a torus vs. sphere_sweep point cloud. Server Time
29 Jul 2024 10:23:28 EDT (-0400)
  Connecting cylinders with chunks of a torus vs. sphere_sweep point cloud.  
From: [GDS|Entropy]
Date: 14 Oct 2011 09:15:01
Message: <web.4e983203deb2e48677e50e540@news.povray.org>
Hello,

I'm looking for a bit of input.

My initial thought regarding the connection of arbitrarily placed cylinders with
sections of a torus follows, which as you will see presented a number of
annoying problems which seem to be resolved by my second idea.

[Idea 1]
Lets assume that I have trace placed cylinders of a constant radius and variable
length all over some poor object, and have saved in an array the two vectors
describing the cylinder along with the translate vector from trace().

Problem 1)
I'm not sure how I might handle the required Reorient_Trans() in terms of
manipulating the three previously saved vectors.

Problem 2)
Determining the parameters of the torus which would correctly connect two
cylinders. Would need to ensure no torus is inside() my traced object, if
inside(), take some alternate action still resulting in a cylinder-cylinder
connection.

Problem 3)
Determining exactly what kind of torus section would be appropriate in degrees,
and modifying the radius of the torus to not look stupid from over/under hang.

Problem 4)
Ensure no duplicate or overlapping connections/objects

Problem 5)
Placing objects along the path defined by the result from above.

[Idea 2]
This lead me to think my initial idea would be the entirely wrong way to go
about this, and perhaps the right answer would be to generate a halton cloud of
points inside the bounding box of the target object but not inside the target
itself. Then I could place disposable spheres of the appropriate diameter along
that path, trace() snap them to the object, test for any intersections between
them with inside(), eliminate violating points, connect the remaining points
with some kind of path/spline, then sphere_sweep using that path.

On initial evaluation, this seems to solve every problem from the other very
kludgey solution.

Am I on the right track here? Any head-slappers I missed?

I'm not entirely sure how to go about full implementation of [Idea 2], though I
have a good enough idea to at least start the thing.

I appreciate any input, as always.

Thank you,
Ian


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.