History

avcodec/cbs: Remove unused function parameters

Several cbs-functions had an unused CodedBitstreamContext parameter. This commit removes these.

Andreas Rheinhardt committed 6 years ago

Commit 1bdbc501 parent fc3f5cd23 files · +138 −165Browse files

Showing the changes to libavcodec/vaapi_encode_mpeg2.c (1 of 23 files). Show all

Unified · Split

libavcodec/vaapi_encode_mpeg2.c+4−5
@@ -93,10 +93,9 @@ static int vaapi_encode_mpeg2_add_header(AVCodecContext *avctx, · 92 unmodified lines
9393 CodedBitstreamFragment *frag,
9494 int type, void *header)
9595 {
96− VAAPIEncodeMPEG2Context *priv = avctx->priv_data;
9796 int err;
9897
99− err = ff_cbs_insert_unit_content(priv->cbc, frag, -1, type, header, NULL);
98+ err = ff_cbs_insert_unit_content(frag, -1, type, header, NULL);
10099 if (err < 0) {
101100 av_log(avctx, AV_LOG_ERROR, "Failed to add header: "
102101 "type = %d.\n", type);
@@ -135,7 +134,7 @@ static int vaapi_encode_mpeg2_write_sequence_header(AVCodecContext *avctx, · 32 unmodified lines
135134
136135 err = vaapi_encode_mpeg2_write_fragment(avctx, data, data_len, frag);
137136 fail:
138− ff_cbs_fragment_reset(priv->cbc, frag);
137+ ff_cbs_fragment_reset(frag);
139138 return 0;
140139 }
141140
@@ -159,7 +158,7 @@ static int vaapi_encode_mpeg2_write_picture_header(AVCodecContext *avctx, · 17 unmodified lines
159158
160159 err = vaapi_encode_mpeg2_write_fragment(avctx, data, data_len, frag);
161160 fail:
162− ff_cbs_fragment_reset(priv->cbc, frag);
161+ ff_cbs_fragment_reset(frag);
163162 return 0;
164163 }
165164
@@ -633,7 +632,7 @@ static av_cold int vaapi_encode_mpeg2_close(AVCodecContext *avctx) · 467 unmodified lines
633632 {
634633 VAAPIEncodeMPEG2Context *priv = avctx->priv_data;
635634
636− ff_cbs_fragment_free(priv->cbc, &priv->current_fragment);
635+ ff_cbs_fragment_free(&priv->current_fragment);
637636 ff_cbs_close(&priv->cbc);
638637
639638 return ff_vaapi_encode_close(avctx);

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