Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > MPEG-2 Encoding

Reply
 
Thread Tools Search this Thread Display Modes
Old 6th January 2011, 08:47   #1  |  Link
Nonoman
Registered User
 
Join Date: Apr 2008
Posts: 1
mencoder resizing using -sws flag

Hy there!

I want to downscale a FullHD stream to pal-dvd size 720x576 using the -sws flag.
(walking on a Ubuntu 10.04 server)

My commandline looks like this:
Code:
mencoder video-delay3,6.mpg -channels 6 -oac copy -ovc lavc -of mpeg -mpegopts format=dvd:tsaf
-vf scale=720:437,expand=720:576,harddup -sws 9 -srate 48000 -af lavcresample=48000
-lavcopts threads=256:vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=9800:vbitrate=9799:
keyint=3:trell:mbd=2:precmp=2:subcmp=2:cmp=2:dia=2:predia=2:cbp:mv0:vqmin=1:lmin=1:
dc=10:aspect=16/9:vstrict=0:vpsize=500:vfdct=0:idct=0 -ofps 25 -o movie.mpg

So, this is using lanczos for resizing. (-sws 9)

How do I adjust the strength of the filter?




man (manual of) mencoder tells me:
scale [= w: h [: ilaced [: chr_drop [: par [: par2 [: presize [: noup [: arnd ]]]]]]]]
  • Scales the image with the software (slow) and performs a color space conversion between YUV and RGB through (see the -sws).

<par> [: <par2>] (also see -sws)
Set some scaling parameters depending on the scaling, which was selected with-sws.
  • -sws 2 (bicubic): B (blurring) and C (Gain)
  • 0.00:0.60 Standard
  • 0.00:0.75 "precise bicubic" VirtualDub
  • 0.00:0.50 Catmull-Rom spline
  • 0.33:0.33 Mitchell-Netravali spline
  • 1.00:0.00 cubic B-spline
  • -sws 7 (gaussian): sharpness (0 (soft) - 100 (sharp))
  • -sws 9 (Lanczos): filter length (1-10)


But how do I have to use this in command-line?



my regards



Last edited by Nonoman; 7th January 2011 at 09:05. Reason: Edited text
Nonoman is offline   Reply With Quote
Old 15th January 2011, 10:44   #2  |  Link
www669
Registered User
 
Join Date: Feb 2010
Posts: 28
can you tell me what's the mencoder websit?
www669 is offline   Reply With Quote
Old 15th January 2011, 10:44   #3  |  Link
www669
Registered User
 
Join Date: Feb 2010
Posts: 28
do you have mencoder's options!
i can't find it
www669 is offline   Reply With Quote
Old 4th July 2011, 21:42   #4  |  Link
rogerdpack
Registered User
 
Join Date: Jun 2011
Posts: 35
Ok I figured it out for mplayer:
http://betterlogic.com/roger/2011/07/mplayer-lanczos/
basically
-sws 9 -vf scale=1280:0:0:0:10# 10 is the filter length...I think so anyway, though it doesn't complain if I set it to 11.

Also does anybody know if it accepts sharpen parameters, like -ssf ls=75.0 -ssf cs=75.0 ?

if it works, it will display "Lanczos" in the output after a few lines.
rogerdpack is offline   Reply With Quote
Reply

Tags
command-line, lanczos, mencoder, resize, ubuntu

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 16:28.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.