1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-12-13 16:08:50 +01:00

[dxvk] Store DXVK options directly with the instance object

This commit is contained in:
Philip Rebohle 2018-11-20 15:50:01 +01:00
parent 7738d2f353
commit 99f6953e89
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
4 changed files with 14 additions and 2 deletions

View File

@ -8,7 +8,7 @@ namespace dxvk {
const Rc<vk::DeviceFn>& vkd, const Rc<vk::DeviceFn>& vkd,
const DxvkDeviceExtensions& extensions, const DxvkDeviceExtensions& extensions,
const DxvkDeviceFeatures& features) const DxvkDeviceFeatures& features)
: m_options (adapter->instance()->config()), : m_options (adapter->instance()->options()),
m_adapter (adapter), m_adapter (adapter),
m_vkd (vkd), m_vkd (vkd),
m_extensions (extensions), m_extensions (extensions),

View File

@ -22,6 +22,8 @@ namespace dxvk {
m_adapters = this->queryAdapters(); m_adapters = this->queryAdapters();
g_vrInstance.initDeviceExtensions(this); g_vrInstance.initDeviceExtensions(this);
m_options = DxvkOptions(m_config);
} }

View File

@ -59,9 +59,18 @@ namespace dxvk {
return m_config; return m_config;
} }
/**
* \brief DXVK options
* \returns DXVK options
*/
const DxvkOptions& options() const {
return m_options;
}
private: private:
Config m_config; Config m_config;
DxvkOptions m_options;
Rc<vk::LibraryFn> m_vkl; Rc<vk::LibraryFn> m_vkl;
Rc<vk::InstanceFn> m_vki; Rc<vk::InstanceFn> m_vki;

View File

@ -5,6 +5,7 @@
namespace dxvk { namespace dxvk {
struct DxvkOptions { struct DxvkOptions {
DxvkOptions() { }
DxvkOptions(const Config& config); DxvkOptions(const Config& config);
/// Allow allocating more memory from /// Allow allocating more memory from