X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Flibtheoraenc.c;h=0ae03bfb1c42ed52a64e8002382b7071ef5a942b;hb=11491503c492f3a3ce190e2ee8cec660d3b91e1d;hp=6a9dee167feee069eed0d42ba90e3ead546f7602;hpb=c39b94be600e8433a1de54b09d86704066efeb27;p=ffmpeg diff --git a/libavcodec/libtheoraenc.c b/libavcodec/libtheoraenc.c index 6a9dee167fe..0ae03bfb1c4 100644 --- a/libavcodec/libtheoraenc.c +++ b/libavcodec/libtheoraenc.c @@ -336,7 +336,8 @@ static int encode_frame(AVCodecContext* avc_context, uint8_t *outbuf, } memcpy(outbuf, o_packet.packet, o_packet.bytes); - // HACK: does not take codec delay into account (neither does the decoder though) + // HACK: assumes no encoder delay, this is true until libtheora becomes + // multithreaded (which will be disabled unless explictly requested) avc_context->coded_frame->pts = frame->pts; avc_context->coded_frame->key_frame = !(o_packet.granulepos & h->keyframe_mask); @@ -360,7 +361,7 @@ static av_cold int encode_close(AVCodecContext* avc_context) /*! AVCodec struct exposed to libavcodec */ AVCodec libtheora_encoder = { .name = "libtheora", - .type = CODEC_TYPE_VIDEO, + .type = AVMEDIA_TYPE_VIDEO, .id = CODEC_ID_THEORA, .priv_data_size = sizeof(TheoraContext), .init = encode_init,