Make D3D9SurfaceImage store data in YUV rather than RGB32




4 years ago
5 months ago


(Reporter: cpearce, Unassigned)


(Blocks: 1 bug)

Firefox Tracking Flags

(Not tracked)


(Whiteboard: gfx-noted)

D3D9SurfaceImage stores its contents in RGB32. This is because I implemented it, and I don't know how to paint the NV12 GPU surfaces we get out of DXVA decoders using a shader or whatever.

Someone who has a clue about graphics would know however.

If we stored D3D9SurfaceImage in YUV and only converted to RGB on paint, we'd half the memory cost of storing video frames when using DXVA.


4 years ago
Priority: -- → P5
Is this an option? I was sort of under the impression that only supported conversion method was using StretchRect.
I looked into this a while back, I believe you're right. Attempting to create a new NV12 texture with DXGI sharing enabled fails, so we can't get the data to the compositor in NV12 format.

It does work if we use the D3D11 DXVA API though, so that's an option for the future.
Whiteboard: gfx-noted
No longer blocks: 778617
Blocks: 1494381
You need to log in before you can comment on or make changes to this bug.