From 5bddd66437e14f339ae1e8148e04bfd5974f6c3e Mon Sep 17 00:00:00 2001 From: mertalev <101130780+mertalev@users.noreply.github.com> Date: Sat, 11 May 2024 15:41:09 -0400 Subject: [PATCH] tweaks --- server/src/utils/media.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/server/src/utils/media.ts b/server/src/utils/media.ts index 859cd3f4bc..49d30db1e2 100644 --- a/server/src/utils/media.ts +++ b/server/src/utils/media.ts @@ -440,7 +440,7 @@ export class NVENCConfig extends BaseHWConfig { } getBaseInputOptions() { - return ['-hwaccel cuda', '-hwaccel_output_format cuda']; + return ['-hwaccel cuda', '-hwaccel_output_format cuda', ...this.getThreadOptions()]; } getBaseOutputOptions(target: TranscodeTarget, videoStream: VideoStreamInfo, audioStream?: AudioStreamInfo) { @@ -464,10 +464,9 @@ export class NVENCConfig extends BaseHWConfig { getToneMapping() { const colors = this.getColors(); - // https://stackoverflow.com/a/65542002 return [ 'hwupload=derive_device=vulkan', - `libplacebo=tonemapping=${this.config.tonemap}:colorspace=${colors.matrix}:color_primaries=${colors.primaries}:color_trc=${colors.transfer}:format=yuv420p:preset=high_quality:downscaler=lanczos`, + `libplacebo=tonemapping=${this.config.tonemap}:colorspace=${colors.matrix}:color_primaries=${colors.primaries}:color_trc=${colors.transfer}:format=yuv420p:range=pc:downscaler=lanczos:deband=true:deband_iterations=3:deband_radius=8:deband_threshold=6`, 'hwupload=derive_device=cuda', ]; }