зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1298324 - Change D3D11DeviceStatus to a union. r=dvander
MozReview-Commit-ID: LCy2NSch39X
This commit is contained in:
Родитель
f795d19994
Коммит
4656974491
|
@ -170,8 +170,12 @@ GPUParent::RecvGetDeviceStatus(GPUDeviceData* aOut)
|
|||
|
||||
#if defined(XP_WIN)
|
||||
if (DeviceManagerDx* dm = DeviceManagerDx::Get()) {
|
||||
dm->ExportDeviceInfo(&aOut->d3d11Device());
|
||||
D3D11DeviceStatus deviceStatus;
|
||||
dm->ExportDeviceInfo(&deviceStatus);
|
||||
aOut->gpuDevice() = deviceStatus;
|
||||
}
|
||||
#else
|
||||
aOut->gpuDevice() = null_t();
|
||||
#endif
|
||||
|
||||
return true;
|
||||
|
|
|
@ -54,12 +54,18 @@ union FeatureChange
|
|||
FeatureFailure;
|
||||
};
|
||||
|
||||
union GPUDeviceStatus
|
||||
{
|
||||
null_t;
|
||||
D3D11DeviceStatus;
|
||||
};
|
||||
|
||||
struct GPUDeviceData
|
||||
{
|
||||
FeatureChange d3d11Compositing;
|
||||
FeatureChange d3d9Compositing;
|
||||
FeatureChange oglCompositing;
|
||||
D3D11DeviceStatus d3d11Device;
|
||||
GPUDeviceStatus gpuDevice;
|
||||
};
|
||||
|
||||
union GfxVarValue
|
||||
|
|
|
@ -2004,7 +2004,7 @@ gfxWindowsPlatform::ImportGPUDeviceData(const mozilla::gfx::GPUDeviceData& aData
|
|||
|
||||
DeviceManagerDx* dm = DeviceManagerDx::Get();
|
||||
if (gfxConfig::IsEnabled(Feature::D3D11_COMPOSITING)) {
|
||||
dm->ImportDeviceInfo(aData.d3d11Device());
|
||||
dm->ImportDeviceInfo(aData.d3d11Device().get_D3D11DeviceStatus());
|
||||
} else {
|
||||
// There should be no devices, so this just takes away the device status.
|
||||
dm->ResetDevices();
|
||||
|
|
Загрузка…
Ссылка в новой задаче