POV-Ray : Newsgroups : povray.binaries.animations : A spline based animation with active stipples Server Time
22 Dec 2024 00:22:38 EST (-0500)
  A spline based animation with active stipples (Message 1 to 4 of 4)  
From: Jeff Reifel
Subject: A spline based animation with active stipples
Date: 2 Jan 2014 11:30:01
Message: <web.52c59311fcc9a40111fab0250@news.povray.org>


Post a reply to this message


Attachments:
Download 'anthony.gif' (221 KB)

Preview of image 'anthony.gif'
anthony.gif


 

From: Christian Froeschlin
Subject: Re: A spline based animation with active stipples
Date: 7 Jan 2014 12:32:22
Message: <52cc3a26$1@news.povray.org>
Really cool although also quite creepy.

Rerender with maggots for full effect ;)


Post a reply to this message

From: Bald Eagle
Subject: Re: A spline based animation with active stipples
Date: 3 Mar 2014 16:04:35
Message: <5314ee63$1@news.povray.org>
Holy cow!  That is REALLY COOL!
Any hints on how you achieved that effect?


Post a reply to this message

From: Jeff Reifel
Subject: Re: A spline based animation with active stipples
Date: 4 Mar 2014 00:50:00
Message: <web.5315688df3bfee6a11fab0250@news.povray.org>
Bald Eagle <cre### [at] netscapenet> wrote:
> Holy cow!  That is REALLY COOL!
> Any hints on how you achieved that effect?

StippleGen available at:
http://www.evilmadscientist.com/2012/stipplegen-weighted-voronoi-stippling-and-tsp-paths-in-processing/
can generate stipple diagrams from images. StippleGen saves its files as
editable SVG files. It can also generate a TSP path from the stippled image, and
save that path as an SVG file which can be edited into POV-ray spline syntax.

Thousands of object{ANT}s are placed at integer indexed locations along the
spline with a #while loop and moved by adding the clock value to the index
causing them to follow each other.
 The following code places,points and moves the objects along the spline.
////////////////////////////////////////////////////////////////////
#declare ArraySize= [THE NUMBER OF POINTS IN YOUR SPLINE];
#declare SP=spline{natural_spline
[YOUR SPLINE]}
#declare Step=1 ;
#declare I=0;
union{
#while(I<ArraySize-1)
#declare C=clock;
#declare Xf = SP(I+.002+C*Step).x; //Where it's headed
#declare Yf = SP(I+.002+C*Step).y; //Where it's headed
#declare Xo = SP(I+C*Step).x;//Where it coming from
#declare Yo = SP(I+C*Step).y;//Where it coming from
#declare Xv  = Xf-Xo;//x component of vector
#declare Yv =  Yf-Yo; //y component of vector
 #if(Yv=0)
 #declare Yv=.001;
  #end
#declare RA=0;
#if  (Yv<0)
#if  (Xv<0)
 #declare RA=-180+atan(Xv/Yv);
  #else
    #declare RA=180+(atan (Xv/Yv));
    #end
     #end
   #declare Point =-(180/pi)*atan(Xv/Yv)-RA; // direction of motion
                                             //keeps object moving head first.

object{ANT
 rotate <0,0,Point>//points object
 translate<Xo,Yo,0>//moves object
    }
#declare I=I+Step ;#end  }


Post a reply to this message

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