Signed-off-by: James Almer <jamrial@gmail.com>tags/n4.4
| @@ -122,7 +122,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, | |||||
| } | } | ||||
| if (avctx->bits_per_coded_sample <= 8) { | if (avctx->bits_per_coded_sample <= 8) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, | const uint8_t *pal = av_packet_get_side_data(avpkt, | ||||
| AV_PKT_DATA_PALETTE, | AV_PKT_DATA_PALETTE, | ||||
| &size); | &size); | ||||
| @@ -3437,11 +3437,11 @@ static int aac_decode_frame(AVCodecContext *avctx, void *data, | |||||
| int buf_consumed; | int buf_consumed; | ||||
| int buf_offset; | int buf_offset; | ||||
| int err; | int err; | ||||
| int new_extradata_size; | |||||
| buffer_size_t new_extradata_size; | |||||
| const uint8_t *new_extradata = av_packet_get_side_data(avpkt, | const uint8_t *new_extradata = av_packet_get_side_data(avpkt, | ||||
| AV_PKT_DATA_NEW_EXTRADATA, | AV_PKT_DATA_NEW_EXTRADATA, | ||||
| &new_extradata_size); | &new_extradata_size); | ||||
| int jp_dualmono_size; | |||||
| buffer_size_t jp_dualmono_size; | |||||
| const uint8_t *jp_dualmono = av_packet_get_side_data(avpkt, | const uint8_t *jp_dualmono = av_packet_get_side_data(avpkt, | ||||
| AV_PKT_DATA_JP_DUALMONO, | AV_PKT_DATA_JP_DUALMONO, | ||||
| &jp_dualmono_size); | &jp_dualmono_size); | ||||
| @@ -103,7 +103,7 @@ static int adx_decode_frame(AVCodecContext *avctx, void *data, | |||||
| const uint8_t *buf = avpkt->data; | const uint8_t *buf = avpkt->data; | ||||
| const uint8_t *buf_end = buf + avpkt->size; | const uint8_t *buf_end = buf + avpkt->size; | ||||
| int num_blocks, ch, ret; | int num_blocks, ch, ret; | ||||
| int new_extradata_size; | |||||
| buffer_size_t new_extradata_size; | |||||
| uint8_t *new_extradata; | uint8_t *new_extradata; | ||||
| new_extradata = av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, | new_extradata = av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, | ||||
| @@ -484,7 +484,7 @@ static int ffat_decode(AVCodecContext *avctx, void *data, | |||||
| if (avctx->codec_id == AV_CODEC_ID_AAC) { | if (avctx->codec_id == AV_CODEC_ID_AAC) { | ||||
| if (!at->extradata_size) { | if (!at->extradata_size) { | ||||
| uint8_t *side_data; | uint8_t *side_data; | ||||
| int side_data_size; | |||||
| buffer_size_t side_data_size; | |||||
| side_data = av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, | side_data = av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, | ||||
| &side_data_size); | &side_data_size); | ||||
| @@ -593,7 +593,7 @@ FF_ENABLE_DEPRECATION_WARNINGS | |||||
| dst->side_data_elems = 0; | dst->side_data_elems = 0; | ||||
| for (i = 0; i < src->side_data_elems; i++) { | for (i = 0; i < src->side_data_elems; i++) { | ||||
| enum AVPacketSideDataType type = src->side_data[i].type; | enum AVPacketSideDataType type = src->side_data[i].type; | ||||
| int size = src->side_data[i].size; | |||||
| buffer_size_t size = src->side_data[i].size; | |||||
| uint8_t *src_data = src->side_data[i].data; | uint8_t *src_data = src->side_data[i].data; | ||||
| uint8_t *dst_data = av_packet_new_side_data(dst, type, size); | uint8_t *dst_data = av_packet_new_side_data(dst, type, size); | ||||
| @@ -800,7 +800,7 @@ void avpriv_packet_list_free(AVPacketList **pkt_buf, AVPacketList **pkt_buf_end) | |||||
| int ff_side_data_set_encoder_stats(AVPacket *pkt, int quality, int64_t *error, int error_count, int pict_type) | int ff_side_data_set_encoder_stats(AVPacket *pkt, int quality, int64_t *error, int error_count, int pict_type) | ||||
| { | { | ||||
| uint8_t *side_data; | uint8_t *side_data; | ||||
| int side_data_size; | |||||
| buffer_size_t side_data_size; | |||||
| int i; | int i; | ||||
| side_data = av_packet_get_side_data(pkt, AV_PKT_DATA_QUALITY_STATS, &side_data_size); | side_data = av_packet_get_side_data(pkt, AV_PKT_DATA_QUALITY_STATS, &side_data_size); | ||||
| @@ -826,7 +826,7 @@ int ff_side_data_set_prft(AVPacket *pkt, int64_t timestamp) | |||||
| { | { | ||||
| AVProducerReferenceTime *prft; | AVProducerReferenceTime *prft; | ||||
| uint8_t *side_data; | uint8_t *side_data; | ||||
| int side_data_size; | |||||
| buffer_size_t side_data_size; | |||||
| side_data = av_packet_get_side_data(pkt, AV_PKT_DATA_PRFT, &side_data_size); | side_data = av_packet_get_side_data(pkt, AV_PKT_DATA_PRFT, &side_data_size); | ||||
| if (!side_data) { | if (!side_data) { | ||||
| @@ -24,7 +24,7 @@ static int cbs_bsf_update_side_data(AVBSFContext *bsf, AVPacket *pkt) | |||||
| CBSBSFContext *ctx = bsf->priv_data; | CBSBSFContext *ctx = bsf->priv_data; | ||||
| CodedBitstreamFragment *frag = &ctx->fragment; | CodedBitstreamFragment *frag = &ctx->fragment; | ||||
| uint8_t *side_data; | uint8_t *side_data; | ||||
| int side_data_size; | |||||
| buffer_size_t side_data_size; | |||||
| int err; | int err; | ||||
| side_data = av_packet_get_side_data(pkt, AV_PKT_DATA_NEW_EXTRADATA, | side_data = av_packet_get_side_data(pkt, AV_PKT_DATA_NEW_EXTRADATA, | ||||
| @@ -477,7 +477,7 @@ static int cinepak_decode_frame(AVCodecContext *avctx, | |||||
| return ret; | return ret; | ||||
| if (s->palette_video) { | if (s->palette_video) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| s->frame->palette_has_changed = 1; | s->frame->palette_has_changed = 1; | ||||
| @@ -66,7 +66,8 @@ typedef struct FramePool { | |||||
| static int apply_param_change(AVCodecContext *avctx, const AVPacket *avpkt) | static int apply_param_change(AVCodecContext *avctx, const AVPacket *avpkt) | ||||
| { | { | ||||
| int size, ret; | |||||
| int ret; | |||||
| buffer_size_t size; | |||||
| const uint8_t *data; | const uint8_t *data; | ||||
| uint32_t flags; | uint32_t flags; | ||||
| int64_t val; | int64_t val; | ||||
| @@ -349,7 +350,7 @@ static inline int decode_simple_internal(AVCodecContext *avctx, AVFrame *frame, | |||||
| got_frame = 0; | got_frame = 0; | ||||
| } else if (avctx->codec->type == AVMEDIA_TYPE_AUDIO) { | } else if (avctx->codec->type == AVMEDIA_TYPE_AUDIO) { | ||||
| uint8_t *side; | uint8_t *side; | ||||
| int side_size; | |||||
| buffer_size_t side_size; | |||||
| uint32_t discard_padding = 0; | uint32_t discard_padding = 0; | ||||
| uint8_t skip_reason = 0; | uint8_t skip_reason = 0; | ||||
| uint8_t discard_reason = 0; | uint8_t discard_reason = 0; | ||||
| @@ -1709,7 +1710,7 @@ int avcodec_default_get_buffer2(AVCodecContext *avctx, AVFrame *frame, int flags | |||||
| static int add_metadata_from_side_data(const AVPacket *avpkt, AVFrame *frame) | static int add_metadata_from_side_data(const AVPacket *avpkt, AVFrame *frame) | ||||
| { | { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *side_metadata; | const uint8_t *side_metadata; | ||||
| AVDictionary **frame_md = &frame->metadata; | AVDictionary **frame_md = &frame->metadata; | ||||
| @@ -1755,7 +1756,7 @@ FF_ENABLE_DEPRECATION_WARNINGS | |||||
| frame->pkt_size = pkt->size; | frame->pkt_size = pkt->size; | ||||
| for (i = 0; i < FF_ARRAY_ELEMS(sd); i++) { | for (i = 0; i < FF_ARRAY_ELEMS(sd); i++) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| uint8_t *packet_sd = av_packet_get_side_data(pkt, sd[i].packet, &size); | uint8_t *packet_sd = av_packet_get_side_data(pkt, sd[i].packet, &size); | ||||
| if (packet_sd) { | if (packet_sd) { | ||||
| AVFrameSideData *frame_sd = av_frame_new_side_data(frame, | AVFrameSideData *frame_sd = av_frame_new_side_data(frame, | ||||
| @@ -461,7 +461,8 @@ static int gdv_decode_frame(AVCodecContext *avctx, void *data, | |||||
| GetByteContext *gb = &gdv->gb; | GetByteContext *gb = &gdv->gb; | ||||
| PutByteContext *pb = &gdv->pb; | PutByteContext *pb = &gdv->pb; | ||||
| AVFrame *frame = data; | AVFrame *frame = data; | ||||
| int ret, i, pal_size; | |||||
| int ret, i; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | ||||
| int compression; | int compression; | ||||
| unsigned flags; | unsigned flags; | ||||
| @@ -371,7 +371,7 @@ static int h264_metadata_handle_display_orientation(AVBSFContext *bsf, | |||||
| H264RawSEIDisplayOrientation *disp = | H264RawSEIDisplayOrientation *disp = | ||||
| &ctx->display_orientation_payload; | &ctx->display_orientation_payload; | ||||
| uint8_t *data; | uint8_t *data; | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| int write = 0; | int write = 0; | ||||
| data = av_packet_get_side_data(pkt, AV_PKT_DATA_DISPLAYMATRIX, &size); | data = av_packet_get_side_data(pkt, AV_PKT_DATA_DISPLAYMATRIX, &size); | ||||
| @@ -975,7 +975,7 @@ static int h264_decode_frame(AVCodecContext *avctx, void *data, | |||||
| return send_next_delayed_frame(h, pict, got_frame, 0); | return send_next_delayed_frame(h, pict, got_frame, 0); | ||||
| if (av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, NULL)) { | if (av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, NULL)) { | ||||
| int side_size; | |||||
| buffer_size_t side_size; | |||||
| uint8_t *side = av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, &side_size); | uint8_t *side = av_packet_get_side_data(avpkt, AV_PKT_DATA_NEW_EXTRADATA, &side_size); | ||||
| ff_h264_decode_extradata(side, side_size, | ff_h264_decode_extradata(side, side_size, | ||||
| &h->ps, &h->is_avc, &h->nal_length_size, | &h->ps, &h->is_avc, &h->nal_length_size, | ||||
| @@ -3303,7 +3303,7 @@ static int hevc_decode_frame(AVCodecContext *avctx, void *data, int *got_output, | |||||
| AVPacket *avpkt) | AVPacket *avpkt) | ||||
| { | { | ||||
| int ret; | int ret; | ||||
| int new_extradata_size; | |||||
| buffer_size_t new_extradata_size; | |||||
| uint8_t *new_extradata; | uint8_t *new_extradata; | ||||
| HEVCContext *s = avctx->priv_data; | HEVCContext *s = avctx->priv_data; | ||||
| @@ -214,7 +214,7 @@ static int idcin_decode_frame(AVCodecContext *avctx, | |||||
| const uint8_t *buf = avpkt->data; | const uint8_t *buf = avpkt->data; | ||||
| int buf_size = avpkt->size; | int buf_size = avpkt->size; | ||||
| IdcinContext *s = avctx->priv_data; | IdcinContext *s = avctx->priv_data; | ||||
| int pal_size; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | ||||
| AVFrame *frame = data; | AVFrame *frame = data; | ||||
| int ret; | int ret; | ||||
| @@ -49,7 +49,8 @@ static int imx_decode_frame(AVCodecContext *avctx, void *data, | |||||
| int *got_frame, AVPacket *avpkt) | int *got_frame, AVPacket *avpkt) | ||||
| { | { | ||||
| SimbiosisIMXContext *imx = avctx->priv_data; | SimbiosisIMXContext *imx = avctx->priv_data; | ||||
| int ret, x, y, pal_size; | |||||
| int ret, x, y; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | ||||
| AVFrame *frame = imx->frame; | AVFrame *frame = imx->frame; | ||||
| GetByteContext gb; | GetByteContext gb; | ||||
| @@ -1317,7 +1317,7 @@ static int ipvideo_decode_frame(AVCodecContext *avctx, | |||||
| return ret; | return ret; | ||||
| if (!s->is_16bpp) { | if (!s->is_16bpp) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| frame->palette_has_changed = 1; | frame->palette_has_changed = 1; | ||||
| @@ -268,7 +268,7 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *got_frame, | |||||
| int i, ret; | int i, ret; | ||||
| int header; | int header; | ||||
| int blocksize; | int blocksize; | ||||
| int pal_size; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | ||||
| bytestream2_init(&ctx->g, avpkt->data, avpkt->size); | bytestream2_init(&ctx->g, avpkt->data, avpkt->size); | ||||
| @@ -221,7 +221,7 @@ static int vpx_decode(AVCodecContext *avctx, | |||||
| struct vpx_image *img, *img_alpha; | struct vpx_image *img, *img_alpha; | ||||
| int ret; | int ret; | ||||
| uint8_t *side_data = NULL; | uint8_t *side_data = NULL; | ||||
| int side_data_size; | |||||
| buffer_size_t side_data_size; | |||||
| ret = decode_frame(avctx, &ctx->decoder, avpkt->data, avpkt->size); | ret = decode_frame(avctx, &ctx->decoder, avpkt->data, avpkt->size); | ||||
| if (ret) | if (ret) | ||||
| @@ -152,7 +152,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| } | } | ||||
| if (avctx->pix_fmt == AV_PIX_FMT_PAL8) { | if (avctx->pix_fmt == AV_PIX_FMT_PAL8) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| @@ -97,7 +97,7 @@ static int msrle_decode_frame(AVCodecContext *avctx, | |||||
| return ret; | return ret; | ||||
| if (avctx->bits_per_coded_sample > 1 && avctx->bits_per_coded_sample <= 8) { | if (avctx->bits_per_coded_sample > 1 && avctx->bits_per_coded_sample <= 8) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| @@ -314,7 +314,7 @@ static int msvideo1_decode_frame(AVCodecContext *avctx, | |||||
| return ret; | return ret; | ||||
| if (s->mode_8bit) { | if (s->mode_8bit) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| @@ -242,7 +242,7 @@ fail: | |||||
| return ret; | return ret; | ||||
| } | } | ||||
| static AVBufferRef *nvdec_decoder_frame_alloc(void *opaque, int size) | |||||
| static AVBufferRef *nvdec_decoder_frame_alloc(void *opaque, buffer_size_t size) | |||||
| { | { | ||||
| NVDECFramePool *pool = opaque; | NVDECFramePool *pool = opaque; | ||||
| AVBufferRef *ret; | AVBufferRef *ret; | ||||
| @@ -283,7 +283,7 @@ static void nvdec_free_dummy(struct AVHWFramesContext *ctx) | |||||
| av_buffer_pool_uninit(&ctx->pool); | av_buffer_pool_uninit(&ctx->pool); | ||||
| } | } | ||||
| static AVBufferRef *nvdec_alloc_dummy(int size) | |||||
| static AVBufferRef *nvdec_alloc_dummy(buffer_size_t size) | |||||
| { | { | ||||
| return av_buffer_create(NULL, 0, NULL, NULL, 0); | return av_buffer_create(NULL, 0, NULL, NULL, 0); | ||||
| } | } | ||||
| @@ -274,7 +274,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| AVFrame * const ref = a->ref; | AVFrame * const ref = a->ref; | ||||
| uint8_t* outdata; | uint8_t* outdata; | ||||
| int delta, intra, ret; | int delta, intra, ret; | ||||
| int pal_size; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | ||||
| if (avpkt->size < 0x86) { | if (avpkt->size < 0x86) { | ||||
| @@ -540,7 +540,7 @@ static int qtrle_decode_frame(AVCodecContext *avctx, | |||||
| } | } | ||||
| if(has_palette) { | if(has_palette) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| @@ -367,7 +367,7 @@ static int raw_decode(AVCodecContext *avctx, void *data, int *got_frame, | |||||
| } | } | ||||
| if (avctx->pix_fmt == AV_PIX_FMT_PAL8) { | if (avctx->pix_fmt == AV_PIX_FMT_PAL8) { | ||||
| int pal_size; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, | ||||
| &pal_size); | &pal_size); | ||||
| int ret; | int ret; | ||||
| @@ -346,7 +346,7 @@ static int rscc_decode_frame(AVCodecContext *avctx, void *data, | |||||
| /* Palette handling */ | /* Palette handling */ | ||||
| if (avctx->pix_fmt == AV_PIX_FMT_PAL8) { | if (avctx->pix_fmt == AV_PIX_FMT_PAL8) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *palette = av_packet_get_side_data(avpkt, | const uint8_t *palette = av_packet_get_side_data(avpkt, | ||||
| AV_PKT_DATA_PALETTE, | AV_PKT_DATA_PALETTE, | ||||
| &size); | &size); | ||||
| @@ -435,7 +435,7 @@ static int smc_decode_frame(AVCodecContext *avctx, | |||||
| const uint8_t *buf = avpkt->data; | const uint8_t *buf = avpkt->data; | ||||
| int buf_size = avpkt->size; | int buf_size = avpkt->size; | ||||
| SmcContext *s = avctx->priv_data; | SmcContext *s = avctx->priv_data; | ||||
| int pal_size; | |||||
| buffer_size_t pal_size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &pal_size); | ||||
| int ret; | int ret; | ||||
| int total_blocks = ((s->avctx->width + 3) / 4) * ((s->avctx->height + 3) / 4); | int total_blocks = ((s->avctx->width + 3) / 4) * ((s->avctx->height + 3) / 4); | ||||
| @@ -58,7 +58,8 @@ static int srt_decode_frame(AVCodecContext *avctx, | |||||
| AVSubtitle *sub = data; | AVSubtitle *sub = data; | ||||
| AVBPrint buffer; | AVBPrint buffer; | ||||
| int x1 = -1, y1 = -1, x2 = -1, y2 = -1; | int x1 = -1, y1 = -1, x2 = -1, y2 = -1; | ||||
| int size, ret; | |||||
| int ret; | |||||
| buffer_size_t size; | |||||
| const uint8_t *p = av_packet_get_side_data(avpkt, AV_PKT_DATA_SUBTITLE_POSITION, &size); | const uint8_t *p = av_packet_get_side_data(avpkt, AV_PKT_DATA_SUBTITLE_POSITION, &size); | ||||
| FFASSDecoderContext *s = avctx->priv_data; | FFASSDecoderContext *s = avctx->priv_data; | ||||
| @@ -72,7 +72,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame, | |||||
| int palette_has_changed = 0; | int palette_has_changed = 0; | ||||
| if (c->avctx->pix_fmt == AV_PIX_FMT_PAL8) { | if (c->avctx->pix_fmt == AV_PIX_FMT_PAL8) { | ||||
| int size; | |||||
| buffer_size_t size; | |||||
| const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | const uint8_t *pal = av_packet_get_side_data(avpkt, AV_PKT_DATA_PALETTE, &size); | ||||
| if (pal && size == AVPALETTE_SIZE) { | if (pal && size == AVPALETTE_SIZE) { | ||||
| @@ -21,6 +21,7 @@ | |||||
| #include "libavutil/avassert.h" | #include "libavutil/avassert.h" | ||||
| #include "libavutil/common.h" | #include "libavutil/common.h" | ||||
| #include "libavutil/internal.h" | |||||
| #include "libavutil/log.h" | #include "libavutil/log.h" | ||||
| #include "libavutil/pixdesc.h" | #include "libavutil/pixdesc.h" | ||||
| @@ -2234,7 +2235,7 @@ static void vaapi_encode_free_output_buffer(void *opaque, | |||||
| } | } | ||||
| static AVBufferRef *vaapi_encode_alloc_output_buffer(void *opaque, | static AVBufferRef *vaapi_encode_alloc_output_buffer(void *opaque, | ||||
| int size) | |||||
| buffer_size_t size) | |||||
| { | { | ||||
| AVCodecContext *avctx = opaque; | AVCodecContext *avctx = opaque; | ||||
| VAAPIEncodeContext *ctx = avctx->priv_data; | VAAPIEncodeContext *ctx = avctx->priv_data; | ||||