[Radiance-general] ranimate

Thomas Bleicher [email protected]
Sat, 31 Jan 2004 22:07:58 +0100


On Wed, Jan 28, 2004 at 06:34:59PM -0600, Mark de la Fuente wrote:
> ** Proprietary **
> 
> Rob, thank you.  I actually stumbled upon the script last night 
> as well.  Had I noticed that " ' " is not the same as " ` " 
> I would have gotten it to work much sooner!
> 
> But just for anyone who runs into this in the future...  
> ranimate pipes the output of the ANIMATE variable into rpict just 
> like it would if you were using the OCTREE variable.  Only since 
> our scene is dynamic, a script is needed that will produce an 
> octree but not actually store it in a file.
> 
> In my case I was using a file called genoctree.script, so my 
> ranfile included ANIMATE= genoctree.script
> 
> As I recall, genoctree.script looked something like this:
> 
> frame=$1
> time=`ev "6+($frame/2)"`
> gensky 1 28 $time > sun.rad
> oconv -i scene.oct -f sun.rad
> rm sun.rad

You should use a different name for the sun.rad file for each
frame. If you have more than one process runing, one might delete
the sun.rad of another (though this may be an unlikely coincidence,
it's still possible).

> Where I'm telling the computer I want to create my sky starting 
> from 6:30 AM and every frame from then on will add = � hour.
> 
> Now, if anyone can help me figure out a way to get a time stamp 
> on each frame, that would be great!

Create expressions to rename the file from <basename>frame.pic to
<basename>timestamp.pic and append them to a file you can run as
a script after the rendering.

There might be a built-in solution, but this will work as well:

#! /bin/bash
frame=$1 
time=`ev "6+(${frame}/2)"`
gensky 1 28 ${time} > sun_${frame}.rad
oconv -i scene.oct -f sun_${frame}.rad
rm sun_${frame}.rad
# create rename-cmds
echo "mv /path/to/*_${frame}.pic /path/to/room_at_${time}.pic" >> rename.sh


Thomas