amazon ec2 - FFmpeg: jpeg scaling on amazone linux -


i have need rescale jpg image in command line. , use ffmpeg that:

ffmpeg -loglevel debug -i photo.jpg -vf scale=1920:1080 photo_scaled.jpg 

it works on work mac , gives following output:

splitting commandline. reading option '-loglevel' ... matched option 'loglevel' (set logging level) argument 'debug'.  reading option '-i' ... matched input file argument 'photo.jpg'.  reading option '-vf' ... matched option 'vf' (set video filters) argument 'scale=1920:1080'.  reading option 'photo_scaled.jpg' ... matched output file. finished splitting commandline.  parsing group of options: global .  applying option loglevel (set logging level) argument debug. parsed group of options.  parsing group of options: input file photo.jpg. parsed group of options.  opening input file: photo.jpg.  [png_pipe @ 0x7fd221810600] format png_pipe probed size=2048 , score=99  [png_pipe @ 0x7fd221810600] before avformat_find_stream_info() pos: 0 bytes read:32768 seeks:0  [png_pipe @ 0x7fd221810600] after avformat_find_stream_info() pos: 303755 bytes read:303755 seeks:0 frames:1 input #0, png_pipe, 'photo.jpg':    duration: n/a, bitrate: n/a  stream #0:0, 1, 1/25: video: png, 1 reference frame, rgb24(pc), 905x509 (0x0), 1/25, 25 tbr, 25 tbn, 25 tbc  opened file.  parsing group of options: output file photo_scaled.jpg.  applying option vf (set video filters) argument scale=1920:1080. parsed group of options.  opening output file: photo_scaled.jpg 

but on amazone server gives me following:

splitting commandline. reading option '-loglevel' ... matched option 'loglevel' (set logging level) argument 'debug'. reading option '-i' ... matched input file argument 'photo.jpg'. reading option '-vf' ... matched option 'vf' (set video filters) argument 'scale=1920:1080'. reading option 'photo_scaled.jpg' ... matched output file. finished splitting commandline. parsing group of options: global . applying option loglevel (set logging level) argument debug. parsed group of options. parsing group of options: input file photo.jpg. parsed group of options. opening input file: photo.jpg. [aviocontext @ 0x372f700] statistics: 303755 bytes read, 0 seeks [mjpeg @ 0x372c6a0] marker=f9 avail_size_in_buf=303444 [mjpeg @ 0x372c6a0] marker parser used 0 bytes (0 bits) [mjpeg @ 0x372c6a0] marker=de avail_size_in_buf=303438 [mjpeg @ 0x372c6a0] marker parser used 0 bytes (0 bits) [mjpeg @ 0x372c6a0] marker=fd avail_size_in_buf=302501 [mjpeg @ 0x372c6a0] marker parser used 0 bytes (0 bits) [mjpeg @ 0x372c6a0] marker=f3 avail_size_in_buf=298342 [mjpeg @ 0x372c6a0] marker parser used 0 bytes (0 bits) [mjpeg @ 0x372c6a0] marker=f8 avail_size_in_buf=297965 [mjpeg @ 0x372c6a0] invalid id 248 [image2 @ 0x372b880] decoding stream 0 failed [image2 @ 0x372b880] not find codec parameters stream 0 (video: mjpeg): unspecified size consider increasing value 'analyzeduration' , 'probesize' options photo.jpg: not find codec parameters 

as checked, configuration of ffmpeg different. on linux:

ffmpeg version n-63893-gc69defd built on jul 16 2014 05:38:01 gcc 4.6 (debian 4.6.3-1) configuration: --prefix=/root/ffmpeg-static/64bit --extra-cflags='-i/root/ffmpeg-static/64bit/include -static' --extra-ldflags='-l/root/ffmpeg-static/64bit/lib -static' --extra-libs='-lxml2 -lexpat -lfreetype' --enable-static --disable-shared --disable-ffserver --disable-doc --enable-bzlib --enable-zlib --enable-postproc --enable-runtime-cpudetect --enable-libx264 --enable-gpl --enable-libtheora --enable-libvorbis --enable-libmp3lame --enable-gray --enable-libass --enable-libfreetype --enable-libopenjpeg --enable-libspeex --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-version3 --enable-libvpx libavutil      52. 89.100 / 52. 89.100 libavcodec     55. 66.101 / 55. 66.101 libavformat    55. 43.100 / 55. 43.100 libavdevice    55. 13.101 / 55. 13.101 libavfilter     4.  8.100 /  4.  8.100 libswscale      2.  6.100 /  2.  6.100 libswresample   0. 19.100 /  0. 19.100 libpostproc    52.  3.100 / 52.  3.100 

on mac:

ffmpeg version 2.8.5 copyright (c) 2000-2016 ffmpeg developers built apple llvm version 7.0.2 (clang-700.1.81) configuration: --prefix=/usr/local/cellar/ffmpeg/2.8.5 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-vda libavutil      54. 31.100 / 54. 31.100 libavcodec     56. 60.100 / 56. 60.100 libavformat    56. 40.101 / 56. 40.101 libavdevice    56.  4.100 / 56.  4.100 libavfilter     5. 40.101 /  5. 40.101 libavresample   2.  1.  0 /  2.  1.  0 libswscale      3.  1.101 /  3.  1.101 libswresample   1.  2.101 /  1.  2.101 libpostproc    53.  3.100 / 53.  3.100 

but specific image scaling in difference? , how make amazone linux's version of ffmpeg work same way mac's version (at least, in case)?


Comments