POV-Ray : Newsgroups : povray.advanced-users : isosurface and trace problem : Re: isosurface and trace problem Server Time
6 May 2024 05:57:09 EDT (-0400)
  Re: isosurface and trace problem  
From: Chris B
Date: 16 Jun 2009 15:07:51
Message: <4a37ed87@news.povray.org>
"Doctor John" <joh### [at] homecom> wrote in message 
news:4a37d69c@news.povray.org...
> I'm having a problem with getting trace to accurately place objects on
> an isosurface.
> ... snip ...
> #declare Terrain_Obj = isosurface {
> function { y-FPigment(x, 0, -z).gray*0.4 }
> ... snip ...
> object {
> Terrain_Obj
> texture { Sand scale 1.4}
> scale <3, 3.1, 1>
> translate <0, -0.65, 0>
> rotate y*45
> }
> ... snip ...
> #declare Pos = trace (Terrain_Obj, Start, -y, Norm );
> #if (vlength(Norm) != 0)
> object {
> Grain
> texture {Sand}
> translate Pos
> }

> Any ideas?

You're placing the object into the scene then scaling, translating and 
rotating it.
You then use the non-scaled, non-translated and non-rotated object in the 
trace command and position spheres on that.

You should move the transformations out from where you add the object to the 
scene and  into the object declaration, then it should be ok (though I 
didn't run your code to check).

Regards,
Chris B.


Post a reply to this message

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