|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Hi,
I have a problem with a height_field :
I have made a flag in the wind for an still picture with a height_field and
it looks like ok for me, but now i have to animate the waves of the
height_field image_map ! Is this possible ??
Thanks
Tom33
Post a reply to this message
Attachments:
Download 'height_field.bmp' (226 KB)
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Tom33" <ths### [at] gmxde> wrote:
> Hi,
>
> I have a problem with a height_field :
>
> I have made a flag in the wind for an still picture with a height_field and
> it looks like ok for me, but now i have to animate the waves of the
> height_field image_map ! Is this possible ??
>
> Thanks
> Tom33
Sorry, i will not animate the image_map !! I will animate the height_field
map to simulate wind ;o)
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Tom33" <ths### [at] gmxde> wrote in message
news:web.43af075227adceaf445e54810@news.povray.org...
> "Tom33" <ths### [at] gmxde> wrote:
>> Hi,
>>
>> I have a problem with a height_field :
>>
>> I have made a flag in the wind for an still picture with a height_field
>> and
>> it looks like ok for me, but now i have to animate the waves of the
>> height_field image_map ! Is this possible ??
>>
>> Thanks
>> Tom33
>
> Sorry, i will not animate the image_map !! I will animate the height_field
> map to simulate wind ;o)
>
Hi Tom,
Yes this is possible.
Two methods spring to mind.
1) Cut and paste a second copy of the image to the right of the first and
smooth out the join, then use clipped_by or CSG to take half the height
field, starting with the left half and moving right until you reach the
right hand edge as the clock moves from 0 to 1. Then when you create an
animation loop it should look seamless. Clearly you'll need to scale the
helf of the height field you use to the size of your flag.
2) Use a function for the height field rather than an image and rotate the
pattern so that it returns to the same spot at the end of the animation
cycle.
The following example illustrates the second method. I've used bumps and
scaled them to give a more ripple-like effect, then rotated the bump pattern
around the origin based on the clock value. The height field then uses the
function, taking samples of the pattern at a point about 0.5 units above the
x axis. As the pattern rotates frame by frame it gives the impression that
the ripples are moving through the surface.
p.s. Because the first and last frame are in the same place you'll need to
delete one or other of them to get a smooth animation cycle (or adjust the
rotation so it doesn't make it all the way back to the start position).
Happy New Year,
Chris B.
light_source { < -150, 80 ,-8> color rgb 1}
camera {location <-0.1,1,-1> look_at <0.5,0.5,0>}
#declare MyFuntion = function {
pattern { bumps scale <0.15,0.3,0.15> rotate y*clock*360}
}
#declare MyIntensity = 0.08;
height_field {
function 400, 400 { MyFuntion(x, y+1, 0.5)*MyIntensity + 0.5 }
smooth
pigment {color rgb <1,1,1>}
}
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Hi Chris,
thanks for this two methods, yesterday i found Christoph Hormanns Wave
Include-Files like your second method !
I post it in the german www.povray-forum.de in this thread:
http://www.povray-forum.de/viewtopic.php?t=139
Here my small flag-animations:
http://www.povray-forum.de/Tom33/height_field_ani1.avi
http://www.povray-forum.de/Tom33/height_field_ani2.avi
Now, I will try it with your first method ;o)
Happy New Year,
Tom33
> Hi Tom,
> Yes this is possible.
>
> Two methods spring to mind.
>
> 1) Cut and paste a second copy of the image to the right of the first and
> smooth out the join, then use clipped_by or CSG to take half the height
> field, starting with the left half and moving right until you reach the
> right hand edge as the clock moves from 0 to 1. Then when you create an
> animation loop it should look seamless. Clearly you'll need to scale the
> helf of the height field you use to the size of your flag.
>
> 2) Use a function for the height field rather than an image and rotate the
> pattern so that it returns to the same spot at the end of the animation
> cycle.
>
> The following example illustrates the second method. I've used bumps and
> scaled them to give a more ripple-like effect, then rotated the bump pattern
> around the origin based on the clock value. The height field then uses the
> function, taking samples of the pattern at a point about 0.5 units above the
> x axis. As the pattern rotates frame by frame it gives the impression that
> the ripples are moving through the surface.
>
> p.s. Because the first and last frame are in the same place you'll need to
> delete one or other of them to get a smooth animation cycle (or adjust the
> rotation so it doesn't make it all the way back to the start position).
>
> Happy New Year,
> Chris B.
>
> light_source { < -150, 80 ,-8> color rgb 1}
> camera {location <-0.1,1,-1> look_at <0.5,0.5,0>}
>
> #declare MyFuntion = function {
> pattern { bumps scale <0.15,0.3,0.15> rotate y*clock*360}
> }
> #declare MyIntensity = 0.08;
>
> height_field {
> function 400, 400 { MyFuntion(x, y+1, 0.5)*MyIntensity + 0.5 }
> smooth
> pigment {color rgb <1,1,1>}
> }
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Tom33 nous apporta ses lumieres en ce 2005-12-26 09:29:
> Hi Chris,
>
> thanks for this two methods, yesterday i found Christoph Hormanns Wave
> Include-Files like your second method !
>
> I post it in the german www.povray-forum.de in this thread:
> http://www.povray-forum.de/viewtopic.php?t=139
>
> Here my small flag-animations:
> http://www.povray-forum.de/Tom33/height_field_ani1.avi
> http://www.povray-forum.de/Tom33/height_field_ani2.avi
>
> Now, I will try it with your first method ;o)
>
> Happy New Year,
> Tom33
>
>
>
>>Hi Tom,
>>Yes this is possible.
>>
>>Two methods spring to mind.
>>
>>1) Cut and paste a second copy of the image to the right of the first and
>>smooth out the join, then use clipped_by or CSG to take half the height
>>field, starting with the left half and moving right until you reach the
>>right hand edge as the clock moves from 0 to 1. Then when you create an
>>animation loop it should look seamless. Clearly you'll need to scale the
>>helf of the height field you use to the size of your flag.
>>
>>2) Use a function for the height field rather than an image and rotate the
>>pattern so that it returns to the same spot at the end of the animation
>>cycle.
>>
>>The following example illustrates the second method. I've used bumps and
>>scaled them to give a more ripple-like effect, then rotated the bump pattern
>>around the origin based on the clock value. The height field then uses the
>>function, taking samples of the pattern at a point about 0.5 units above the
>>x axis. As the pattern rotates frame by frame it gives the impression that
>>the ripples are moving through the surface.
>>
>>p.s. Because the first and last frame are in the same place you'll need to
>>delete one or other of them to get a smooth animation cycle (or adjust the
>>rotation so it doesn't make it all the way back to the start position).
>>
>>Happy New Year,
>>Chris B.
>>
>>light_source { < -150, 80 ,-8> color rgb 1}
>>camera {location <-0.1,1,-1> look_at <0.5,0.5,0>}
>>
>>#declare MyFuntion = function {
>> pattern { bumps scale <0.15,0.3,0.15> rotate y*clock*360}
>>}
>>#declare MyIntensity = 0.08;
>>
>>height_field {
>> function 400, 400 { MyFuntion(x, y+1, 0.5)*MyIntensity + 0.5 }
>> smooth
>> pigment {color rgb <1,1,1>}
>>}
>
>
>
>
Using the +kc flag on the command line is usefull for creating cyclical animations, it
ensure that
the first and last frames are not identical. With it, you don't have to delete the
last frame, and
don't have to change your code if you change the number of frames to render.
--
Alain
-------------------------------------------------
I drive way too fast to worry about cholesterol.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|