ilia3101 / MLV-App

All in one MLV processing app.
https://mlv.app/
GNU General Public License v3.0
283 stars 29 forks source link

Resize ffmpeg allow filter choice #132

Closed ilia3101 closed 5 years ago

ilia3101 commented 5 years ago

I don't know what the current one is but I'd like to be able to choose sinc cubic linear etc. I find when I upscale a small amount with editing software it reduces the detail a lot, so I'd like to do it with sinc filter out of MLV app.

I didn't check that the default filter in mlv app and haven't compared yet but I think it should be an option as sometimes different upscale methods are useful.

masc4ii commented 5 years ago

Do you have some information how to do that? (example commands) Now our command is this: ... -vf scale=w=1920:h=1080 ... for 1920x1080

ilia3101 commented 5 years ago

I was going to try and do this earlier, but qt code is still something I don't understand. But the way to set scaling method it seems is this:

-sws_flags scaling_filter

where scaling filter names are listed here: https://ffmpeg.org/ffmpeg-scaler.html

masc4ii commented 5 years ago

Thanks, I'll have a look at this. I think what you don't understand is not Qt, it is my puzzle game attaching all snippets of the ffmpeg command together... From Qt side, there is only QString( "..." ), QString( "...%1..." ).arg( variable ) and string.append( "..." ). I think you understand this :) Most of the other code is standard C++. But please ask, if you don't understand something!

masc4ii commented 5 years ago

Please test latest commit. sws_flags=sinc is no the only standard. To make it switchable: what options else from the list do you like to be supported? If you want to see the full ffmpeg command, comment in line 2010 of MainWindow.cpp.

masc4ii commented 5 years ago

Good... and more to test for you. I implemented a combobox in export settings where you can choose between the three types you mentioned above. Hope it works ;-) Edit: bicubic was default. At least I see a difference between bilinear and sinc, so it seems to do something.

ilia3101 commented 5 years ago

thank you!!!

ilia3101 commented 5 years ago

@masc4ii 2880x1080 clips look beautiful upscaled to 3840x1440 with sinc! A big improvement over previous scaling.

I think lanczos should be an option too, I think its good for scaling.

bouncyball-git commented 5 years ago

Yes lanczos is really good.

masc4ii commented 5 years ago

No problem... I'll add it. Edit: done. Edit2: something else?

masc4ii commented 5 years ago

Can we close, or do we need something more?