Closed Bug 1742229 Opened 2 years ago Closed 2 years ago

Firefox doesn't use modifiers for YUV surfaces

Categories

(Core :: Widget: Gtk, defect, P2)

Firefox 94
x86_64
Linux
defect

Tracking

()

RESOLVED FIXED
96 Branch
Tracking Status
firefox96 --- fixed

People

(Reporter: elfarto, Assigned: elfarto)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 1 obsolete file)

Attached patch use-modifiers-for-yuv.patch (obsolete) — Splinter Review

Steps to reproduce:

I'm attempting to get Firefox working with my new VA-API implementation that uses NVIDIA's NVDecode.

Actual results:

I just got a green box instead of the video.

Expected results:

The video should have shown.

I managed to fix the issue by getting Firefox to set the modifiers for YUV surfaces aswell as for RGBA surfaces. I've attached a patch.

Component: Untriaged → Widget: Gtk
Product: Firefox → Core
OS: Unspecified → Linux
Hardware: Unspecified → x86_64

Hello Stephen,
thanks for the patch, do you mind to use phabricator to submit it?
https://moz-conduit.readthedocs.io/en/latest/phabricator-user.html
Thanks.

Flags: needinfo?(elfarto)
Priority: -- → P2

Firefox is not setting the modifiers for YUV surfaces causing the import of surfaces that require them to fail.

Assignee: nobody → elfarto
Flags: needinfo?(elfarto)
Attachment #9251739 - Attachment is obsolete: true
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true

Stephen, the patch is in 'draft / Changes Planned' state. Is that correct?
Thanks.

Flags: needinfo?(elfarto)

(In reply to Martin Stránský [:stransky] (ni? me) from comment #3)

Stephen, the patch is in 'draft / Changes Planned' state. Is that correct?
Thanks.

No the patch is complete, but I'm not certain what I need to do to get it out of that state.

Flags: needinfo?(elfarto)
Attachment #9251861 - Attachment description: WIP: Bug 1742229 - Firefox doesn't use modifiers for YUV surfaces → Bug 1742229 - Firefox doesn't use modifiers for YUV surfaces

Please try to submit the patch again. Remove WIP: prefix and add r?stransky at the end. That should move the patch to review queue.
Thanks.

Flags: needinfo?(elfarto)
Attachment #9251861 - Attachment description: Bug 1742229 - Firefox doesn't use modifiers for YUV surfaces → Bug 1742229 - Firefox doesn't use modifiers for YUV surfaces r?stransky

Done

Flags: needinfo?(elfarto)

Great, Thanks!

Pushed by stransky@redhat.com:
https://hg.mozilla.org/integration/autoland/rev/9dd4b8501129
Firefox doesn't use modifiers for YUV surfaces r=stransky

Stephen,

do you mind to provide any details how VA-API with NVIDIA drivers can be used? Right now we're missing any info how to set up (and I don't have any NVIDIA hardware):

https://fedoraproject.org/wiki/Firefox_Hardware_acceleration#Video_decoding_on_NVIDIA

Thanks.

To use VA-API with NVIDIA with DMA-BUF support, you need the new VA-API implementation I've been developing, not the VDPAU one that's currently available. I haven't released the source code for this yet, but I do plan to.

I'm somewhat hesitant to do so at the moment as Firefox is really the only use case for it (most other apps will just use NVDEC directly), and there are other blockers, such as needing to completely disable the sandbox for it to run (it needs cuda and a gstreamer lib).

However, once there's a version of Firefox available that only needs config/environment variables to use it, rather than a custom build that'll make it much easier to test and will make a good point to release the code.

I see, Thanks for the info.

Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch

It would be interesting if this works on Nvidia as well: https://www.phoronix.com/scan.php?page=news_item&px=VA-API-On-Vulkan-Video-Hacks

QA Whiteboard: [qa-96b-p2]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: