CESNET / UltraGrid

UltraGrid low-latency audio and video network transmission system
http://www.ultragrid.cz
Other
499 stars 53 forks source link

issues with vulkan_sdl2 display #291

Closed alatteri closed 1 year ago

alatteri commented 1 year ago

Hello, I am reporting 2 issues with vulkan_sdl2 display

1) When using vulkan_sdl2 as display surface, it is introducing horizontal pixel tearing. This is not related to Vsync, as this happens even on totally static frames. Switching to sdl surface, the problem does not happen. vulkan_sdl2 is preferred since it can properly display as 10bit surface. See screenshots 1175 and 1176. Zoom in to the jpeg and it becomes very clear.

2) If fullscreen option is not used, vulkan will display as a small portion of the frame even though the input signal and the physical monitor has matching resolutions. See screenshots 1177 and 1178. Input signal and monitor both have native resolutions of 3840x2160. -d sdl displays properly but -d vulkan_sdl2 is shrunken. Now in real use case, I do always use :fs, but I thought I would bring this up as it may be related to the first issue

IMG_1175 IMG_1176 IMG_1177 IMG_1178

alatteri commented 1 year ago

and here is the source PNG that I used to test with.

45_degree_grid_UHD

mpiatka commented 1 year ago

Hello,

thanks for reporting! The pixel tearing was an issue with the R10k shader conversion and should be now fixed.

The second point is not really a bug, but rather an inconsistency in behavior. The vulkan display simply never changes the window size depending on the video. Automatic resizing could be implemented if there is a demand for it.

alatteri commented 1 year ago

No need as :fs is the only behaviour I use. I just didn't know if it was also a symptom of the first bug. Thanks!!

The second point is not really a bug, but rather an inconsistency in behavior. The vulkan display simply never changes the window size depending on the video. Automatic resizing could be implemented if there is a demand for it.

alatteri commented 1 year ago

Sorry to say, that did not fix it.

UltraGrid 1.8+ (tags/continuous rev 417f25f built Feb 6 2023 07:54:12) uv -d vulkan_sdl2:fs --param use-hw-accel IMG_1188

alatteri commented 1 year ago

Normally I do prefer to use x265 with R10K/R12L, but for UHD x265 isn't fast enough so I must use SVT-HEVC or x264 which use pixfmt yuv444p10le.

[2023-02-06 08:06:30] [video dec.] Detected internal codec: Y416 [2023-02-06 08:06:30] [display] Successfully reconfigured display to 3840x2160 @24.00p, codec Y416 [2023-02-06 08:06:30] [lavd] Selected pixel format: yuv444p10le

mpiatka commented 1 year ago

Right, sorry my bad. The issue was actually the same, just in another shader. Today I pushed the fixes for the remaining shaders, so it should hopefully work correctly now.

alatteri commented 1 year ago

Perfect. Thanks!!!