Commit 72bc5bc0 authored by David Reid's avatar David Reid

Update ma_node_output_bus_set_volume() to allow amplification.

parent c394348d
...@@ -2787,9 +2787,8 @@ static ma_result ma_node_output_bus_set_volume(ma_node_output_bus* pOutputBus, f ...@@ -2787,9 +2787,8 @@ static ma_result ma_node_output_bus_set_volume(ma_node_output_bus* pOutputBus, f
{ {
MA_ASSERT(pOutputBus != NULL); MA_ASSERT(pOutputBus != NULL);
/* Returning an error if outside the 0..1 range for consistency with how it's handled with ma_device_set_master_volume(). */ if (volume < 0.0f) {
if (volume < 0.0f || volume > 1.0f) { volume = 0.0f;
return MA_INVALID_ARGS;
} }
c89atomic_exchange_f32(&pOutputBus->volume, volume); c89atomic_exchange_f32(&pOutputBus->volume, volume);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment