POV-Ray : Newsgroups : povray.newusers : Scene enquiry : Re: Scene enquiry Server Time 2 Mar 2024 12:41:39 EST (-0500)
 Re: Scene enquiry
 From: m@b Date: 19 Oct 2022 13:27:27 Message: <6350337f@news.povray.org>
```
{
"@context": "https://schema.org",
"@type": "DiscussionForumPosting",
"@id": "#6350337f%40news.povray.org",
"dateCreated": "2022-10-19T17:27:27+00:00",
"datePublished": "2022-10-19T17:27:27+00:00",
"author": {
"@type": "Person",
"name": "m@b"
}
}
On 19/10/2022 5:39 PM, santividal wrote:
> Him I am trying to replicate this water droplets all around the tap, so maybe a
> series of droplets every 12 or 24 degrees around z axis. How should I do. that?
> I know it is a beginner trick, but I am trying different #while sentences and it
> doesn't seem to work out. Could somebody help me? Here is the code I am using to
> achieve the droplets look like a trajectory.
>
> Thanks in advance for any help,
>
>
> // FUENTE SUPERIOR
>
> #declare posX = 0.02;
> #declare posY = 0.82;
> #declare dy = 0.055;
> #declare posZ=0;
> #declare posZ= <0,0,posZ+12>;
>
>
>      #while (posX < 0.3)
>      sphere {
>      <posX,posY,0>, 0.01
>      material { agua }  }
>      #declare dy = dy - 0.01;
>      #declare posX = posX + 0.02;
>      #declare posY = (posY + dy);
>      #end
>
>

#declare Rotation=0;
#declare Rotation_angle=12;

#while (Rotation < 360)
#declare posX = 0.02;
#declare posY = 0.82;
#declare dy = 0.055;
#while (posX < 0.3)
sphere {
<posX,posY,0>, 0.01
// material { agua }
rotate<0,Rotation,0>
}
#declare dy = dy - 0.01;
#declare posX = posX + 0.02;
#declare posY = (posY + dy);
#end
#declare Rotation = (Rotation + Rotation_angle);
#end
```