mirror of
https://github.com/moonlight-stream/moonlight-qt
synced 2024-11-14 15:37:09 +00:00
Add h264_omx and hevc_omx decoders used by the Vision Five 2
This commit is contained in:
parent
7cf77211b0
commit
fb39ad896e
2 changed files with 10 additions and 0 deletions
|
@ -135,6 +135,14 @@ bool DrmRenderer::prepareDecoderContext(AVCodecContext* context, AVDictionary**
|
|||
// buffers that we get back. We only support NV12 buffers now.
|
||||
av_dict_set_int(options, "pixel_format", AV_PIX_FMT_NV12, 0);
|
||||
|
||||
// This option controls the pixel format for the h264_omx and hevc_omx decoders
|
||||
// used by the JH7110 multimedia stack. This decoder gives us software frames,
|
||||
// so we need a format supported by our DRM dumb buffer code (NV12/NV21/P010).
|
||||
//
|
||||
// https://doc-en.rvspace.org/VisionFive2/DG_Multimedia/JH7110_SDK/h264_omx.html
|
||||
// https://doc-en.rvspace.org/VisionFive2/DG_Multimedia/JH7110_SDK/hevc_omx.html
|
||||
av_dict_set(options, "omx_pix_fmt", "nv12", 0);
|
||||
|
||||
if (m_HwAccelBackend) {
|
||||
context->hw_device_ctx = av_buffer_ref(m_HwContext);
|
||||
}
|
||||
|
|
|
@ -56,11 +56,13 @@ static const struct {
|
|||
{"h264_nvv4l2", 0},
|
||||
{"h264_nvmpi", 0},
|
||||
{"h264_v4l2m2m", 0},
|
||||
{"h264_omx", 0},
|
||||
|
||||
{"hevc_rkmpp", 0},
|
||||
{"hevc_nvv4l2", CAPABILITY_REFERENCE_FRAME_INVALIDATION_HEVC},
|
||||
{"hevc_nvmpi", 0},
|
||||
{"hevc_v4l2m2m", 0},
|
||||
{"hevc_omx", 0},
|
||||
};
|
||||
|
||||
bool FFmpegVideoDecoder::isHardwareAccelerated()
|
||||
|
|
Loading…
Reference in a new issue