mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-11 19:24:11 +01:00
[d3d11] Reintroduce support for dxgi.maxFrameLatency
This option was previously ignored for some reason.
This commit is contained in:
parent
d50fb7f311
commit
2bae3a5c8b
@ -1736,7 +1736,8 @@ namespace dxvk {
|
|||||||
m_d3d11Device (this, FeatureLevel, FeatureFlags),
|
m_d3d11Device (this, FeatureLevel, FeatureFlags),
|
||||||
m_d3d11Presenter(this, &m_d3d11Device),
|
m_d3d11Presenter(this, &m_d3d11Device),
|
||||||
m_d3d11Interop (this, &m_d3d11Device),
|
m_d3d11Interop (this, &m_d3d11Device),
|
||||||
m_wineFactory (&m_d3d11Presenter) {
|
m_wineFactory (&m_d3d11Presenter),
|
||||||
|
m_frameLatencyCap(m_d3d11Device.GetOptions()->maxFrameLatency) {
|
||||||
for (uint32_t i = 0; i < m_frameEvents.size(); i++)
|
for (uint32_t i = 0; i < m_frameEvents.size(); i++)
|
||||||
m_frameEvents[i] = new DxvkEvent();
|
m_frameEvents[i] = new DxvkEvent();
|
||||||
}
|
}
|
||||||
|
@ -13,6 +13,7 @@ namespace dxvk {
|
|||||||
this->samplerAnisotropy = config.getOption<int32_t>("d3d11.samplerAnisotropy", -1);
|
this->samplerAnisotropy = config.getOption<int32_t>("d3d11.samplerAnisotropy", -1);
|
||||||
this->deferSurfaceCreation = config.getOption<bool>("dxgi.deferSurfaceCreation", false);
|
this->deferSurfaceCreation = config.getOption<bool>("dxgi.deferSurfaceCreation", false);
|
||||||
this->numBackBuffers = config.getOption<int32_t>("dxgi.numBackBuffers", 0);
|
this->numBackBuffers = config.getOption<int32_t>("dxgi.numBackBuffers", 0);
|
||||||
|
this->maxFrameLatency = config.getOption<int32_t>("dxgi.maxFrameLatency", 0);
|
||||||
this->syncInterval = config.getOption<int32_t>("dxgi.syncInterval", -1);
|
this->syncInterval = config.getOption<int32_t>("dxgi.syncInterval", -1);
|
||||||
this->syncMode = D3D11SwapChainSyncMode(config.getOption<int32_t>("dxgi.syncMode", 0));
|
this->syncMode = D3D11SwapChainSyncMode(config.getOption<int32_t>("dxgi.syncMode", 0));
|
||||||
}
|
}
|
||||||
|
@ -68,6 +68,10 @@ namespace dxvk {
|
|||||||
/// passed to IDXGISwapChain::Present.
|
/// passed to IDXGISwapChain::Present.
|
||||||
int32_t syncInterval;
|
int32_t syncInterval;
|
||||||
|
|
||||||
|
/// Override maximum frame latency if the app specifies
|
||||||
|
/// a higher value. May help with frame timing issues.
|
||||||
|
int32_t maxFrameLatency;
|
||||||
|
|
||||||
/// Defer surface creation until first present call. This
|
/// Defer surface creation until first present call. This
|
||||||
/// fixes issues with games that create multiple swap chains
|
/// fixes issues with games that create multiple swap chains
|
||||||
/// for a single window that may interfere with each other.
|
/// for a single window that may interfere with each other.
|
||||||
|
@ -28,9 +28,6 @@ namespace dxvk {
|
|||||||
|
|
||||||
|
|
||||||
DxgiOptions::DxgiOptions(const Config& config) {
|
DxgiOptions::DxgiOptions(const Config& config) {
|
||||||
this->deferSurfaceCreation = config.getOption<bool> ("dxgi.deferSurfaceCreation", false);
|
|
||||||
this->maxFrameLatency = config.getOption<int32_t> ("dxgi.maxFrameLatency", 0);
|
|
||||||
|
|
||||||
// Fetch these as a string representing a hexadecimal number and parse it.
|
// Fetch these as a string representing a hexadecimal number and parse it.
|
||||||
this->customVendorId = parsePciId(config.getOption<std::string>("dxgi.customVendorId"));
|
this->customVendorId = parsePciId(config.getOption<std::string>("dxgi.customVendorId"));
|
||||||
this->customDeviceId = parsePciId(config.getOption<std::string>("dxgi.customDeviceId"));
|
this->customDeviceId = parsePciId(config.getOption<std::string>("dxgi.customDeviceId"));
|
||||||
|
@ -17,15 +17,6 @@ namespace dxvk {
|
|||||||
struct DxgiOptions {
|
struct DxgiOptions {
|
||||||
DxgiOptions(const Config& config);
|
DxgiOptions(const Config& config);
|
||||||
|
|
||||||
/// Defer surface creation until first present call. This
|
|
||||||
/// fixes issues with games that create multiple swap chains
|
|
||||||
/// for a single window that may interfere with each other.
|
|
||||||
bool deferSurfaceCreation;
|
|
||||||
|
|
||||||
/// Override maximum frame latency if the app specifies
|
|
||||||
/// a higher value. May help with frame timing issues.
|
|
||||||
int32_t maxFrameLatency;
|
|
||||||
|
|
||||||
/// Override PCI vendor and device IDs reported to the
|
/// Override PCI vendor and device IDs reported to the
|
||||||
/// application. This may make apps think they are running
|
/// application. This may make apps think they are running
|
||||||
/// on a different GPU than they do and behave differently.
|
/// on a different GPU than they do and behave differently.
|
||||||
|
Loading…
Reference in New Issue
Block a user