<html><head></head><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px"><div id="yui_3_16_0_1_1444584732413_3552">Hi,</div><div dir="ltr" id="yui_3_16_0_1_1444584732413_3583">almost 2 weeks ago I mailed this patch but no one answered.</div><div id="yui_3_16_0_1_1444584732413_3683" dir="ltr">Maybe I should give more informations about this:</div><div id="yui_3_16_0_1_1444584732413_3788" dir="ltr">When trying to encode AVC-Intra with ffmpeg/x264 in mov container I get following x264 error message "Separate headers not supported in AVC-Intra mode".</div><div id="yui_3_16_0_1_1444584732413_4421" dir="ltr">Also x264_sei_version_write is called with the x264_encoder_headers function, which should be not allowed for AVC-Intra.<br></div><div dir="ltr" id="yui_3_16_0_1_1444584732413_3553">I first wrote a patch for ffmpeg to fix this but then I thought that it makes more sense to patch x264 because other applications using x264 may behave the same.</div><div id="yui_3_16_0_1_1444584732413_4260" dir="ltr">Please comment or just give me a short information if there is no interest.<br></div><div id="yui_3_16_0_1_1444584732413_4358" dir="ltr">Regards,</div><div id="yui_3_16_0_1_1444584732413_4386" dir="ltr">Thomas<br></div> <br><div class="qtdSeparateBR"><br><br></div><div style="display: block;" class="yahoo_quoted"> <div style="font-family: HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div dir="ltr"> <font face="Arial" size="2"> Thomas Mundt <loudmax@yahoo.de> schrieb am 1:49 Dienstag, 29.September 2015:<br> </font> </div> <br><br> <div class="y_msg_container">IME-Version: 1.0<br>Content-Type: text/plain; charset=UTF-8<br>Content-Transfer-Encoding: 8bit<br><br>For x264 encoding in mov container ffmpeg sets x264 parameter b_repeat_headers to 0 and calls x264_encoder_headers which calls x264_sei_version_write function. Both is not allowed for AVC-Intra. Since other applications may behave similar it´s better to avoid this here.<br><br>Signed-off-by: Thomas Mundt <<a ymailto="mailto:loudmax@yahoo.de" href="mailto:loudmax@yahoo.de">loudmax@yahoo.de</a>><br>---<br> encoder/encoder.c | 18 ++++++++++--------<br> 1 file changed, 10 insertions(+), 8 deletions(-)<br><br>diff --git a/encoder/encoder.c b/encoder/encoder.c<br>index 79997b9..e2f0048 100644<br>--- a/encoder/encoder.c<br>+++ b/encoder/encoder.c<br>@@ -743,8 +743,8 @@ static int x264_validate_parameters( x264_t *h, int b_open )<br> <br> if( !h->param.b_repeat_headers )<br> {<br>- x264_log( h, X264_LOG_ERROR, "Separate headers not supported in AVC-Intra mode\n" );<br>- return -1;<br>+ x264_log( h, X264_LOG_INFO, "Separate headers is not supported in AVC-Intra mode and will be ignored\n" );<br>+ h->param.b_repeat_headers = 1;<br> }<br> <br> int i;<br>@@ -2005,12 +2005,14 @@ int x264_encoder_headers( x264_t *h, x264_nal_t **pp_nal, int *pi_nal )<br> if( x264_nal_end( h ) )<br> return -1;<br> <br>- /* identify ourselves */<br>- x264_nal_start( h, NAL_SEI, NAL_PRIORITY_DISPOSABLE );<br>- if( x264_sei_version_write( h, &h->out.bs ) )<br>- return -1;<br>- if( x264_nal_end( h ) )<br>- return -1;<br>+ /* identify ourselves when not AVC-Intra */<br>+ if( !h->param.i_avcintra_class ) {<br>+ x264_nal_start( h, NAL_SEI, NAL_PRIORITY_DISPOSABLE );<br>+ if( x264_sei_version_write( h, &h->out.bs ) )<br>+ return -1;<br>+ if( x264_nal_end( h ) )<br>+ return -1;<br>+ }<br> <br> frame_size = x264_encoder_encapsulate_nals( h, 0 );<br> if( frame_size < 0 )<br>-- <br>1.9.2<br><br><br><br>_______________________________________________<br>x264-devel mailing list<br><a ymailto="mailto:x264-devel@videolan.org" href="mailto:x264-devel@videolan.org">x264-devel@videolan.org</a><br><a href="https://mailman.videolan.org/listinfo/x264-devel" target="_blank">https://mailman.videolan.org/listinfo/x264-devel</a><br><br><br></div> </div> </div> </div></div></body></html>