Merge commit 'eae7338e1592f4a398b7c3cb9d1ac854b7a44ff8'
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 24 Apr 2015 20:21:12 +0000 (22:21 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 24 Apr 2015 20:21:17 +0000 (22:21 +0200)
* commit 'eae7338e1592f4a398b7c3cb9d1ac854b7a44ff8':
  libx264: Make codec use the init-cleanup flag and mark it as init-thread-safe

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavcodec/libx264.c

@@@ -886,22 -696,9 +888,24 @@@ AVCodec ff_libx264_encoder = 
      .encode2          = X264_frame,
      .close            = X264_close,
      .capabilities     = CODEC_CAP_DELAY | CODEC_CAP_AUTO_THREADS,
 -    .priv_class       = &class,
 +    .priv_class       = &x264_class,
      .defaults         = x264_defaults,
      .init_static_data = X264_init_static,
+     .caps_internal    = FF_CODEC_CAP_INIT_THREADSAFE |
+                         FF_CODEC_CAP_INIT_CLEANUP,
  };
 +
 +AVCodec ff_libx264rgb_encoder = {
 +    .name           = "libx264rgb",
 +    .long_name      = NULL_IF_CONFIG_SMALL("libx264 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 RGB"),
 +    .type           = AVMEDIA_TYPE_VIDEO,
 +    .id             = AV_CODEC_ID_H264,
 +    .priv_data_size = sizeof(X264Context),
 +    .init           = X264_init,
 +    .encode2        = X264_frame,
 +    .close          = X264_close,
 +    .capabilities   = CODEC_CAP_DELAY | CODEC_CAP_AUTO_THREADS,
 +    .priv_class     = &rgbclass,
 +    .defaults       = x264_defaults,
 +    .pix_fmts       = pix_fmts_8bit_rgb,
 +};