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

Video resampling (smart resample) like in Sony Vegas

Tags: None
(comma "," separated)
SHEG
Registered Member
Posts
6
Karma
0
Hello, everybody!

I am new to Kdenlive and this forum. Hopefully I do not break any rules asking my first question. I am using Kdenlive 0.9.6 on Ubuntu 14.04.0 (maybe this is already regarded as a foul here). For some days now, I am searching for a thread which covers my problem. I also could hardly find an expressive title for this thread of mine, which might be one reason my search wasn't successful until now.

Basically, I am looking for a free alternative to Sony Vegas/Sony Movie Studio - this is where wonderful Kdenlive comes into play - but with one certain feature! In Vegas one has the option to resample video clips with a frame rate differing from the project's frame rate. I don't know if it's some type of 'motion interpolation' or 'motion blur' but this feature leads to a very smooth video.

The feature and its benefits but also disadvantages is explained in this video on youtube.

What I am actually trying is to make a movie out of video game scenes. I record the clips at 240 fps and render the movie at 30 fps. Due to the resampling feature of Vegas not only every 8th frame but all frames are used and in some way overlaid to 30 frames per second (so each frame consists of originally 8 frames).

And here is my question: Is there a way to achieve this with Kdenlive?

Since I am new to this software, I only tried some basic editing and rendering and could not find a way myself. All other threads I found adressed the creation of slow motion effects by the use of frame interpolation.

I really like Kdenlive since the handling is intuitive and the feature set covers all basic needs. Hopefully there is a way to get the resampling effect.

Thanks for your help!
User avatar
ttguy
Moderator
Posts
1152
Karma
6
OS
The video by SirCrest you link to was very interesting. Thanks for that.
The message I got from that video was that most of the time you want to avoid having your software do the frame blending that the "smart resampling" of sony vegas because it leads to blurriness. I am not sure how exactly Kdenlive resamples video to change the frame rate but it will be using ffmpeg/avconv technology.
But what I can tell you is that Kdenlive has the same concepts of input video frame rates, project setting frame rates and output video frame rates.
So I think what you should try and do it take SirCrest's advice and make your project settings frame rate and your output video frame rates be an even multiple of your source material. You are doing 240fps down to 30 fps so I guess you have got that sorted.

You can view the properties of your input clips from the project tree https://userbase.kde.org/Kdenlive/Manua ... Properties

To set up project settings see https://userbase.kde.org/Kdenlive/Manua ... t_Settings

To setup the output settings see https://userbase.kde.org/Kdenlive/Manua ... enu/Render

I am struggling right now to figure out how you set frame rate in the output settings now that I look at it.
Should be covered in https://userbase.kde.org/Kdenlive/Manua ... Parameters but I can not see it.
vpinon
KDE Developer
Posts
708
Karma
6
OS
you should be able to force output frame rate by editing render profile with "r=30"
MLT won't blend your 8 frames, it will pull 1 frame over 8: in MLT, "consumers" drive the pipeline by picking what they need from the "producers"...
I will look at video later to understand the wanted effect.
User avatar
ttguy
Moderator
Posts
1152
Karma
6
OS
So I can not see how kdenlive decides the frame rate at the render stage. Maybe it uses the project settings - which do specify frame rate.
SHEG
Registered Member
Posts
6
Karma
0
Thank you for your answers!

Actually, I want to have this blurriness. I merely picked SirCrest's video because of his detailed explanations of the feature.

My project settings are set to 30 fps which also is the render frame rate. Unfortunately only every 8th frame from the source clip is taken so that the result appears to be laggy and not fluent as it would be with smart resampling in Sony Vegas. I also have Windows PC and the 30 days free trial of Vegas installed so that I can compare the rendered clips.

If I disable smart resampling in Sony Vegas then I get the same result as when rendering in Kdenlive. But that is not what I want. What I am looking for is a way to produce a video so that it looks like it is rendered in Sony Vegas with smart resampling enabled.
User avatar
ttguy
Moderator
Posts
1152
Karma
6
OS
According to melt doco you could force frame rate with a fps parameter in the render profile - see
http://www.mltframework.org/bin/view/ML ... format#fps unit: frames/second

That page lists a huge number of parameters that melt understands. The parameters represent ffmpeg/avconv functionality. So you need to read ffmpeg doco to see if it supplies this frame blending that you desire.
SHEG
Registered Member
Posts
6
Karma
0
OK, I'll give it a try and investigate. Adding the fps parameter to the render profile didn't change the result. But the MLT parameters list has many more entries...

EDIT:

Any parameter I added to the profile had no influence to the rendered video. Taking this Kdenlive Manual into account my version of Kdenlive uses ffmpeg parameters. Those did work and now I am still searching for a parameter achieving the desired effect. :)

EDIT #2:
After a few tests I must say: Having set the project framerate to 240 fps (same as the input clips) and the rendering framerate to 30 fps by the use of the r-parameter does not help.

EDIT #3:
Unfortunately I couldn't find an appropriate parameter for my problem. But as I want to use Kdenlive I came up with a solution satisfiying my needs: I render the video at 60 fps. This looks much more fluent and at the same time sharper than using smart resample in Sony Vegas.
May be the motion adaptive frame rate conversion will be implemented in future releases. :)

Nevertheless, thank you very much for your help!
hftom
Registered Member
Posts
21
Karma
0
SHEG
Registered Member
Posts
6
Karma
0
Thanks for the link. During my preceding research I already found many threads proposing the use of slomoVideo. I tried to avoid it because one has to pre-render the footage at the desired framerate. In Sony Vegas you can keep the original footage (in my case with 240 fps) and flexibly adjust the playback rate for each clip, i.e. also use slow motion at varying speeds. It would be great if this was possible with Kdenlive.

But you are right, although it would require some effort this would be the best workaround. Maybe I will give it a try.
hftom
Registered Member
Posts
21
Karma
0
SHEG wrote:Thanks for the link. During my preceding research I already found many threads proposing the use of slomoVideo. I tried to avoid it because one has to pre-render the footage at the desired framerate. In Sony Vegas you can keep the original footage (in my case with 240 fps) and flexibly adjust the playback rate for each clip, i.e. also use slow motion at varying speeds. It would be great if this was possible with Kdenlive.

But you are right, although it would require some effort this would be the best workaround. Maybe I will give it a try.


SlowmoVideo doesn't do this (imho hugly) blending thing that Vegas does.
It uses optical flow based interpolation to create additional frames and
in your case, it can do real motion blur based on the optical flow analysis.
SHEG
Registered Member
Posts
6
Karma
0
hftom wrote:[...] SlowmoVideo doesn't do this (imho hugly) blending thing that Vegas does. [...]


I totally agree! The more I try to solve my problem the less I like the resampling feature... ;D

Today I'll take a look at slowmoVideo and report my experiences.

EDIT:

OK, I got slowmoVideo running but unfortunately I cannot keep the priginal playback speed when rendering from 240 to 30 fps and simultaneously use the motion blur feature (slowmoVideo crashes). Do you know which shutter function I have to under these conditions?
hftom
Registered Member
Posts
21
Karma
0
SHEG wrote:
hftom wrote:[...] SlowmoVideo doesn't do this (imho hugly) blending thing that Vegas does. [...]


I totally agree! The more I try to solve my problem the less I like the resampling feature... ;D

Today I'll take a look at slowmoVideo and report my experiences.

EDIT:

OK, I got slowmoVideo running but unfortunately I cannot keep the priginal playback speed when rendering from 240 to 30 fps and simultaneously use the motion blur feature (slowmoVideo crashes). Do you know which shutter function I have to under these conditions?


Try to first downsample to 30fps with ffmpeg or kdenlive then run slowmoVideo on this one to add motion blur.
SHEG
Registered Member
Posts
6
Karma
0
hftom wrote:[...] Try to first downsample to 30fps with ffmpeg or kdenlive then run slowmoVideo on this one to add motion blur.


But then all information through the additional frames will be lost since 7 of 8 frames are dropped in my case. The motion blur calculated by slowmoVideo can't be as high in quality as it could possibly be if the additional frames would also be taken into account.

Further tests also revealed that my footage causes a lot artifacts since the camera movements are very fast (it's from a video game after all). But I am very happy with rendering at 60 fps right now. The video runs smooth and the images are still very sharp. As I already stated this is much better then everything I could have achieved with "smart resampling".

But once again, thanks for your help! :)


Bookmarks



Who is online

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