mirror of
https://github.com/antopilo/Nuake.git
synced 2026-09-21 20:08:40 +03:00
Upgraded to C++ 20 & better audio voice management
This commit is contained in:
@@ -56,6 +56,16 @@ public:
|
||||
ComponentTableReset(component.IsPlaying, false);
|
||||
}
|
||||
ImGui::TableNextColumn();
|
||||
{
|
||||
ImGui::Text("Loop");
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ImGui::Checkbox("##Loop", &component.Loop);
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ComponentTableReset(component.Loop, false);
|
||||
}
|
||||
ImGui::TableNextColumn();
|
||||
{
|
||||
ImGui::Text("Volume");
|
||||
ImGui::TableNextColumn();
|
||||
@@ -85,6 +95,51 @@ public:
|
||||
|
||||
ComponentTableReset(component.Pan, 0.0f);
|
||||
}
|
||||
|
||||
ImGui::TableNextColumn();
|
||||
{
|
||||
ImGui::Text("Spatialized");
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ImGui::Checkbox("##Spatialized", &component.Spatialized);
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ComponentTableReset(component.Spatialized, false);
|
||||
}
|
||||
|
||||
if (component.Spatialized)
|
||||
{
|
||||
ImGui::TableNextColumn();
|
||||
{
|
||||
ImGui::Text("Min Distance");
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ImGui::DragFloat("##minDistance", &component.MinDistance, 0.001f, 0.0f);
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ComponentTableReset(component.MinDistance, 1.0f);
|
||||
}
|
||||
ImGui::TableNextColumn();
|
||||
{
|
||||
ImGui::Text("Max Distance");
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ImGui::DragFloat("##maxDistance", &component.MaxDistance, 0.001f, 0.0f);
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ComponentTableReset(component.MaxDistance, 10.0f);
|
||||
}
|
||||
ImGui::TableNextColumn();
|
||||
{
|
||||
ImGui::Text("Attenuation Factor");
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ImGui::DragFloat("##attenuationFactor", &component.AttenuationFactor, 0.001f, 0.0f);
|
||||
ImGui::TableNextColumn();
|
||||
|
||||
ComponentTableReset(component.AttenuationFactor, 1.0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
EndComponentTable();
|
||||
}
|
||||
|
||||
@@ -126,7 +126,7 @@ public:
|
||||
|
||||
uint32_t animIndex = model->GetCurrentAnimationIndex();
|
||||
uint32_t oldAnimIndex = animIndex;
|
||||
auto& animations = model->GetAnimations();
|
||||
auto animations = model->GetAnimations();
|
||||
if (ImGui::BeginCombo("Type", model->GetCurrentAnimation()->GetName().c_str()))
|
||||
{
|
||||
for (int n = 0; n < model->GetAnimationsCount(); n++)
|
||||
|
||||
Reference in New Issue
Block a user