forked from ShuriZma/suyu
1
0
Fork 0

Allow >1 cpu threads on video decoding, disable multi-frame decoding

This commit is contained in:
Kelebek1 2023-02-14 18:55:46 +00:00
parent 770a49616d
commit 139b645aa2
1 changed files with 2 additions and 0 deletions

View File

@ -152,6 +152,8 @@ bool Codec::CreateGpuAvDevice() {
void Codec::InitializeAvCodecContext() { void Codec::InitializeAvCodecContext() {
av_codec_ctx = avcodec_alloc_context3(av_codec); av_codec_ctx = avcodec_alloc_context3(av_codec);
av_opt_set(av_codec_ctx->priv_data, "tune", "zerolatency", 0); av_opt_set(av_codec_ctx->priv_data, "tune", "zerolatency", 0);
av_codec_ctx->thread_count = 0;
av_codec_ctx->thread_type &= ~FF_THREAD_FRAME;
} }
void Codec::InitializeGpuDecoder() { void Codec::InitializeGpuDecoder() {