This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Image Stabilization

Tags: None
(comma "," separated)
g.marco
Registered Member
Posts
87
Karma
0

Re: Image Stabilization

Sat Nov 19, 2011 5:45 pm
I'm on a integration in kdenlive for the stabilization. i will commit a brach with that in later. First this will simple call the simple commandline. Later all adjustable parameter will be changeable.

Parameter to use can be viewn with

melt -query filter=videostab

melt -query filter=videostab2


callmebruce
Registered Member
Posts
41
Karma
0

Re: Image Stabilization

Sat Nov 19, 2011 11:05 pm
I'm looking forward to the integration, but that might be real tricky! Thanks for the hints. I shot video on a little Kodak Playsport ZI10 in 720P at 30FPS (really 29.97). I'm giving the following a shot:
melt -verbose -profile atsc_720p_2997 100_0032.MP4 -filter videostab -consumer xml:100_0032-vstab.mlt all=1 real_time=-2
melt 100_0032-vstab.mlt
melt 100_0032-vstab.mlt -verbose -consumer avformat:100_0032-vstab.mp4 properties=mp4 real_time=-2 threads=3

I already ran the original clip through transcode, so I'll take a look to compare transcode versus mlt/videostab. But - wow!!!!! This is brutally slow on my tiny Netbook. I'm thinking any app that calls it might need a word of warning - get a cup of coffee, take a nap, head off to the office and check when you get back. I know I'm going at it underpowered, but it takes some time.
callmebruce
Registered Member
Posts
41
Karma
0

Re: Image Stabilization

Sun Nov 20, 2011 2:18 am
Original Clip: http://www.youtube.com/watch?v=mfXTzxMYjXA
Stabilized with transcode (just default settings): http://www.youtube.com/watch?v=vWBQdk0U1xg
Stabilized with melt videostab filter: http://www.youtube.com/watch?v=SZNvEm_32eI
Stabilized with MELT using videostab2 filter: http://youtu.be/a88TuT5d8PA

(edited - I messed something up. The original clip is much larger in size than the transcoded and melt'ed versions. I must have done something wrong. I went from about 22 megs down to 5-6 megs)

In all reality, I checked out a small, lightweight tripod with the legs shock-corded together. For pan and sweeps standing in one location, I'm going to use a tripod (still need to figure out the best way to handle the speed of the pan and sweep though). I'll still try to learn more about video stabilization, as I want to take clips while hiking or biking and those will be pretty unsteady. I didn't want a tripod or a monopod, as I picked up a pocket camcorder specifically so it would fit in my shirt pocket and I could carry it anywhere. However, I need to do something to clean up the motion in my clips.
yellow_drupal
Registered Member
Posts
748
Karma
0

Re: Image Stabilization

Sun Nov 20, 2011 7:56 am
I have one of those Gorilla pods with the bendy legs and a bean bag type thing both are great when travelling light to gain a bit of support on a rock, fence, tree whatever.

Also with the Gorilla pod I bend the legs right round upwards each side of the camera and use them like handle bars spacing my hands further apart from the camera and a little offset front to back it helps stop some of the rotation of the camera. Not ideal but can help.
callmebruce
Registered Member
Posts
41
Karma
0

Re: Image Stabilization

Sun Nov 20, 2011 8:16 pm
Yellow - thanks for the tip!! When I bought the little Kodak ZI10, I also bought a Sony external clip on mic and a small desktop tripod. I looked at the Gorilla pod, but decided on a small plastic Ultra-pod II. It hadn't even occurred to me to mount the camera on the pod to hold the camera steady. Sure - I figured using it on a desktop would be cool for a mini-interview. So, I mounted the little camcorder on the ultra-pod, held two of the legs of the pod, rather than the camera itself - and wandered through the house shooting at 720P, 60FPS. Tried viewing it on my Netbook, no go. My wife is out for the day so I hooked up to the new Mac Book Pro we bought a few days ago. She may not be getting that Mac book Pro back!

Anyway, thanks for the tip. That made a huge difference, and I might be able to use software to filter out the remaining jitter and shake. Not about to reshoot my last project (it was a one hour round-trip, and a four hour clean-up whittled down to 24 short clips further whittled down to 2-3 minutes of video). But will use that method the next time out.

So - pay attention to shooting methods first to cut down on shake. Then use image stabilization on digital video to clean it up.
yellow_drupal
Registered Member
Posts
748
Karma
0

Re: Image Stabilization

Mon Nov 21, 2011 9:43 am
Absolutely, shooting methods and practice, including minimizing panning :-) is most important, there's no magic button to fix after. Even hardware assisted GPU stabilization solutions take time away from editing and are not necessarily a one hit fixes all. :-) But we all have occasions a stabilize tool is inevitable.

My personal preference with regard to panning is not to :-), but to take 3 or 4 shots of various points of interest in the view rather than a pan l/r or r/l and cut between them or dolly a couple of them with a small slider. Panning can feel uncomfortable, difficult to get steady unless using a fluid head tripod and I think it takes far too long in the length of the video to go across the pan and keep it comfortable, compared to a more snappy cut between a few short clips of interest.

All personal choices though, no right and wrong way. :-)






yellow_drupal
Registered Member
Posts
748
Karma
0

Re: Image Stabilization

Mon Nov 21, 2011 11:52 am
marco, not wishing to jump the gun but I see the Stabilize options in kdenlives Project menu in latest svn but when I try applying it to a clip in the Project Tree or for a clip on the Time line nothing appears to happen. I guess this is work in progress?

I do have the stabilize options in MLT on the CLI.
g.marco
Registered Member
Posts
87
Karma
0

Re: Image Stabilization

Mon Nov 21, 2011 8:09 pm
the new code that works is in the stabilize branch of kdenlive.

if someone would help testing ( it should work, but it is yet not possible, to change the default parameters ATM)

if is seems to work for you i could merge this into master


yellow_drupal
Registered Member
Posts
748
Karma
0

Re: Image Stabilization

Mon Nov 21, 2011 9:09 pm
marco, unfortunately I'm not building from source but instead using sunabs svn PPA on Ubuntu, I'll try building the stabilize branch to test, many thanks.
betaversion
Registered Member
Posts
16
Karma
0

Re: Image Stabilization

Tue Nov 22, 2011 10:50 am
Hi Yellow, I'm using svn in Ubuntu 11.10 in Gnome2 environment. I've tested the stabilize but I see no changes.
I've used a clip 1920x1080 50i and the same converted at 1280x720 25p but I don't see any processing starting. (i've transcode already installed).
What's missing?
g.marco
Registered Member
Posts
87
Karma
0

Re: Image Stabilization

Tue Nov 22, 2011 9:20 pm
you dont need transcode for that, the code is in mlt too.

it takes a (maybe very long) time to see the progressbar changing.
after that you have a myvideo.mp4.mlt file from myvideo.mp4.
When you clip "add to project" the resulting .mlt file will be added to project also.

so could you test this with a bit more time ;)

i'll commit some changes to adjust all the parameters for the filters


betaversion
Registered Member
Posts
16
Karma
0

Re: Image Stabilization

Tue Nov 22, 2011 10:06 pm
I don't see any interface. Again, no progress bar is present and CPU activity is normal.
g.marco
Registered Member
Posts
87
Karma
0

Re: Image Stabilization

Tue Nov 22, 2011 10:34 pm
hmm, did you update some minutes ago ?

i pushed some changes into stabilize branch.



betaversion
Registered Member
Posts
16
Karma
0

Re: Image Stabilization

Wed Nov 23, 2011 2:15 pm
I've seen now. This morning were not available. However nothing is changed for Stabilize. Or first I choose to stabilize AND AFTER I MUST transcode in another format?
callmebruce
Registered Member
Posts
41
Karma
0

Re: Image Stabilization

Wed Nov 23, 2011 3:09 pm
Marco, when running from the command line, I saw that I needed to run melt first, it generated an mlt file (that I could watch) then you ran melt again to end up with a stabilized video. On my under-powered netbook it took a significant amount of time, and I named the output clip with a new name. (it took me at least 30-45 minutes to stablize a small clip, but I have a slower netbook)

As integrated into KDenlive, do you still do a multi-step process? Does it make a new clip? Or does the .mlt file go into the timeline for viewing, then you get the stabilized clip on final rendering? I was just wondering how it worked so that when stabilize hits the sunab ppa I'd know what to expect.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], kde-naveen, Sogou [Bot]