POV-Ray : Newsgroups : povray.binaries.images : trace() is unreliable on lathe : trace() is unreliable on lathe Server Time
28 May 2022 01:03:57 EDT (-0400)
  trace() is unreliable on lathe  
From: Cousin Ricky
Date: 25 Apr 2022 18:25:52
Message: <62671ff0@news.povray.org>
I want to compute the volume of arbitrary solids of revolution, and to
do this, I need to trace the objects.  But with cubic and Bezier lathes,
trace() is hit or miss.  These images show the results of trying to
trace the tops and bottoms of various shapes.  All the shapes uses the
Sturm option.
 - A '?' on the middle axis means the trace failed from above or
   below.  (There are no such failures in these illustrations.)
 - A '?' near the top or bottom means the trace failed from the side.
 - Two 'X's on the left side or convex apex mean all trace attempts were
   successful.
 - A single 'X' on the left side or convex apex means that a trace from
   above or below went all the way through the shape, and hit the
   other end!
 - An 'X' on a concave end means that the trace missed from the side,
   but hit the middle.

Image sor_extents.jpg traces the exact middle and the top and bottom of
the shape.  Image sor_extents-4.jpg traces from offsets of 1E-4.  Image
sor_extents-3.jpg traces from offsets of 1E-3.

As you can see, only with an accuracy of 0.001 can traces be guaranteed.
 But this is with POV-Ray 3.7; results are different with other versions
of POV-Ray!  I had to take it up to 0.005 to guarantee traces with 3.5.

Along with the images, I have attached the scene definition file and
#debug outputs from the 3.7 renders.


Post a reply to this message


Attachments:
Download 'sor_extents.jpg' (297 KB) Download 'sor_extents-4.jpg' (298 KB) Download 'sor_extents-3.jpg' (298 KB) Download 'sor_extents.zip' (5 KB)

Preview of image 'sor_extents.jpg'
sor_extents.jpg

Preview of image 'sor_extents-4.jpg'
sor_extents-4.jpg

Preview of image 'sor_extents-3.jpg'
sor_extents-3.jpg

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