POV-Ray : Newsgroups : povray.advanced-users : Location changing while scaling : Re: Location changing while scaling Server Time
28 Oct 2024 08:26:10 EDT (-0400)
  Re: Location changing while scaling  
From: yesbird
Date: 2 Sep 2024 07:04:37
Message: <66d59bc5$1@news.povray.org>
On 02/09/2024 13:43, Alain Martel wrote:
> You need to scale your spheres when they are at <0,0,0> then translate 
> them to the desired location.
> 
> Use this instead :
> // Spheres
> #local len = dimension_size(VertexVectors,1) - 1;
> #for (i, 0, len)
>    sphere { 0, 0.04 scale y * 1.2 // No longer move
>             texture { pigment {rgb <0.1, 0.3, 0.1>} }
> 
>      translate VertexVectors[i]
>    }

Many thanks for elegant solution !
--
YB


Post a reply to this message

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