Skip to content

Commit

Permalink
Traktor: SoundComponent setParameter using string as id.
Browse files Browse the repository at this point in the history
  • Loading branch information
apistol78 committed Feb 29, 2024
1 parent 950e886 commit 5f72a0f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions code/Spray/SoundComponent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,10 @@ void SoundComponent::setPitch(float pitch)
m_handle->setPitch(pitch);
}

void SoundComponent::setParameter(int32_t id, float parameter)
void SoundComponent::setParameter(const std::wstring& id, float parameter)
{
if (m_handle != nullptr)
m_handle->setParameter(id, parameter);
m_handle->setParameter(sound::getParameterHandle(id), parameter);
}

}
2 changes: 1 addition & 1 deletion code/Spray/SoundComponent.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class T_DLLCLASS SoundComponent : public world::IEntityComponent

void setPitch(float pitch);

void setParameter(int32_t id, float parameter);
void setParameter(const std::wstring& id, float parameter);

private:
Ref< sound::ISoundPlayer > m_soundPlayer;
Expand Down

0 comments on commit 5f72a0f

Please sign in to comment.