Commit f3b4a922 authored by Vittorio Giovara's avatar Vittorio Giovara

libtheoraenc: Keep coded_frame.key_frame a write-only variable

parent d6006dd9
......@@ -349,7 +349,7 @@ static int encode_frame(AVCodecContext* avc_context, AVPacket *pkt,
// multithreaded (which will be disabled unless explicitly requested)
pkt->pts = pkt->dts = frame->pts;
avc_context->coded_frame->key_frame = !(o_packet.granulepos & h->keyframe_mask);
if (avc_context->coded_frame->key_frame)
if (!(o_packet.granulepos & h->keyframe_mask))
pkt->flags |= AV_PKT_FLAG_KEY;
*got_packet = 1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment