diff options
author | Chris Robinson <[email protected]> | 2022-02-07 13:52:51 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2022-02-07 13:53:57 -0800 |
commit | f23c7fe8ba77d4d406d37c60501f961313db7d1a (patch) | |
tree | 569b57749d759f98bf114beac1893c1341dcf702 /alc/context.cpp | |
parent | 1807e083c8a4579979748d062e7b54a19c3b76b9 (diff) |
Avoid a proxy ALfilter object for EAX source properties
Diffstat (limited to 'alc/context.cpp')
-rw-r--r-- | alc/context.cpp | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/alc/context.cpp b/alc/context.cpp index 902e86be..1e363a41 100644 --- a/alc/context.cpp +++ b/alc/context.cpp @@ -467,22 +467,6 @@ void ALCcontext::eax_uninitialize() noexcept eax_is_tried_ = false; eax_fx_slots_.uninitialize(); - eax_al_filter_ = nullptr; -} - -void ALCcontext::eax_initialize_source( - ALsource& al_source) noexcept -try -{ - auto param = EaxSourceInitParam{}; - param.al_context = this; - param.al_filter = eax_al_filter_.get(); - - al_source.eax_initialize(param); -} -catch (...) -{ - eax_log_exception("Failed to initialize a source."); } ALenum ALCcontext::eax_eax_set( @@ -682,7 +666,6 @@ void ALCcontext::eax_initialize() eax_ensure_compatibility(); eax_initialize_filter_gain(); - eax_initialize_filter(); eax_set_defaults(); eax_set_air_absorbtion_hf(); eax_initialize_fx_slots(); @@ -775,16 +758,6 @@ void ALCcontext::eax_set_defaults() noexcept eax_d_ = eax_; } -void ALCcontext::eax_initialize_filter() -{ - eax_al_filter_ = eax_create_al_low_pass_filter(*this); - - if (!eax_al_filter_) - { - eax_fail("Failed to make a low-pass filter."); - } -} - void ALCcontext::eax_dispatch_fx_slot( const EaxEaxCall& eax_call) { @@ -979,7 +952,7 @@ void ALCcontext::eax_initialize_sources() for (auto& source : SourceListEnumerator{mSourceList}) { - eax_initialize_source(source); + source.eax_initialize(this); } } |