POV-Ray : Newsgroups : povray.newusers : Import of measurement data (ASCII format) in animation : Re: Import of measurement data (ASCII format) in animation Server Time
18 Apr 2024 13:36:32 EDT (-0400)
  Re: Import of measurement data (ASCII format) in animation  
From: scott
Date: 26 Feb 2016 06:47:28
Message: <56d03b50$1@news.povray.org>
> I have a question regarding an animation which is supposed to reproduce the
> vibration of a metal plate, that was taken at six different points of the
> plate. The measured values are available in ASCII format.
>
> So far, I know how to define a simple geometry (scene) and start an animation
> with the help of the "clock" command. However, my task is to design a metal
> plate which vibrates according to the vibration values taken at the 6 different
> points of the plate mentioned before. For this reason, I am actually supposed to
> import the vibration data to my POV-Ray code and assign it to 6 points in my
> geometry.

I would read in all the points from the ASCII file to an array first. 
Look up "#read" and "array" in the help, you should be able to figure 
out how to do it.

Then, you can choose which value to use from the array based on the 
"clock" value.

Once you've got that working, you might then want to experiment with 
doing some kind of linear interpolation between frames to get a smoother 
animation.


Post a reply to this message

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