[FFmpeg-user] Error in scaling expression

Stefano Sabatini stefasab at gmail.com
Mon Oct 24 16:22:19 CEST 2011


On date Monday 2011-10-24 14:58:12 +0200, me at renecalles.de encoded:
> Hi all,
> 
> as i'm trying to create a filter-chain for resizing using ffmpeg i
> ran into the following issue:
> 
> ffmpeg -i aspect_test.e25.ts -vf
> "scale='320:(ih*ow)/(iw*sar)',pad='320:240:0:30',setdar=4:3" -y -f
> ipod trial.m4v
> 
> ffmpeg version 0.7.6, Copyright (c) 2000-2011 the FFmpeg developers
> built on Oct  4 2011 15:25:01 with gcc 4.2.1 (Apple Inc. build 5666)
> (dot 3)
> configuration: --prefix=/opt/local --enable-gpl --enable-postproc
> --enable-swscale --enable-avfilter --enable-libmp3lame
> --enable-libvorbis --enable-libtheora --enable-libdirac
> --enable-libschroedinger --enable-libopenjpeg --enable-libxvid
> --enable-libx264 --enable-libvpx --enable-libspeex
> --mandir=/opt/local/share/man --enable-shared --enable-pthreads
> --cc=/usr/bin/gcc-4.2 --arch=x86_64 --enable-yasm
> libavutil    50. 43. 0 / 50. 43. 0
> libavcodec   52.122. 0 / 52.122. 0
> libavformat  52.110. 0 / 52.110. 0
> libavdevice  52.  5. 0 / 52.  5. 0
> libavfilter   1. 80. 0 /  1. 80. 0
> libswscale    0. 14. 1 /  0. 14. 1
> libpostproc  51.  2. 0 / 51.  2. 0
> [mpegts @ 0x102051000] max_analyze_duration 5000000 reached at 5000000
> Input #0, mpegts, from 'aspect_test.e25.ts':
> Duration: 00:02:46.96, start: 0.595556, bitrate: 2815 kb/s
> Program 2
> Stream #0.0[0x21]: Video: h264 (Main), yuv420p, 720x576 [PAR 64:45
> DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
> Stream #0.1[0x24](ger): Audio: ac3, 48000 Hz, 5.1, s16, 448 kb/s
> [buffer @ 0x10192e9c0] w:720 h:576 pixfmt:yuv420p tb:1/1000000
> sar:64/45 sws_param:
> [setdar @ 0x10192f560] a:4/3
> [scale @ 0x10192eee0] [Eval @ 0x7fff5fbfe4a0] Undefined constant or
> missing '(' in 'sar)'
> Error when evaluating the expression '(ih*ow)/(iw*sar)'
> 
> 
> Is the sar variable missing or deprecated or something? Or am i'm
> doing something completely wrong?

You need libavfilter >= 2.24.2, check commit
01151a26c03c5df85509150d393e039f574d005f.


More information about the ffmpeg-user mailing list