H264

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

H264

jackyr
Hi
I have a trouble to encode DV50 (dvdvideo) format  into flv
this format comes with yuv422 which incompatible with profiles main and
baseline
is there a way to get flv format
ffmpeg  -i <input_file>   -f flv -y  <dest_file.flv>

this works but the flv file is getting yuv422 (I would like 420p)
  ffmpeg  -i <input_file> -vcodec libx264 -b:v 380k  -r:v 25 -g 200
-a:codec aac -strict experimental -ar 44100 -ab 56k -ac 1 -f flv -y
<dest_file.flv>
I have tried both -pixel_format yuv420p and/or profile main or baseline
with does not work

what I would like to get is
flv yuv420p main or baseline profile could you help me ?

following  are 2 log  extract the  first is ok (but the ouput is still
422 )
the second one does not run but end of the log file it says profile is
not correct while its recommand the main profile
what can I do

thanks for your help
jacky





ffmpeg started on 2014-01-23 at 13:29:28
Report written to "ffmpeg-20140123-132928.log"
Command line:
ffmpeg -i entree.dv -vcodec libx264 -b:v 380k -r:v 25 -vf
"scale=720:ih*544/576" -pixel_format yuv420p -g 200 -threads 0 -acodec
aac -strict experimental -cutoff 15000 -ab 56k -ar 44100 -ac 1
-benchmark -loglevel verbose -report -f flv -y sortie_qn.flv -vcodec
libx264 -b:v 600k -r:v 25 -vf "scale=720:ih*544/576" -pixel_format
yuv420p -g 200 -threads 0 -acodec aac -strict experimental -cutoff 15000
-ab 56k -ar 44100 -ac 1 -y sortie_bq.flv
ffmpeg version N-59407-gfead241 Copyright (c) 2000-2013 the FFmpeg
developers
   built on Dec 28 2013 22:01:59 with gcc 4.8.2 (GCC)
   configuration: --enable-gpl --enable-version3 --disable-w32threads
--enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r
--enable-gnutls --enable-iconv --enable-libass --enable-libbluray
--enable-libcaca --enable-libfreetype --enable-libgsm --enable-libilbc
--enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus
--enable-librtmp --enable-libschroedinger --enable-libsoxr
--enable-libspeex --enable-libtheora --enable-libtwolame
--enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc
--enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libx264
--enable-libxavs --enable-libxvid --enable-zlib
   libavutil      52. 59.100 / 52. 59.100
   libavcodec     55. 47.100 / 55. 47.100
   libavformat    55. 22.100 / 55. 22.100
   libavdevice    55.  5.102 / 55.  5.102
   libavfilter     4.  0.103 /  4.  0.103
   libswscale      2.  5.101 /  2.  5.101
   libswresample   0. 17.104 /  0. 17.104
   libpostproc    52.  3.100 / 52.  3.100
Splitting the commandline.
Reading option '-i' ... matched as input file with argument 'entree.dv'.
Reading option '-vcodec' ... matched as option 'vcodec' (force video
codec ('copy' to copy stream)) with argument 'libx264'.
Reading option '-b:v' ... matched as option 'b' (video bitrate (please
use -b:v)) with argument '380k'.
Reading option '-r:v' ... matched as option 'r' (set frame rate (Hz
value, fraction or abbreviation)) with argument '25'.
Reading option '-vf' ... matched as option 'vf' (set video filters) with
argument 'scale=720:ih*544/576'.
Reading option '-pixel_format' ... matched as AVOption 'pixel_format'
with argument 'yuv420p'.
Reading option '-g' ... matched as AVOption 'g' with argument '200'.
Reading option '-threads' ... matched as AVOption 'threads' with
argument '0'.
Reading option '-acodec' ... matched as option 'acodec' (force audio
codec ('copy' to copy stream)) with argument 'aac'.
Reading option '-strict' ... matched as AVOption 'strict' with argument
'experimental'.
Reading option '-cutoff' ... matched as AVOption 'cutoff' with argument
'15000'.
Reading option '-ab' ... matched as AVOption 'ab' with argument '56k'.
Reading option '-ar' ... matched as option 'ar' (set audio sampling rate
(in Hz)) with argument '44100'.
Reading option '-ac' ... matched as option 'ac' (set number of audio
channels) with argument '1'.
Reading option '-benchmark' ... matched as option 'benchmark' (add
timings for benchmarking) with argument '1'.
Reading option '-loglevel' ... matched as option 'loglevel' (set logging
level) with argument 'verbose'.
Reading option '-report' ... matched as option 'report' (generate a
report) with argument '1'.
Reading option '-f' ... matched as option 'f' (force format) with
argument 'flv'.
Reading option '-y' ... matched as option 'y' (overwrite output files)
with argument '1'.
Reading option 'sortie_qn.flv' ... matched as output file.
Reading option '-vcodec' ... matched as option 'vcodec' (force video
codec ('copy' to copy stream)) with argument 'libx264'.
Reading option '-b:v' ... matched as option 'b' (video bitrate (please
use -b:v)) with argument '600k'.
Reading option '-r:v' ... matched as option 'r' (set frame rate (Hz
value, fraction or abbreviation)) with argument '25'.
Reading option '-vf' ... matched as option 'vf' (set video filters) with
argument 'scale=720:ih*544/576'.
Reading option '-pixel_format' ... matched as AVOption 'pixel_format'
with argument 'yuv420p'.
Reading option '-g' ... matched as AVOption 'g' with argument '200'.
Reading option '-threads' ... matched as AVOption 'threads' with
argument '0'.
Reading option '-acodec' ... matched as option 'acodec' (force audio
codec ('copy' to copy stream)) with argument 'aac'.
Reading option '-strict' ... matched as AVOption 'strict' with argument
'experimental'.
Reading option '-cutoff' ... matched as AVOption 'cutoff' with argument
'15000'.
Reading option '-ab' ... matched as AVOption 'ab' with argument '56k'.
Reading option '-ar' ... matched as option 'ar' (set audio sampling rate
(in Hz)) with argument '44100'.
Reading option '-ac' ... matched as option 'ac' (set number of audio
channels) with argument '1'.
Reading option '-y' ... matched as option 'y' (overwrite output files)
with argument '1'.
Reading option 'sortie_bq.flv' ... matched as output file.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option benchmark (add timings for benchmarking) with argument 1.
Applying option loglevel (set logging level) with argument verbose.
Applying option report (generate a report) with argument 1.
Applying option y (overwrite output files) with argument 1.
Applying option y (overwrite output files) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input file entree.dv.
Successfully parsed a group of options.
Opening an input file: entree.dv.
[dv @ 03e46a60] Format dv probed with size=2048 and score=75
[dv @ 03e46a60] Before avformat_find_stream_info() pos: 0 bytes
read:32768 seeks:0
[dv @ 03e46a60] All info found
[dv @ 03e46a60] Estimating duration from bitrate, this may be inaccurate
[dv @ 03e46a60] After avformat_find_stream_info() pos: 288000 bytes
read:288000 seeks:0 frames:3
Input #0, dv, from 'entree.dv':
   Metadata:
     timecode        : 00:00:00:00
   Duration: 00:00:25.60, start: 0.000000, bitrate: 57600 kb/s
     Stream #0:0, 1, 1/25: Video: dvvideo, yuv422p, 720x576 [SAR 16:15
DAR 4:3], 57600 kb/s, 25 tbr, 25 tbn, 25 tbc
     Stream #0:1, 1, 1/30000: Audio: pcm_s16le, 48000 Hz, stereo, s16,
1536 kb/s
     Stream #0:2, 1, 1/30000: Audio: pcm_s16le, 48000 Hz, stereo, s16,
1536 kb/s
Successfully opened the file.
Parsing a group of options: output file sortie_qn.flv.
Applying option vcodec (force video codec ('copy' to copy stream)) with
argument libx264.
Applying option b:v (video bitrate (please use -b:v)) with argument 380k.
Applying option r:v (set frame rate (Hz value, fraction or
abbreviation)) with argument 25.
Applying option vf (set video filters) with argument scale=720:ih*544/576.
Applying option acodec (force audio codec ('copy' to copy stream)) with
argument aac.
Applying option ar (set audio sampling rate (in Hz)) with argument 44100.
Applying option ac (set number of audio channels) with argument 1.
Applying option f (force format) with argument flv.
Successfully parsed a group of options.
Opening an output file: sortie_qn.flv.
Successfully opened the file.
Parsing a group of options: output file sortie_bq.flv.


second log

ffmpeg started on 2014-01-23 at 13:56:39
Report written to "ffmpeg-20140123-135639.log"
Command line:
ffmpeg -i entree.dv -vcodec libx264 -b:v 380k -profile:v main -r:v 25
-vf "scale=720:ih*544/576" -pixel_format yuv420p -g 200 -threads 0 -an
-benchmark -loglevel verbose -report -f flv -y sortie_qn.flv -vcodec
libx264 -b:v 600k -r:v 25 -vf "scale=720:ih*544/576" -pixel_format
yuv420p -g 200 -threads 0 -an -y sortie_bq.flv
ffmpeg version N-59407-gfead241 Copyright (c) 2000-2013 the FFmpeg
developers
   built on Dec 28 2013 22:01:59 with gcc 4.8.2 (GCC)
   configuration: --enable-gpl --enable-version3 --disable-w32threads
--enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r
--enable-gnutls --enable-iconv --enable-libass --enable-libbluray
--enable-libcaca --enable-libfreetype --enable-libgsm --enable-libilbc
--enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus
--enable-librtmp --enable-libschroedinger --enable-libsoxr
--enable-libspeex --enable-libtheora --enable-libtwolame
--enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc
--enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libx264
--enable-libxavs --enable-libxvid --enable-zlib
   libavutil      52. 59.100 / 52. 59.100
   libavcodec     55. 47.100 / 55. 47.100
   libavformat    55. 22.100 / 55. 22.100
   libavdevice    55.  5.102 / 55.  5.102
   libavfilter     4.  0.103 /  4.  0.103
   libswscale      2.  5.101 /  2.  5.101
   libswresample   0. 17.104 /  0. 17.104
   libpostproc    52.  3.100 / 52.  3.100
Splitting the commandline.
Reading option '-i' ... matched as input file with argument 'entree.dv'.
Reading option '-vcodec' ... matched as option 'vcodec' (force video
codec ('copy' to copy stream)) with argument 'libx264'.
Reading option '-b:v' ... matched as option 'b' (video bitrate (please
use -b:v)) with argument '380k'.
Reading option '-profile:v' ... matched as option 'profile' (set
profile) with argument 'main'.
Reading option '-r:v' ... matched as option 'r' (set frame rate (Hz
value, fraction or abbreviation)) with argument '25'.
Reading option '-vf' ... matched as option 'vf' (set video filters) with
argument 'scale=720:ih*544/576'.
Reading option '-pixel_format' ... matched as AVOption 'pixel_format'
with argument 'yuv420p'.
Reading option '-g' ... matched as AVOption 'g' with argument '200'.
Reading option '-threads' ... matched as AVOption 'threads' with
argument '0'.
Reading option '-an' ... matched as option 'an' (disable audio) with
argument '1'.
Reading option '-benchmark' ... matched as option 'benchmark' (add
timings for benchmarking) with argument '1'.
Reading option '-loglevel' ... matched as option 'loglevel' (set logging
level) with argument 'verbose'.
Reading option '-report' ... matched as option 'report' (generate a
report) with argument '1'.
Reading option '-f' ... matched as option 'f' (force format) with
argument 'flv'.
Reading option '-y' ... matched as option 'y' (overwrite output files)
with argument '1'.
Reading option 'sortie_qn.flv' ... matched as output file.
Reading option '-vcodec' ... matched as option 'vcodec' (force video
codec ('copy' to copy stream)) with argument 'libx264'.
Reading option '-b:v' ... matched as option 'b' (video bitrate (please
use -b:v)) with argument '600k'.
Reading option '-r:v' ... matched as option 'r' (set frame rate (Hz
value, fraction or abbreviation)) with argument '25'.
Reading option '-vf' ... matched as option 'vf' (set video filters) with
argument 'scale=720:ih*544/576'.
Reading option '-pixel_format' ... matched as AVOption 'pixel_format'
with argument 'yuv420p'.
Reading option '-g' ... matched as AVOption 'g' with argument '200'.
Reading option '-threads' ... matched as AVOption 'threads' with
argument '0'.
Reading option '-an' ... matched as option 'an' (disable audio) with
argument '1'.
Reading option '-y' ... matched as option 'y' (overwrite output files)
with argument '1'.
Reading option 'sortie_bq.flv' ... matched as output file.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option benchmark (add timings for benchmarking) with argument 1.
Applying option loglevel (set logging level) with argument verbose.
Applying option report (generate a report) with argument 1.
Applying option y (overwrite output files) with argument 1.
Applying option y (overwrite output files) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input file entree.dv.
Successfully parsed a group of options.
Opening an input file: entree.dv.
[dv @ 02887e40] Format dv probed with size=2048 and score=75
[dv @ 02887e40] Before avformat_find_stream_info() pos: 0 bytes
read:32768 seeks:0
[dv @ 02887e40] All info found
[dv @ 02887e40] Estimating duration from bitrate, this may be inaccurate
[dv @ 02887e40] After avformat_find_stream_info() pos: 288000 bytes
read:288000 seeks:0 frames:3
Input #0, dv, from 'entree.dv':
   Metadata:
     timecode        : 00:00:00:00
   Duration: 00:00:25.60, start: 0.000000, bitrate: 57600 kb/s
     Stream #0:0, 1, 1/25: Video: dvvideo, yuv422p, 720x576 [SAR 16:15
DAR 4:3], 57600 kb/s, 25 tbr, 25 tbn, 25 tbc
     Stream #0:1, 1, 1/30000: Audio: pcm_s16le, 48000 Hz, stereo, s16,
1536 kb/s
     Stream #0:2, 1, 1/30000: Audio: pcm_s16le, 48000 Hz, stereo, s16,
1536 kb/s
Successfully opened the file.
Parsing a group of options: output file sortie_qn.flv.
Applying option vcodec (force video codec ('copy' to copy stream)) with
argument libx264.
Applying option b:v (video bitrate (please use -b:v)) with argument 380k.
Applying option profile:v (set profile) with argument main.
Applying option r:v (set frame rate (Hz value, fraction or
abbreviation)) with argument 25.
Applying option vf (set video filters) with argument scale=720:ih*544/576.
Applying option an (disable audio) with argument 1.
Applying option f (force format) with argument flv.
Successfully parsed a group of options.
Opening an output file: sortie_qn.flv.
Successfully opened the file.
Parsing a group of options: output file sortie_bq.flv.
Applying option vcodec (force video codec ('copy' to copy stream)) with
argument libx264.
Applying option b:v (video bitrate (please use -b:v)) with argument 600k.
Applying option r:v (set frame rate (Hz value, fraction or
abbreviation)) with argument 25.
Applying option vf (set video filters) with argument scale=720:ih*544/576.
Applying option an (disable audio) with argument 1.
Successfully parsed a group of options.
Opening an output file: sortie_bq.flv.
Successfully opened the file.
detected 4 logical cores
[Parsed_scale_0 @ 03da7d60] Setting 'w' to value '720'
[Parsed_scale_0 @ 03da7d60] Setting 'h' to value 'ih*544/576'
[Parsed_scale_0 @ 03da7d60] Setting 'flags' to value '0x4'
[Parsed_scale_0 @ 03da7d60] w:720 h:ih*544/576 flags:'0x4' interl:0
[graph 0 input from stream 0:0 @ 02889c40] Setting 'video_size' to value
'720x576'
[graph 0 input from stream 0:0 @ 02889c40] Setting 'pix_fmt' to value '4'
[graph 0 input from stream 0:0 @ 02889c40] Setting 'time_base' to value
'1/25'
[graph 0 input from stream 0:0 @ 02889c40] Setting 'pixel_aspect' to
value '16/15'
[graph 0 input from stream 0:0 @ 02889c40] Setting 'sws_param' to value
'flags=2'
[graph 0 input from stream 0:0 @ 02889c40] Setting 'frame_rate' to value
'25/1'
[graph 0 input from stream 0:0 @ 02889c40] w:720 h:576 pixfmt:yuv422p
tb:1/25 fr:25/1 sar:16/15 sws_param:flags=2
[format @ 0288bf00] compat: called with
args=[yuv420p|yuvj420p|yuv422p|yuvj422p|yuv444p|yuvj444p|nv12|nv16]
[format @ 0288bf00] Setting 'pix_fmts' to value
'yuv420p|yuvj420p|yuv422p|yuvj422p|yuv444p|yuvj444p|nv12|nv16'
[AVFilterGraph @ 03dabfa0] query_formats: 4 queried, 3 merged, 0 already
done, 0 delayed
[Parsed_scale_0 @ 03da7d60] w:720 h:576 fmt:yuv422p sar:16/15 -> w:720
h:544 fmt:yuv422p sar:136/135 flags:0x4
No pixel format specified, yuv422p for H.264 encoding chosen.
Use -pix_fmt yuv420p for compatibility with outdated media players.
[Parsed_scale_0 @ 0288d5e0] Setting 'w' to value '720'
[Parsed_scale_0 @ 0288d5e0] Setting 'h' to value 'ih*544/576'
[Parsed_scale_0 @ 0288d5e0] Setting 'flags' to value '0x4'
[Parsed_scale_0 @ 0288d5e0] w:720 h:ih*544/576 flags:'0x4' interl:0
[graph 1 input from stream 0:0 @ 0288cb60] Setting 'video_size' to value
'720x576'
[graph 1 input from stream 0:0 @ 0288cb60] Setting 'pix_fmt' to value '4'
[graph 1 input from stream 0:0 @ 0288cb60] Setting 'time_base' to value
'1/25'
[graph 1 input from stream 0:0 @ 0288cb60] Setting 'pixel_aspect' to
value '16/15'
[graph 1 input from stream 0:0 @ 0288cb60] Setting 'sws_param' to value
'flags=2'
[graph 1 input from stream 0:0 @ 0288cb60] Setting 'frame_rate' to value
'25/1'
[graph 1 input from stream 0:0 @ 0288cb60] w:720 h:576 pixfmt:yuv422p
tb:1/25 fr:25/1 sar:16/15 sws_param:flags=2
[format @ 0288cde0] compat: called with
args=[yuv420p|yuvj420p|yuv422p|yuvj422p|yuv444p|yuvj444p|nv12|nv16]
[format @ 0288cde0] Setting 'pix_fmts' to value
'yuv420p|yuvj420p|yuv422p|yuvj422p|yuv444p|yuvj444p|nv12|nv16'
[AVFilterGraph @ 03db5180] query_formats: 4 queried, 3 merged, 0 already
done, 0 delayed
[Parsed_scale_0 @ 0288d5e0] w:720 h:576 fmt:yuv422p sar:16/15 -> w:720
h:544 fmt:yuv422p sar:136/135 flags:0x4
No pixel format specified, yuv422p for H.264 encoding chosen.
Use -pix_fmt yuv420p for compatibility with outdated media players.
[libx264 @ 03da1f60] Error setting profile main.
[libx264 @ 03da1f60] Possible profiles: baseline main high high10
high422 high444
Output #0, flv, to 'sortie_qn.flv':
   Metadata:
     timecode        : 00:00:00:00
     Stream #0:0, 0, 1/90000: Video: h264, yuv422p, 720x544 [SAR 136:135
DAR 4:3], q=-1--1, 380 kb/s, 90k tbn, 25 tbc
Output #1, flv, to 'sortie_bq.flv':
   Metadata:
     timecode        : 00:00:00:00
     Stream #1:0, 0, 1/90000: Video: h264, yuv422p, 720x544 [SAR 136:135
DAR 4:3], q=-1--1, 90k tbn, 25 tbc
Stream mapping:
   Stream #0:0 -> #0:0 (dvvideo -> libx264)
   Stream #0:0 -> #1:0 (dvvideo -> libx264)
Error while opening encoder for output stream #0:0 - maybe incorrect
parameters such as bit_rate, rate, width or height
[AVIOContext @ 03da3040] Statistics: 0 seeks, 0 writeouts
[AVIOContext @ 03da53c0] Statistics: 0 seeks, 0 writeouts
[AVIOContext @ 028883e0] Statistics: 288000 bytes read, 0 seeks

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: H264

James Darnley
On 2014-01-23 14:01, jacky wrote:
> No pixel format specified, yuv422p for H.264 encoding chosen.
> Use -pix_fmt yuv420p for compatibility with outdated media players.

It quite clearly says here what you should do.  Where did you get
-pixel_format from?


_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

signature.asc (697 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: H264

jackyr

Le 23/01/2014 14:07, James Darnley a écrit :

> On 2014-01-23 14:01, jacky wrote:
>> No pixel format specified, yuv422p for H.264 encoding chosen.
>> Use -pix_fmt yuv420p for compatibility with outdated media players.
> It quite clearly says here what you should do.  Where did you get
> -pixel_format from?
>
>
>
> _______________________________________________
> ffmpeg-user mailing list
> [hidden email]
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
OH !!! what a mistake I made , pixel_format is the internal batch name
not any of ffmpeg arg
I apologise for such a mistake .. it take me su much time to debug .. it
was obvious . sorry
many thanks
jacky


_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user