Bug 1839315: part 4) Link from `SheetLoadData::mWasAlternate` to spec. r=emilio DONTBUILD
[gecko.git] / gfx / vr / FxROutputHandler.h
blob33e246aae55e0785f75758baa0ec473dc161bcac
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #pragma once
8 struct ID3D11Texture2D;
9 struct IDXGISwapChain;
10 struct ID3D11DeviceContext;
11 struct ID3D11Device;
13 #include <windows.h>
14 #include <d3d11_1.h>
16 #include "mozilla/RefPtr.h"
18 // FxROutputHandler is responsible for managing resources to share a Desktop
19 // browser window with a Firefox Reality VR window.
20 // Note: this object is created on the Compositor thread, but its usage should
21 // only be on the RenderThread.
22 class FxROutputHandler final {
23 public:
24 bool TryInitialize(IDXGISwapChain* aSwapChain, ID3D11Device* aDevice);
25 void UpdateOutput(ID3D11DeviceContext* aCtx);
27 private:
28 RefPtr<IDXGISwapChain> mSwapChain = nullptr;
29 RefPtr<ID3D11Texture2D> mTexCopy = nullptr;