0
0

I have an app that can use 4 speakers, where speakers 3 and 4 might sometimes be used for a metronome while stereo output is used for audio tracks. I know under IOS 7 and newer you can use multichannel class-compliant USB audio interfaces like Traktor Audio DJ Mk 2 and address 4 or more output channels. This is what I am trying to get working.

Under Windows and MacOS, I have this working like this (with my Traktor):

...

    Track::SoundSystem->setDriver(0);            //This will be the Traktor

    // Init the soundsystem first to get its preferred values
    result = Track::SoundSystem->init(100, FMOD_INIT_NORMAL, 0);

    // Ask for 4 hardware channels. Does not seem to do anything on any OS
    result = Track::SoundSystem->setHardwareChannels(4);

    // Get the preferred values
    Track::SoundSystem->getSoftwareFormat(&samplerate, &format,
                      &numoutputchannels, &maxinputchannels, &resamplemethod, &bits );

    // Close and reopen, asking for 4 output channels and using everything else that was set up by the first init
    Track::SoundSystem->close();
    Track::SoundSystem->setSoftwareFormat(samplerate, format, 4, maxinputchannels,
                      resamplemethod );

    Track::SoundSystem->init(100, FMOD_INIT_NORMAL, 0);
    ...
    SetSpeakerLevels, etc

On Windows and Mac, this code works and I get my 4 channel output. I use ASIO on WIndows, but I never need to specify it to FMOD.

On IOS, it all runs and I get good return codes, but I never hear channels 3 and 4 on my device.
Any ideas as to what I need to do to get the upper output channels to be heard on IOS?

  • You must to post comments
0
0

Hi Mark,
FMOD in iOS doesnt support enumerating devices and would always return 1 for getNumDrivers.

You’re right that setHardwareChannels does nothing, because that is talking about voices (like a soundcard that has 32 3d hardware voices for example). A 4 channel output stream is not related to this.

We’d possibly have to add device enumeration to the iOS version which is not normally a thing. We’ll discuss it here.

  • Mark Snyder
    Thanks for considering it. This is a key capability for thingas like multitrack know players, so if it is made available I am sure folks will find it useful.
  • Brett Paterson
    we just got a Traktor by the way and are testing with it now
  • Mark Snyder

    Did this ever get unlocked on IOS? I haven’t moved to FMOD 5 mainly because I was using the subsound API to do a metronome. Is FMOD 5 my best bet, or did you allow multichannels on version 4? Thanks

  • Mark Snyder

    Did this ever get unlocked on IOS? I haven’t moved to FMOD 5 mainly because I was using the subsound API to do a metronome. Is FMOD 5 my best bet, or did you allow multichannels on version 4? Thanks

  • Richard Simms

    Hi Mark,

    You are able to use multichannel output on iOS by using the AudioSession API. Have a read of the “Multichannel Output” section of the iOS Getting Started doc.

    https://fmod.com/resources/documentation-api?page=content/generated/platform_ios/basics.html

    Thanks,
    Richard

Showing 1 result
Your Answer

Please first to submit.