|
|
> Hi,
>
> I have a 3D mesh .inc file, including thousands of triangles like this:
>
> }
> smooth_triangle { // #763945
> <1.35632e-019, 1.35632e-019, 1.35632e-019>, <0.0147179, 0.999892,
> 0.000199087>,
> <1.35632e-019, 1.35632e-019, 1.35632e-019>, <0.0147179, 0.999892,
> 0.000199087>,
> <0.000173748, 1.35632e-019, 3.35076e+012>, <1.93994e-005, 0.992192,
> 0.124723>
> }
>
>
> , I know what should I expect by rendering it in POV-ray, but somthing strange
> is observed, maybe just 2 or3 triangles.
> Could anybody please show me how I can render a mesh in povray?
> Do I need to use Mesh in the script in povray?
> How I have to decide about the position of camera and light source??
> Thanks!
> Vincent
>
>
The format for a smooth triangle is vertex1, normal1, vertex2, normal2,
vertex3, normal3.
If the inc file start with mesh{ and have a } at it's end, there should
be no problem.
Let see, this triangle have 2 identical points making it a degenerate
triangle. Degenerate triangles are not rendered. If I remenmber
correctly, 1e-19 is smaller than the epsilon value, whitch is a
thresshold value to truncate to zero.
Next, you have a point at 3.35e12, whitch is an extremely large value
(3.35 millions of millions). This can cause the mesh to appear as been
infinite even if it's not the case, and most of it's triangle degenerate
and not rendered.
If even one point of a triangle is to far away, it will probably not be
rendered. Christian proposed scaling your mesh down by 10, 100,... In
this particular case, you may need to scale down by 1e-7 to 1e-9 to have
anything... This will make many triangles become sub-pixel in size, even
if rendered at 16000 by 12000 pixels.
Your range of values going from 1e-19 to 1e12 is extreeme with a
variation of 31 orders of magnitude. You just can't render such a scene
without busting the floating point precision limits. Try keeping the
range of values in your scene within 6 orders of magnitude or less.
Next, when a finite object surround the camera, it often register as
infinite, as in unboundable. Try rendering this and look at the statistics:
sphere{0, 30 pigment{bozo} finish{ambient 1}}
//no camera so use the default one siting at the origin pointing toward +Z.
Try rendering with +q0 on the command line. This will make all texture
ambient 1 and turn off any light. It's a good debuging tool and rather
fast. It will make any part shadowed by other to become visible.
Alain
Post a reply to this message
|
|