mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-14 03:11:20 +00:00
avcodec/codec_desc: Mark AVRN, TGQ, PhotoCD, VBN as intra-only
Also remove the then redundant assignments of AV_FRAME_FLAG_KEY, AV_PICTURE_TYPE_I. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
2a00d68c09
commit
95937d6316
@ -67,8 +67,6 @@ static int decode_frame(AVCodecContext *avctx, AVFrame *p,
|
||||
|
||||
if ((ret = ff_get_buffer(avctx, p, 0)) < 0)
|
||||
return ret;
|
||||
p->pict_type= AV_PICTURE_TYPE_I;
|
||||
p->flags |= AV_FRAME_FLAG_KEY;
|
||||
|
||||
if(a->interlace) {
|
||||
buf += (true_height - avctx->height)*avctx->width;
|
||||
|
@ -905,7 +905,7 @@ static const AVCodecDescriptor codec_descriptors[] = {
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
.name = "tgq",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("Electronic Arts TGQ video"),
|
||||
.props = AV_CODEC_PROP_LOSSY,
|
||||
.props = AV_CODEC_PROP_INTRA_ONLY | AV_CODEC_PROP_LOSSY,
|
||||
},
|
||||
{
|
||||
.id = AV_CODEC_ID_TQI,
|
||||
@ -1503,6 +1503,7 @@ static const AVCodecDescriptor codec_descriptors[] = {
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
.name = "avrn",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("Avid AVI Codec"),
|
||||
.props = AV_CODEC_PROP_INTRA_ONLY | AV_CODEC_PROP_LOSSLESS,
|
||||
},
|
||||
{
|
||||
.id = AV_CODEC_ID_CPIA,
|
||||
@ -1820,7 +1821,7 @@ static const AVCodecDescriptor codec_descriptors[] = {
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
.name = "photocd",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("Kodak Photo CD"),
|
||||
.props = AV_CODEC_PROP_LOSSY,
|
||||
.props = AV_CODEC_PROP_INTRA_ONLY | AV_CODEC_PROP_LOSSY,
|
||||
},
|
||||
{
|
||||
.id = AV_CODEC_ID_IPU,
|
||||
@ -1869,7 +1870,7 @@ static const AVCodecDescriptor codec_descriptors[] = {
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
.name = "vbn",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("Vizrt Binary Image"),
|
||||
.props = AV_CODEC_PROP_LOSSY,
|
||||
.props = AV_CODEC_PROP_INTRA_ONLY | AV_CODEC_PROP_LOSSY,
|
||||
},
|
||||
{
|
||||
.id = AV_CODEC_ID_JPEGXL,
|
||||
|
@ -237,8 +237,6 @@ static int tgq_decode_frame(AVCodecContext *avctx, AVFrame *frame,
|
||||
|
||||
if ((ret = ff_get_buffer(avctx, frame, 0)) < 0)
|
||||
return ret;
|
||||
frame->flags |= AV_FRAME_FLAG_KEY;
|
||||
frame->pict_type = AV_PICTURE_TYPE_I;
|
||||
|
||||
for (y = 0; y < FFALIGN(avctx->height, 16) >> 4; y++)
|
||||
for (x = 0; x < FFALIGN(avctx->width, 16) >> 4; x++)
|
||||
|
@ -331,9 +331,6 @@ static int photocd_decode_frame(AVCodecContext *avctx, AVFrame *p,
|
||||
if ((ret = ff_thread_get_buffer(avctx, p, 0)) < 0)
|
||||
return ret;
|
||||
|
||||
p->pict_type = AV_PICTURE_TYPE_I;
|
||||
p->flags |= AV_FRAME_FLAG_KEY;
|
||||
|
||||
bytestream2_init(gb, avpkt->data, avpkt->size);
|
||||
|
||||
if (s->resolution < 3) {
|
||||
|
@ -151,9 +151,6 @@ static int vbn_decode_frame(AVCodecContext *avctx,
|
||||
if (ret < 0)
|
||||
goto out;
|
||||
|
||||
frame->pict_type = AV_PICTURE_TYPE_I;
|
||||
frame->flags |= AV_FRAME_FLAG_KEY;
|
||||
|
||||
if (format == VBN_FORMAT_RAW) {
|
||||
uint8_t *flipped = frame->data[0] + frame->linesize[0] * (frame->height - 1);
|
||||
av_image_copy_plane(flipped, -frame->linesize[0], image_buf ? image_buf : gb->buffer, linesize, linesize, frame->height);
|
||||
|
Loading…
Reference in New Issue
Block a user