handle AV_HWDEVICE_TYPE_MMAL not being defined

This commit is contained in:
Isaac Connor 2021-09-27 10:58:16 -04:00
parent 94c1b3445d
commit 202d95fc5a
1 changed files with 2 additions and 0 deletions

View File

@ -66,8 +66,10 @@ static enum AVPixelFormat find_fmt_by_hw_type(const enum AVHWDeviceType type) {
return AV_PIX_FMT_VDPAU; return AV_PIX_FMT_VDPAU;
case AV_HWDEVICE_TYPE_CUDA: case AV_HWDEVICE_TYPE_CUDA:
return AV_PIX_FMT_CUDA; return AV_PIX_FMT_CUDA;
#ifdef AV_HWDEVICE_TYPE_MMAL
case AV_HWDEVICE_TYPE_MMAL: case AV_HWDEVICE_TYPE_MMAL:
return AV_PIX_FMT_MMAL; return AV_PIX_FMT_MMAL;
#endif
case AV_HWDEVICE_TYPE_VIDEOTOOLBOX: case AV_HWDEVICE_TYPE_VIDEOTOOLBOX:
return AV_PIX_FMT_VIDEOTOOLBOX; return AV_PIX_FMT_VIDEOTOOLBOX;
default: default: