POV-Ray : Newsgroups : povray.general : Latest animation -- "Larry's Last Ride" : Re: Latest animation -- "Larry's Last Ride" Server Time
30 Jul 2024 12:25:52 EDT (-0400)
  Re: Latest animation -- "Larry's Last Ride"  
From: Dan Byers
Date: 5 Feb 2009 10:30:02
Message: <web.498b0571a0d736a7a8d0b25a0@news.povray.org>
"Kenneth" <kdw### [at] earthlinknet> wrote:
> Funny! An out-of-the-ordinary use of POV-Ray, which is always nice to see. I
> took a look at your other animations; VERY creative. I'm somewhat new to POV
> animation, trying to figure out 'sequencing' of events, etc. You've tackled
> that and mastered it. Bravo!
>
> Ken W.

Thanks for the compliment :)  Yeah, you wouldn't normally think of using POV to
make 2-D, traditional 'cel' animations, but it's such a versatile program that
it can do it fairly easily.  All I'm doing is creating polygons for each 'cel'
layer, and a #switch( frame_number ) block to assign an appropriate image_map
as a texture for each polygon:

#local aspect_ratio = 4/3; // or 16/9 if shooting for widescreen

// Layer 1
#switch( frame_number )
  #case( 1 )      #local f_name = "alien1.png"; #break
  #range( 2, 5 )  #local f_name = "alien2.png"; #break // looking at camera
  ...
#end

polygon {
  5,
  <1,1,0>,
  <-1,1,0>,
  <-1,-1,0>,
  <1,-1,0>,
  <1,1,0>

  pigment {
    image_map {
      png f_name once interpolate 2
    }
  }
  finish {
    ambient 1 diffuse 0
  }

  translate <-.5,-.5,0>  // center the image

  // you can scale, rotate, or translate the layer as your heart
  // sees fit -- for zooming cameras, moving backgrounds, etc.
  scale <1 * aspect_ratio, 1, 1>
  rotate <...>
  translate <...>

}

// Layer 2 code
.....
// Layer 3 code
.....


global_settings {
  max_trace_level 20 // the more layers, the higher this number should be...
                     // for animatics reels, 5 or 8 is fine
  assumed_gamma 1.0  // VERY IMPORTANT!!!
}


camera {
  orthographic
  location <0,0,-10>
  up y
  right x*aspect_ratio
  angle ...
  rotate <0,0,0>
  look_at 0
}

That's it in a nutshell!  Don't forget to translate each layer slightly along
the z axis :)

--
Dan
GoofyGraffix.com


Post a reply to this message

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