X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Fyop.c;h=57d100c26d715accf7137db5ccd0a6a4dafd4a4f;hb=dc7e07ac1f015117a3abaa9c5f3a594cc7fd0b7a;hp=235e5c9658cac43ea65f516aca739b5cdb4e9139;hpb=148bcae98c7227cfe0aac74841b0888bd456332a;p=ffmpeg diff --git a/libavcodec/yop.c b/libavcodec/yop.c index 235e5c9658c..57d100c26d7 100644 --- a/libavcodec/yop.c +++ b/libavcodec/yop.c @@ -1,5 +1,5 @@ /** - * @file libavcodec/yop.c + * @file * Psygnosis YOP decoder * * Copyright (C) 2010 Mohamed Naufal Basheer @@ -24,6 +24,7 @@ */ #include "libavutil/intreadwrite.h" +#include "libavcore/imgutils.h" #include "avcodec.h" #include "get_bits.h" @@ -84,7 +85,7 @@ static av_cold int yop_decode_init(AVCodecContext *avctx) s->avctx = avctx; if (avctx->width & 1 || avctx->height & 1 || - avcodec_check_dimensions(avctx, avctx->width, avctx->height) < 0) { + av_image_check_size(avctx->width, avctx->height, 0, avctx) < 0) { av_log(avctx, AV_LOG_ERROR, "YOP has invalid dimensions\n"); return -1; } @@ -114,7 +115,7 @@ static av_cold int yop_decode_close(AVCodecContext *avctx) } /** - * Paints a macroblock using the pattern in paint_lut. + * Paint a macroblock using the pattern in paint_lut. * @param s codec context * @param tag the tag that was in the nibble */ @@ -130,7 +131,7 @@ static void yop_paint_block(YopDecContext *s, int tag) } /** - * Copies a previously painted macroblock to the current_block. + * Copy a previously painted macroblock to the current_block. * @param copy_tag the tag that was in the nibble */ static int yop_copy_previous_block(YopDecContext *s, int copy_tag) @@ -155,7 +156,7 @@ static int yop_copy_previous_block(YopDecContext *s, int copy_tag) } /** - * Returns the next nibble in sequence, consuming a new byte on the input + * Return the next nibble in sequence, consuming a new byte on the input * only if necessary. */ static uint8_t yop_get_next_nibble(YopDecContext *s) @@ -173,7 +174,7 @@ static uint8_t yop_get_next_nibble(YopDecContext *s) } /** - * Takes s->dstptr to the next macroblock in sequence. + * Take s->dstptr to the next macroblock in sequence. */ static void yop_next_macroblock(YopDecContext *s) { @@ -249,7 +250,7 @@ static int yop_decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVCodec yop_decoder = { "yop", - CODEC_TYPE_VIDEO, + AVMEDIA_TYPE_VIDEO, CODEC_ID_YOP, sizeof(YopDecContext), yop_decode_init,