History

avcodec/h261dec: Don't set framerate multiple times

Just do it once during init.

Andreas Rheinhardt committed 2 years ago

Commit eb0beff1 parent 9933dfe1 file · +2 −2Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/h261dec.c+2−2
@@ -87,6 +87,8 @@ static av_cold int h261_decode_init(AVCodecContext *avctx) · 86 unmodified lines
8787 MpegEncContext *const s = &h->s;
8888 int ret;
8989
90+ avctx->framerate = (AVRational) { 30000, 1001 };
91+
9092 s->private_ctx = &h->common;
9193 // set defaults
9294 ret = ff_mpv_decode_init(s, avctx);
@@ -473,8 +475,6 @@ static int h261_decode_picture_header(H261DecContext *h) · 380 unmodified lines
473475 /* temporal reference */
474476 skip_bits(&s->gb, 5); /* picture timestamp */
475477
476− s->avctx->framerate = (AVRational) { 30000, 1001 };
477−
478478 /* PTYPE starts here */
479479 skip_bits1(&s->gb); /* split screen off */
480480 skip_bits1(&s->gb); /* camera off */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t