Audio
Exports related to audio media.
interface AudioCommandFileArgs
extends AudioCommandFileOptions {
audioRate?: number
clipTime: TimeRange
time: Time
}
interface AudioCommandFileOptions
extends CommandFileOptions {
audioRate?: number
time: Time
}
interface AudioOutputOptions
extends OutputOptions {
audioBitrate?: Value
audioChannels?: number
audioCodec?: string
audioRate?: number
basename?: string
extension?: string
format?: string
options?: ValueRecord
}
interface AudioPreview {
adjustGain: (audible: Instance) => void
buffer: number
bufferClips: (clips: Array<Clip>) => boolean
seconds: number
startContext: () => boolean
startPlaying: (time: Time, clips: Array<Clip>) => boolean
stopContext: () => void
stopPlaying: () => void
}
interface AudioPreviewArgs {
buffer?: number
}
interface AudioProperties {}
interface AudioStart {
duration: number
offset?: number
start: number
}
interface ClientAudio
extends AudioBuffer {}
interface ClippedRawAudioArgs
extends InstanceArgs, ClippedRawAudioObject {
asset: Media
endTrim?: number
gain?: number
loops?: number
muted?: boolean
speed?: number
startTrim?: number
}
interface ClippedRawAudioObject
extends AudibleInstanceObject {
endTrim?: number
gain?: number
loops?: number
muted?: boolean
speed?: number
startTrim?: number
}
interface StorableMashAudio
extends StorableMash, MashAudibleProperties {
accountId?: string
buffer?: number
createdAt?: number
id?: string
label: string
loop?: boolean
/** Determines duration of clip frames. */
quantize?: number
resources?: Array<StorableResource>
source: string
tracks?: Array<TrackObject>
type: string
updatedAt?: number
}
interface StorableRawAudio
extends StorableMedia, AudioProperties {
accountId?: string
createdAt?: number
id?: string
label: string
resources?: Array<StorableResource>
source: string
type: string
updatedAt?: number
}
interface StoredAudio
extends StoredMedia, AudioProperties {
accountId: string
createdAt?: number
deletedAt?: number
id: string
label: string
resources?: Array<StoredResource>
source: string
type: string
updatedAt?: number
userId?: string
}
interface StoredMashAudio
extends StoredMash, MashAudibleProperties {
accountId: string
buffer?: number
createdAt?: number
deletedAt?: number
id: string
label: string
loop?: boolean
/** Determines duration of clip frames. */
quantize?: number
resources?: Array<StoredResource>
source: string
tracks?: Array<TrackObject>
type: string
updatedAt?: number
userId?: string
}
interface StoredRawAudio
extends StoredAudio {
accountId: string
createdAt?: number
deletedAt?: number
id: string
label: string
resources?: Array<StoredResource>
source: string
type: string
updatedAt?: number
userId?: string
}
/** @implements MashCommand */
class AudioMashCommandClass
extends MashCommandClass {
_id: StringOrNot
assetsServerPromise: () => Promise<DataOrError<number>>
audible: boolean
audibleCommandFilters: (args: AudibleCommandFilterArgs, instance: Instance) => Array<CommandFilter>
audioCommandFilters: (clip: Clip, args: AudibleCommandFilterArgs) => Promise<Array<CommandFilter>>
avType?: AudibleType
baseCommandFilePromise: (media: Media, args: FilesCacheArgs, commandFile: CommandFile) => Promise<DataOrError<number>>
clip: () => Clip | undefined
commandFilePromise: (media: Media, args: FilesCacheArgs, commandFile: CommandFile) => Promise<DataOrError<number>>
commandFiles: (instance: Instance | VisibleInstance, cacheArgs: CommandFileArgs) => Array<CommandFile>
commandRawFilePromise: (media: Media, args: FilesCacheArgs, file: CommandFile) => Promise<DataOrError<number>>
commandSvgFilePromise: (media: VisibleMedia, args: FilesCacheArgs, file: CommandFile) => Promise<DataOrError<number>>
duration: number
encodeDescription: () => Promise<EncodeDescription>
filters: () => Promise<Array<CommandFilter>>
id: () => string
inputCommandFiles: () => Promise<Array<CommandFile>>
inputs: () => Promise<CommandInputRecord>
mediaType: MediaType
precodeDescription: () => Promise<PrecodeDescription>
time: Time
visible: boolean
}
/** @implements AudioPreview */
class AudioPreviewClass {
adjustGain: (audible: Instance) => void
buffer: number
bufferClips: (clips: Array<Clip>) => boolean
seconds: number
startContext: () => boolean
startPlaying: (time: Time, clips: Array<Clip>) => boolean
stopContext: () => void
stopPlaying: () => void
}
/** @implements Media */
class ClientRawAudioClass {
accountId: string
api: () => Promise<DataOrError<Api>>
asStored: unknown
boolean: (key: string) => boolean
cacheMedia: (args: MediaCacheArgs) => Promise<DataOrError<number>>
canBeMuted: boolean
changeObject: (propertyId: SignalId, scalar?: Scalar) => ChangeEditObject
changeScalars: (scalars: ScalarsById) => void
changesObject: (scalars: ScalarsById) => ChangePropertiesEditObject
clipObject: (object?: InstanceObject) => ClipObject
constrainedValue: (found: Property, value?: Scalar) => Scalar | undefined
createdAt?: number
deletedAt?: number
duration: number
fetchResource: (resource: Resource) => Promise<DataOrError<true>>
findResource: (types: Strings) => Resource | undefined
frames: (quantize: number) => number
hasIntrinsicSizing?: boolean
hasIntrinsicTiming?: boolean
host: Plugins
id: string
instanceArgs: (object?: InstanceObject) => InstanceArgs
instanceFromObject: (object?: InstanceObject) => Instance
label: string
mediaIds: Strings
number: (key: string) => number
properties: Array<Property>
propertiesOfTarget: (targetId: string) => Array<Property>
propertyFind: (name: string) => Property | undefined
propertyIds: (targetId: string) => Array<SignalId>
resources: Array<Resource>
scalarsRecord: (idOrNames: Strings) => ScalarRecord
setValue: (nameOrId: string, scalar?: Scalar, dontConstrain?: boolean) => void
shouldSelectProperty: (property: Property) => boolean
source: string
string: (key: string) => string
targetId: string
toJSON: () => unknown
tweenValues: (key: string, time: Time, range: TimeRange) => Array<Scalar>
tweens: (key: string) => boolean
type: string
unload: () => void
updatedAt?: number
userId?: string
value: (key: string) => Scalar | undefined
}
/** @implements Instance */
class ClippedClientRawAudioClass {
asset: Media
assetFrames: (quantize: number) => Numbers
assetId: string
assetTime: (masherTime: Time) => Time
boolean: (key: string) => boolean
cacheInstance: (args: InstanceCacheArgs) => Promise<DataOrError<number>>
canBeMuted: boolean
changeObject: (propertyId: SignalId, scalar?: Scalar) => ChangeEditObject
changeScalars: (scalars: ScalarsById) => void
changesObject: (scalars: ScalarsById) => ChangePropertiesEditObject
clip: Clip
constrainedValue: (found: Property, value?: Scalar) => Scalar | undefined
frames: (quantize: number) => number
host: Plugins
id: string
instanceObject: InstanceObject
intrinsicsKnown: (options: IntrinsicOptions) => boolean
isDefault: boolean
mediaIds: Strings
muted: boolean
number: (key: string) => number
properties: Array<Property>
propertiesOfTarget: (targetId: string) => Array<Property>
propertyFind: (name: string) => Property | undefined
propertyIds: (targetId: string) => Array<SignalId>
scalarsById: (targetId: string, time?: Time, timeIsStart?: boolean, useNames?: boolean) => SignalScalarRecord
scalarsRecord: (idOrNames: Strings) => ScalarRecord
setValue: (nameOrId: string, scalar?: Scalar, dontConstrain?: boolean) => void
shouldSelectProperty: (property: Property) => boolean
string: (key: string) => string
targetId: string
toJSON: () => unknown
tweenValues: (key: string, time: Time, range: TimeRange) => Array<Scalar>
tweens: (key: string) => boolean
value: (key: string) => Scalar | undefined
}
/** @implements Instance */
class ClippedRawAudioClass {
asset: Media
assetFrames: (quantize: number) => Numbers
assetId: string
assetTime: (masherTime: Time) => Time
boolean: (key: string) => boolean
cacheInstance: (args: InstanceCacheArgs) => Promise<DataOrError<number>>
canBeMuted: boolean
changeObject: (propertyId: SignalId, scalar?: Scalar) => ChangeEditObject
changeScalars: (scalars: ScalarsById) => void
changesObject: (scalars: ScalarsById) => ChangePropertiesEditObject
clip: Clip
constrainedValue: (found: Property, value?: Scalar) => Scalar | undefined
frames: (quantize: number) => number
host: Plugins
id: string
instanceObject: InstanceObject
intrinsicsKnown: (options: IntrinsicOptions) => boolean
isDefault: boolean
mediaIds: Strings
muted: boolean
number: (key: string) => number
properties: Array<Property>
propertiesOfTarget: (targetId: string) => Array<Property>
propertyFind: (name: string) => Property | undefined
propertyIds: (targetId: string) => Array<SignalId>
scalarsById: (targetId: string, time?: Time, timeIsStart?: boolean, useNames?: boolean) => SignalScalarRecord
scalarsRecord: (idOrNames: Strings) => ScalarRecord
setValue: (nameOrId: string, scalar?: Scalar, dontConstrain?: boolean) => void
shouldSelectProperty: (property: Property) => boolean
string: (key: string) => string
targetId: string
toJSON: () => unknown
tweenValues: (key: string, time: Time, range: TimeRange) => Array<Scalar>
tweens: (key: string) => boolean
value: (key: string) => Scalar | undefined
}
/** @implements Media */
class RawAudioClass {
accountId: string
api: () => Promise<DataOrError<Api>>
asStored: unknown
boolean: (key: string) => boolean
cacheMedia: (args: MediaCacheArgs) => Promise<DataOrError<number>>
canBeMuted: boolean
changeObject: (propertyId: SignalId, scalar?: Scalar) => ChangeEditObject
changeScalars: (scalars: ScalarsById) => void
changesObject: (scalars: ScalarsById) => ChangePropertiesEditObject
clipObject: (object?: InstanceObject) => ClipObject
constrainedValue: (found: Property, value?: Scalar) => Scalar | undefined
createdAt?: number
deletedAt?: number
duration: number
fetchResource: (resource: Resource) => Promise<DataOrError<true>>
findResource: (types: Strings) => Resource | undefined
frames: (quantize: number) => number
hasIntrinsicSizing?: boolean
hasIntrinsicTiming?: boolean
host: Plugins
id: string
instanceArgs: (object?: InstanceObject) => InstanceArgs
instanceFromObject: (object?: InstanceObject) => Instance
label: string
mediaIds: Strings
number: (key: string) => number
properties: Array<Property>
propertiesOfTarget: (targetId: string) => Array<Property>
propertyFind: (name: string) => Property | undefined
propertyIds: (targetId: string) => Array<SignalId>
resources: Array<Resource>
scalarsRecord: (idOrNames: Strings) => ScalarRecord
setValue: (nameOrId: string, scalar?: Scalar, dontConstrain?: boolean) => void
shouldSelectProperty: (property: Property) => boolean
source: string
string: (key: string) => string
targetId: string
toJSON: () => unknown
tweenValues: (key: string, time: Time, range: TimeRange) => Array<Scalar>
tweens: (key: string) => boolean
type: string
unload: () => void
updatedAt?: number
userId?: string
value: (key: string) => Scalar | undefined
}
function AudioMediaMixin<T = Constrained<Media>>(
Base: T
): Mixed<T, Media>