[FFmpeg-user] Streaming Syntax error
Mettavihari D
tv.lists at gmail.com
Mon Jul 24 07:00:38 EEST 2017
Greetings,
I have tried this several ways, but keep getting errors.
My problem is that the recipient wants a fixed bitrate and that my
stream is varying in bitrate.
>>
>> Thank you for the note
>> What do you suggest that I put in this line
>> If I can have the syntax to use then I can adjust the values.
>>
>> On Wed, Jun 28, 2017 at 7:17 AM, Reuben Martin <reuben.m at gmail.com> wrote:
>>> On Tuesday, June 27, 2017 7:09:46 PM CDT Mettavihari D wrote:
>>>> I tried the following:
>>>> /root/bin/ffmpeg -re -i /data/video/sinhala/innput-15m.mp4 -acodec
>>>> copy -vcodec copy -maxrate 1.5M -bufsize 3M -f flv -metadata
>>>> streamName=xlarge rtmp://some.site.com.
>>>
>>> You cannot adjust the bitrate of the stream without re-encoding it. (i.e. you
>>> cannot use "-vcodec copy”)
>>>
>>> -Reuben
>>>
>>>
>
> Does this syntax look OK
>
> /root/bin/ffmpeg -re -i /data/video/sinhala/input-15m.mp4 -b 1500k
> -minrate 1500k -maxrate 1500k -bufsize 3000k -f flv -metadata
> streamName=xlarge rtmp://some.site.com.
>
when I run this on the command line it is working.
ffmpeg -i file.mp4 -acodec libfdk_aac -b:a 128k -vcodec libx264
-preset fast -b:v 1500k -minrate 1500k -maxrate 1500k -bufsize 3000k
-f mp4 outfile.mp4
When I run this in a script I get errors.
ffmpeg_pids.append(subprocess32.Popen([args['ffmpeg_path'], '-re',
'-i', args['content_dir']+'/'+args['channel_dir']+"/"+dharmavahini,
'-acodec', 'libfdk_aac', '-b:a 128k', '-vcodec', 'libx264', '-b:v
1500k', '-minrate 1500k -maxrate 1500k -bufsize 1500k', '-f', 'flv',
'-metadata', 'streamName=xlarge', 'rtmp://site']))
The errors are given below.
Unable to find a suitable output format for 'libx264' libx264: Invalid argument
ffmpeg version N-86069-ga453f55 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-11)
configuration: --prefix=/root/ffmpeg_build
--extra-cflags=-I/root/ffmpeg_build/include
--extra-ldflags='-L/root/ffmpeg_build/lib -ldl' --bindir=/root/bin
--pkg-config-flags=--static --enable-gpl --enable-nonfree
--enable-libfdk_aac --enable-libfreetype --enable-libmp3lame
--enable-libvorbis --enable-libvpx --enable-libx264
libavutil 55. 62.100 / 55. 62.100
libavcodec 57. 95.101 / 57. 95.101
libavformat 57. 72.101 / 57. 72.101
libavdevice 57. 7.100 / 57. 7.100
libavfilter 6. 89.100 / 6. 89.100
libswscale 4. 7.101 / 4. 7.101
libswresample 2. 8.100 / 2. 8.100
libpostproc 54. 6.100 / 54. 6.100
/media/data/playlists/yupptv/sutta/satipattana-15m.mp4: No such file
or directory
ffmpeg version N-86069-ga453f55 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-11)
configuration: --prefix=/root/ffmpeg_build
--extra-cflags=-I/root/ffmpeg_build/include
--extra-ldflags='-L/root/ffmpeg_build/lib -ldl' --bindir=/root/bin
--pkg-config-flags=--static --enable-gpl --enable-nonfree
--enable-libfdk_aac --enable-libfreetype --enable-libmp3lame
--enable-libvorbis --enable-libvpx --enable-libx264
libavutil 55. 62.100 / 55. 62.100
libavcodec 57. 95.101 / 57. 95.101
libavformat 57. 72.101 / 57. 72.101
libavdevice 57. 7.100 / 57. 7.100
libavfilter 6. 89.100 / 6. 89.100
libswscale 4. 7.101 / 4. 7.101
libswresample 2. 8.100 / 2. 8.100
libpostproc 54. 6.100 / 54. 6.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from
'/media/data/video/yupptv/sutta/satipattana-15m.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf54.3.100
Duration: 01:12:47.78, start: 0.000000, bitrate: 1603 kb/s
Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p,
704x396 [SAR 3:4 DAR 4:3], 1468 kb/s, 25 fps, 25 tbr, 25 tbn, 50 tbc
(default)
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz,
stereo, fltp, 127 kb/s (default)
Metadata:
handler_name : SoundHandler
[NULL @ 0x3ca53a0] Unable to find a suitable output format for 'libx264'
libx264: Invalid argument
A hint on where to read more on this is very useful.
regards
Mettavihari
More information about the ffmpeg-user
mailing list