# MTCoreAudio Constants and Types Reference

These types and constants are used in MTCoreAudio.framework.

## MTCoreAudioDirection

An MTCoreAudioDirection is used to specify the section of an audio device, either input or output.

    typedef enum MTCoreAudioDirection {
    	kMTCoreAudioDevicePlaybackDirection,
    	kMTCoreAudioDeviceRecordDirection
    } MTCoreAudioDirection;

`kMTCoreAudioDevicePlaybackDirection`
  Specifies the playback (output) section of an audio device.
`kMTCoreAudioDeviceRecordDirection`
  Specifies the record (input) section of an audio device.

## MTCoreAudioStreamSide

An MTCoreAudioStreamSide is used to specify the logical or physical side of a stream when querying or setting stream formats.

    typedef enum MTCoreAudioStreamSide {
    	kMTCoreAudioStreamLogicalSide,
    	kMTCoreAudioStreamPhysicalSide
    } MTCoreAudioStreamSide;

`kMTCoreAudioStreamLogicalSide`
  Specifies the logical side of a stream; that is, the side that interfaces with the application program. Note that for 'lpcm'-format, samples in the logical side are always 32-bit floating point.
`kMTCoreAudioStreamPhysicalSide`
  Specifies the physical side of a stream; that is, the side that interfaces directly with the audio hardware. The physical and logical stream formats may differ significantly, at the discretion of the device driver.

## MTCoreAudioVolumeInfo

An MTCoreAudioVolumeInfo conveys all the useful information about a channel's volume-related settings all at once. It is only returned as the result of a query.

    typedef struct _MTCoreAudioVolumeInfo {
    	Boolean hasVolume;
    	Boolean canSetVolume;
    	Float32 theVolume;
    	Boolean canMute;
    	Boolean isMuted;
    	Boolean canPlayThru;
    	Boolean playThruIsSet;
    } MTCoreAudioVolumeInfo;

`hasVolume`
  `true` if this channel has a volume associated with it, and `false` if it does not.
`canSetVolume`
  `true` if this channel's volume can be changed, and `false` if it is static.
`theVolume`
  The volume of this channel, between `0.0` and `1.0`. Valid only if `hasVolume` is `true`.
`canMute`
  `true` if this channel can be muted.
`isMuted`
  `true` if this channel is currently muted.
`canPlayThru`
  `true` if this channel supports Play-Thru mode, in which the record section is routed directly by the hardware to the playback section.
`playThruIsSet`
  `true` if this channel is currently in Play-Thru mode.

Mike > Mac OS X > MTCoreAudio.framework > MTCoreAudio Constants and Types