mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2025-10-27 02:41:54 +08:00
ffmpeg: remove ffmpeg_videotoolbox
This was almost completely redundant. The only functionality that's no longer available after this removal is the videotoolbox_pixfmt arg, which has been obsolete for several years.
This commit is contained in:
@@ -2858,12 +2858,7 @@ static enum AVPixelFormat get_format(AVCodecContext *s, const enum AVPixelFormat
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (config) {
|
||||
if (config->device_type != ist->hwaccel_device_type) {
|
||||
// Different hwaccel offered, ignore.
|
||||
continue;
|
||||
}
|
||||
|
||||
if (config && config->device_type == ist->hwaccel_device_type) {
|
||||
ret = hwaccel_decode_init(s);
|
||||
if (ret < 0) {
|
||||
if (ist->hwaccel_id == HWACCEL_GENERIC) {
|
||||
@@ -2876,36 +2871,10 @@ static enum AVPixelFormat get_format(AVCodecContext *s, const enum AVPixelFormat
|
||||
}
|
||||
continue;
|
||||
}
|
||||
} else {
|
||||
const HWAccel *hwaccel = NULL;
|
||||
int i;
|
||||
for (i = 0; hwaccels[i].name; i++) {
|
||||
if (hwaccels[i].pix_fmt == *p) {
|
||||
hwaccel = &hwaccels[i];
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!hwaccel) {
|
||||
// No hwaccel supporting this pixfmt.
|
||||
continue;
|
||||
}
|
||||
if (hwaccel->id != ist->hwaccel_id) {
|
||||
// Does not match requested hwaccel.
|
||||
continue;
|
||||
}
|
||||
|
||||
ret = hwaccel->init(s);
|
||||
if (ret < 0) {
|
||||
av_log(NULL, AV_LOG_FATAL,
|
||||
"%s hwaccel requested for input stream #%d:%d, "
|
||||
"but cannot be initialized.\n", hwaccel->name,
|
||||
ist->file_index, ist->st->index);
|
||||
return AV_PIX_FMT_NONE;
|
||||
}
|
||||
ist->hwaccel_pix_fmt = *p;
|
||||
break;
|
||||
}
|
||||
|
||||
ist->hwaccel_pix_fmt = *p;
|
||||
break;
|
||||
}
|
||||
|
||||
return *p;
|
||||
|
||||
Reference in New Issue
Block a user