Opened 9 years ago
Closed 8 years ago
#4586 closed defect (needs_more_info)
ffmpeg cannot re-stream yuvj420 h264 format video from ip camera
Reported by: | tapas | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | undetermined |
Version: | git-master | Keywords: | h264 rtsp |
Cc: | Michael Niedermayer | Blocked By: | |
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
I can save camera video to hard disk by running following command :
/home/broadcaster/bin/ffmpeg -use_wallclock_as_timestamps 1 -r 25 -thread_queue_size 51200 -threads 4 -i "rtsp://admin:admin@$1:8557/PSIA/Streaming/channels/2?videoCodecType=H.264" -use_wallclock_as_timestamps 1 -r 25 -b:v 2048k -bufsize 20480 -c:v copy -f avi cam.avi
But I cannot re-stream video from above ip camera to any FMS server.
here is the command which I am using for re-streaming:
/home/broadcaster/bin/ffmpeg -use_wallclock_as_timestamps 1 -r 25 -thread_queue_size 51200 -threads 4 -i "rtsp://admin:admin@$1:8557/PSIA/Streaming/channels/2?videoCodecType=H.264" -use_wallclock_as_timestamps 1 -r 25 -b:v 2048k -bufsize 20480 -c:v copy -f flv rtmp://ip_url
Further debugging showed me that it happens only when ip camera generates yuvj420p stream.
But above command works if I use a different ip camera which outputs video format as yuv420p.
here is the bug report generated with "-report" arguments for affected ip camera using above command.
But if I try to record video to hard disk in avi container then ffmpeg does it successfully. here is the command which I used to save camera h264 stream into avi file:
/home/broadcaster/bin/ffmpeg -use_wallclock_as_timestamps 1 -r 25 -thread_queue_size 51200 -threads 4 -i "rtsp://admin:admin@$1:8557/PSIA/Streaming/channels/2?videoCodecType=H.264" -use_wallclock_as_timestamps 1 -r 25 -b:v 2048k -bufsize 20480 -c:v copy -f avi cam.avi
saved Avi file from above command :
[1] http://www.datafilehost.com/d/4c6e8f04
This issue can be easily reproduced if we run following command on above [1] avi file:
ffmpeg -v 9 -loglevel 99 -i cam.avi -codec copy -f flv cam.flv -report
ffmpeg does not give any error but it can generate correct flv file too.
Issue is present on latest ffmpeg as of today (1st June, 2015) found in http://johnvansickle.com/ffmpeg/
Attachments (2)
Change History (6)
by , 9 years ago
Attachment: | ffmpeg-20150601-223924.log added |
---|
by , 9 years ago
Attachment: | ffmpeg-20150601-222202.log added |
---|
ffmpeg cannot convert avi to flv format
comment:1 by , 9 years ago
Component: | ffmpeg → undetermined |
---|---|
Keywords: | h264 added; yuvj420p streaming fails removed |
Priority: | critical → normal |
Reproduced by developer: | unset |
comment:3 by , 9 years ago
Cc: | added |
---|
comment:4 by , 8 years ago
Resolution: | → needs_more_info |
---|---|
Status: | new → closed |
rtsp streaming failed for yuvj420p h264 video format