-
-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rendering zero copy HDR AVFrames decoded via Vulkan (NVidia GPU) results in green frames #237
Comments
Try this #239 |
@nowrep thanks I will try it out later this week, was in contact with jbaiter and he told me about this. Was not aware that there is an open pull request for that. I really hope that this fixes the issue. |
Fixes mapping Vulkan P010 frames. Closes haasn#237
@haasn just for information the fix in the pull request "Only adjust bit_shift for DRM P010 frames" Mentioned above, fixed the problem for me. |
I'm reportg this issue occurs with AMD, too - because this bug ticket has been closed, I've opened a new one now only refering to nVidia. #272 |
Hi,
currently I'm working on a Java wrapper for libplacebo to render my real time stream. So far everythin works great and I'm currently testing it on my Windows development machine. My application supports DXVA, D3D11, NVIDEO_CUDA and VULKAN decoding on Windows. As far as I have understood the source code of libplacebo, AVFrames decoded via Vulkan, VAAPI are supporting zero copy rendering via libplacebo (when VkWin32SurfaceCreateInfoKHR is used on Windows for example). However, I encountered a strange problem during testing and I'm not sure if it's a driver issue, ffmpeg issue, or libplacebo issue. I have following results on my Windows machine:
H264 decoding
SOFTWARE decoding + libplacebo rendering = ✓
NVIDEO_CUDA decoding + libplacebo rendering = ✓
DXVA decoding + libplacebo rendering = ✓
D3D11 decoding + libplacebo rendering = ✓
VULKAN decoding + libplacebo rendering = ✓
VULKAN decoding (zero copy)+ libplacebo rendering = ✓
H265 decoding
SOFTWARE decoding + libplacebo rendering = ✓
NVIDEO_CUDA decoding + libplacebo rendering = ✓
DXVA decoding + libplacebo rendering = ✓
D3D11 decoding + libplacebo rendering = ✓
VULKAN decoding + libplacebo rendering = ✓
VULKAN decoding (zero copy)+ libplacebo rendering = ✓
H265 + HDR10 decoding
SOFTWARE decoding + libplacebo rendering = ✓
NVIDEO_CUDA decoding + libplacebo rendering = ✓
DXVA decoding + libplacebo rendering = ✓
D3D11 decoding + libplacebo rendering = ✓
VULKAN decoding + libplacebo rendering = ✓
VULKAN decoding (zero copy)+ libplacebo rendering = ✗ (green frames)
The only difference I do when when using zero copy is this
When I use vulkan decoding without the zero copy via
av_hwframe_transfer_data
and pass this frame to libplacebo everything works fine. But with zero copy I get only greenish frames and via the log I get following warnings, errorsMasking
blit_srcfrom wrapped texture because the corresponding format 'rx10' does not support PL_FMT_CAP_BLITTABLE
I'm not sure if this issue is related but it sounds similar. Here is an example frame to visualize what I mean with "green frame"
normal hdr via VULKAN decoding + libplacebo rendering
This is how I get the AVFrame and this is how I pass it to libplacebo
And in my JNI code I do follwowing
Here is a full example of my JNI wrapper code.
Is this something which is known? If not I can provide more information.
I have a reproducable java rendering project which uses javacv for the ffmepg decoding part and my libplacebo java wrapper for the rendering part. If needed I can upload this example to my GitHub account.
The text was updated successfully, but these errors were encountered: