I’ve taken the ScriptUsageVideoPlayback and modified it slightly to target a specific bus instead of the master channel group. Below is what I’m currently doing:
if (!mChannel.hasHandle() && mTotalSamplesWritten > mAdjustedLatencySamples)
{
Bus bus = FMODUnity.RuntimeManager.GetBus(fmodBusPath);
AudioManager.CheckResult(bus.lockChannelGroup());
AudioManager.CheckResult(RuntimeManager.StudioSystem.flushCommands());
AudioManager.CheckResult(bus.getChannelGroup(out FMOD.ChannelGroup group));
AudioManager.CheckResult(RuntimeManager.CoreSystem.playSound(mSound, group, false, out mChannel));
AudioManager.CheckResult(mChannel.setVolume(_volume));
AudioManager.CheckResult(bus.unlockChannelGroup());
}
The audio still plays, just like it did with the master channel group but it does not appear to target the bus. When profiling the bus does not show any audio coming through and no amount of volume manipulation has an impact.
I’m not entirely sure what I’m doing wrong above or what else I can dig into to try to figure out why it doesn’t appear to work.
The bus and group above do return as valid, I just removed the checks for clarity.
