avcodec/libopenjpegenc: Add frame-threading capability
authorDave Rice <dave@dericed.com>
Tue, 3 Jun 2014 18:47:17 +0000 (14:47 -0400)
committerMichael Niedermayer <michaelni@gmx.at>
Tue, 3 Jun 2014 19:17:04 +0000 (21:17 +0200)
This gives a >50% speed up when encoding with libopenjpeg.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/libopenjpegenc.c

index ac77c7d..0fcc48f 100644 (file)
@@ -645,7 +645,7 @@ AVCodec ff_libopenjpeg_encoder = {
     .init           = libopenjpeg_encode_init,
     .encode2        = libopenjpeg_encode_frame,
     .close          = libopenjpeg_encode_close,
-    .capabilities   = 0,
+    .capabilities   = CODEC_CAP_FRAME_THREADS | CODEC_CAP_INTRA_ONLY,
     .pix_fmts       = (const enum AVPixelFormat[]) {
         AV_PIX_FMT_RGB24, AV_PIX_FMT_RGBA, AV_PIX_FMT_RGB48,
         AV_PIX_FMT_RGBA64, AV_PIX_FMT_GBR24P,