INTERACT FORUM

Linux => JRiver Media Center 31 for Linux => Topic started by: mattkhan on November 19, 2023, 09:46:39 am

Title: tonemapping peak detect not working on linux
Post by: mattkhan on November 19, 2023, 09:46:39 am
as per https://yabb.jriver.com/interact/index.php/topic,135621.msg952870.html#msg952870

any clues in the attached log?
Title: Re: tonemapping peak detect not working on linux
Post by: Hendrik on November 19, 2023, 12:05:23 pm
Well it is failing on something
Code: [Select]
0007360: 140059508000448: Playback: CJRVideoRendererCore::Thread: Resized swapchain to 246x138, refresh: 60, sync interval: 166659
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Polar radius 49.518837 exceeds implementation capacity!
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Failed dispatching scaler.. disabling
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Attempting to modify a failed shader!
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Attempting to modify a failed shader!
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Failed creating HDR peak detection shader.. disabling
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Attempting to modify a failed shader!
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Attempting to modify a failed shader!
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Attempting to modify a failed shader!
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Dithering to 8 bit depth
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Trying to dispatch a failed shader.
0007526: 140059508000448: Playback: CJRVideoRendererCore::PLLog: Failed rendering image!
0007526: 140059508000448: Playback: CJRVideoRendererCore::Render: Rendering Frame failed

From the error, I'm guessing you are using a polar downscaler (Jinc), and its failing on a too extreme downscaling factor 3840x2160 -> 246x138 (action window?)
I have not seen that error myself, but I'll investigate.

Maybe try an ortho downscaler? (literally any other then Jinc)

If its what I think it is, I might have to swap downscaling algorithm to something else on extreme downscaling ratios. But other then Action Window, there is no reasonable expectation of such high downscaling going on.

Edit:
Oh I realized why I havent seen this error. On newer GPUs Jinc uses Compute Shaders which has different limits.
Title: Re: tonemapping peak detect not working on linux
Post by: mattkhan on November 19, 2023, 12:25:36 pm
It did open directly into the overview screen, I will get a new log with it going direct to display view to see if that changes anything
Title: Re: tonemapping peak detect not working on linux
Post by: mattkhan on November 19, 2023, 02:01:02 pm
in fact it does if it opens into a larger window, log attached

for some reason I can't fathom, this MC instance doesn't open display view automatically. I can't find a config option for that either

anyway I guess it's a rather obscure bug, if playback starts in a too small window then HDR peak detection is borked.

Title: Re: tonemapping peak detect not working on linux
Post by: JimH on November 19, 2023, 02:13:47 pm
Should be set in Options > General > Behavior.
Title: Re: tonemapping peak detect not working on linux
Post by: mattkhan on November 19, 2023, 02:57:54 pm
"Jump on play (Video)" is set to display view

I think the issue here is that this test clip is not in the library and "File > Open Media File" is ignoring that option whereas playing a library item does respect it
Title: Re: tonemapping peak detect not working on linux
Post by: mattkhan on November 19, 2023, 03:01:15 pm
actually I'm wrong, you have to use "Display view (even in playing now)" and then it works. I don't understand why there are 2 options for what seems like same behaviour mind you
Title: Re: tonemapping peak detect not working on linux
Post by: Hendrik on November 19, 2023, 03:02:24 pm
anyway I guess it's a rather obscure bug, if playback starts in a too small window then HDR peak detection is borked.

I'll fix it by swapping out the scaling algorithm for downscaling on factors below 1/8th or something, which should be close to its limit.
You could confirm this by swapping downscaling to Lanczos or literally anything thats not Jinc.
Title: Re: tonemapping peak detect not working on linux
Post by: mattkhan on November 20, 2023, 02:37:26 am
yes that fixes it