PDA

View Full Version : Time laps with AviSynth - how to add a bit motionblur?


communist
18th May 2005, 12:14
Last year on an event I placed a SVHS and later a DV camera on high position and let it record 2-3 hours. Then capped it to PC via firewire and tried to speed it up with Premiere - rendering would have taken ages with it. So I checked the AviSynth manual to see if there were functions that I could abuse for this kind of purpose.
I loaded the file in VirtualDub with a simple script that did a good job on speeding up those 2-3 hours of footage in realtime (on a Athlon XP 2000+).
AviSource(...)
AssumeFPS(1500)#a bit more or less, what looks 'best'
ChangeFPS(25)
AviSynth really saved me on that (and many other) occasion.

I was wondering how I could improve the output by adding some sort of motion blur. I'm sure this is easily possible since I'm already throwing away a lot of frames and hence its not the same as not having them from the beginning (like with low-fps footage).
Since my knowledge of AviSynth is really limited to its basic - anyone have an idea how to make the most out of it - without slowing it down too much - since that was the main reason to use AviSynth?

Leak
18th May 2005, 16:30
Originally posted by communist
I was wondering how I could improve the output by adding some sort of motion blur. I'm sure this is easily possible since I'm already throwing away a lot of frames and hence its not the same as not having them from the beginning (like with low-fps footage).

Well, what you basically want to do is blend some consecutive frames from your source together whenever you don't throw a frame out...


AVISource(...)
ConvertToYUY2() # if neccessary

TemporalSoften(5,255,255,255,2)
SelectEvery(60,0)


That'll select each 60th frame for output (basically what you did with AssumeFPS and ConvertFPS), but before it does this it blends it with the previous 5 and next 5 frames.

Disclaimer: since this is totally untested you'll probably have to adjust the radius to your liking... :)

np: Slam ft. Dot Allison - Visions (Two Lone Swordsmen Vocal Mix) (Two Lone Swordsmen - Peppered With Spastic Magic)

Mug Funky
18th May 2005, 16:30
for a blur of 10 frames together (factor of 10 speedup):

temporalsoften(5,255,255,255,2).selectevery(10,5).assumefps(25)

this should give you something interesting to look at, but i haven't tested it at all :)

Leak
18th May 2005, 16:37
Originally posted by Leak at 16:30
TemporalSoften(5,255,255,255,2)
SelectEvery(60,0)

Originally posted by Mug Funky at 16:30
temporalsoften(5,255,255,255,2).selectevery(10,5).assumefps(25)

:D:D:D:D:D

Great minds think alike, eh? ;)

But since he sped up the video 60x in his original post, I guess a radius of 30 for TemporalSoften would be a bit counter-productive speedwise; I guess a radius of 5 should work quite well too...

(Okay, using SelectEvery(60,30) might be better for the first frame...)

np: Force Legato - System (Two Lone Swordsmen Remix) (Two Lone Swordsmen - Peppered With Spastic Magic)

communist
20th May 2005, 12:59
Nice - radius of 2 looks pretty good to me (ie not too much or overdone).
Thanks guys :)