Firelight Technologies FMOD Studio API

FMOD_OUTPUT_DESCRIPTION

When creating an output, declare one of these and provide the relevant callbacks and name for FMOD to use when it opens and reads a file of this type.

Structure

typedef struct {
  const char *name;
  unsigned int version;
  int polling;
  FMOD_OUTPUT_GETNUMDRIVERS_CALLBACK getnumdrivers;
  FMOD_OUTPUT_GETDRIVERINFO_CALLBACK getdriverinfo;
  FMOD_OUTPUT_INIT_CALLBACK init;
  FMOD_OUTPUT_START_CALLBACK start;
  FMOD_OUTPUT_STOP_CALLBACK stop;
  FMOD_OUTPUT_CLOSE_CALLBACK close;
  FMOD_OUTPUT_UPDATE_CALLBACK update;
  FMOD_OUTPUT_GETHANDLE_CALLBACK gethandle;
  FMOD_OUTPUT_GETPOSITION_CALLBACK getposition;
  FMOD_OUTPUT_LOCK_CALLBACK lock;
  FMOD_OUTPUT_UNLOCK_CALLBACK unlock;
} FMOD_OUTPUT_DESCRIPTION;

Members

name

[in] Name of the output.

version

[in] Plugin writer's version number.

polling

[in] If TRUE (non zero), this tells FMOD to start a thread and call getposition / lock / unlock for feeding data. If 0, the output is probably callback based, so all the plugin needs to do is call readfrommixer to the appropriate pointer.

getnumdrivers

[in] For sound device enumeration. This callback is to give System::getNumDrivers somthing to return.

getdriverinfo

[in] For sound device enumeration. This callback is to give System::getDriverName somthing to return.

init

[in] Initialization function for the output device. This is called from System::init.

start

[in] Initialization function for the output device to start accepting audio data from the FMOD software mixer. This is called from System::init.

stop

[in] Initialization function for the output device to stop accepting audio data from FMOD the software mixer. This is called from System::close.

close

[in] Cleanup / close down function for the output device. This is called from System::close.

update

[in] Update function that is called once a frame by the user. This is called from System::update.

gethandle

[in] This is called from System::getOutputHandle. This is just to return a pointer to the internal system device object that the system may be using.

getposition

[in] This is called from the FMOD software mixer thread if 'polling' = true. This returns a position value in samples so that FMOD knows where and when to fill its buffer.

lock

[in] This is called from the FMOD software mixer thread if 'polling' = true. This function provides a pointer to data that FMOD can write to when software mixing.

unlock

[in] This is called from the FMOD software mixer thread if 'polling' = true. This optional function accepts the data that has been mixed and copies it or does whatever it needs to before sending it to the hardware.

Remarks

Members marked with [in] mean the variable can be written to. The user can set the value.
Members marked with [out] mean the variable is modified by FMOD and is for reading purposes only. Do not change this value.

See Also




Version 1.03.06 Built on Apr 17, 2014