You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
fftools/ffmpeg_dec: remove pointless InputStream.hwaccel_retrieve_data
It is always set to hwaccel_retrieve_data() from ffmpeg_hw.c, so that function can just be called directly instead.
This commit is contained in:
@@ -393,7 +393,6 @@ typedef struct InputStream {
|
|||||||
char *hwaccel_device;
|
char *hwaccel_device;
|
||||||
enum AVPixelFormat hwaccel_output_format;
|
enum AVPixelFormat hwaccel_output_format;
|
||||||
|
|
||||||
int (*hwaccel_retrieve_data)(AVCodecContext *s, AVFrame *frame);
|
|
||||||
enum AVPixelFormat hwaccel_pix_fmt;
|
enum AVPixelFormat hwaccel_pix_fmt;
|
||||||
|
|
||||||
/* stats */
|
/* stats */
|
||||||
|
@@ -272,8 +272,8 @@ static int video_frame_process(InputStream *ist, AVFrame *frame)
|
|||||||
if(ist->top_field_first>=0)
|
if(ist->top_field_first>=0)
|
||||||
frame->flags |= AV_FRAME_FLAG_TOP_FIELD_FIRST;
|
frame->flags |= AV_FRAME_FLAG_TOP_FIELD_FIRST;
|
||||||
|
|
||||||
if (ist->hwaccel_retrieve_data && frame->format == ist->hwaccel_pix_fmt) {
|
if (frame->format == ist->hwaccel_pix_fmt) {
|
||||||
int err = ist->hwaccel_retrieve_data(ist->dec_ctx, frame);
|
int err = hwaccel_retrieve_data(ist->dec_ctx, frame);
|
||||||
if (err < 0)
|
if (err < 0)
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
@@ -561,7 +561,6 @@ static enum AVPixelFormat get_format(AVCodecContext *s, const enum AVPixelFormat
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (config && config->device_type == ist->hwaccel_device_type) {
|
if (config && config->device_type == ist->hwaccel_device_type) {
|
||||||
ist->hwaccel_retrieve_data = hwaccel_retrieve_data;
|
|
||||||
ist->hwaccel_pix_fmt = *p;
|
ist->hwaccel_pix_fmt = *p;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user