mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-22 16:37:31 +09:00
Add VP9 Hardware Decoding with DXVA (Non-MFT), Vista+
Thanks to Maggie (imjustsomeoneiguess) on discord for helping with a lot of this VP9 media code. This is the first browser so far to support VP9 Non MFT
This commit is contained in:
parent
e0fe6706d1
commit
1414824320
18 changed files with 1747 additions and 34 deletions
|
|
@ -314,6 +314,28 @@ FindD3D9BlacklistedDLL() {
|
|||
"media.wmf.disable-d3d9-for-dlls");
|
||||
}
|
||||
|
||||
DXVA2Manager*
|
||||
WMFVideoMFTManager::CreateVP9DXVA(layers::KnowsCompositor* aCompositor,
|
||||
nsACString& aFailureReason, const GUID& aGUID)
|
||||
{
|
||||
DXVA2Manager* result = nullptr;
|
||||
nsCOMPtr<nsIRunnable> event = NS_NewRunnableFunction([&]() {
|
||||
const nsCString& blocked = FindD3D9BlacklistedDLL();
|
||||
if (!blocked.IsEmpty()) {
|
||||
aFailureReason.AssignLiteral("D3D9 DLL is blocklisted");
|
||||
return;
|
||||
}
|
||||
result = DXVA2Manager::CreateD3D9DXVA(aCompositor, aFailureReason, &aGUID);
|
||||
});
|
||||
if (NS_IsMainThread()) {
|
||||
event->Run();
|
||||
} else {
|
||||
nsCOMPtr<nsIThread> mainThread = do_GetMainThread();
|
||||
SyncRunnable::DispatchToThread(mainThread, event);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
class CreateDXVAManagerEvent : public Runnable {
|
||||
public:
|
||||
CreateDXVAManagerEvent(LayersBackend aBackend,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue