IntdashAudioDecoder
open class IntdashAudioDecoder : NSObject, AACDecoderDelegate, OpusDecoderDelegate
音声用のデコーダークラス。
-
デコードに使用する音声のコーデック。
Declaration
Swift
public private(set) var codec: IntdashAudioCodec { get } -
デコード用オプション。
Declaration
Swift
public private(set) var option: IntdashAudioDecoderOption { get } -
オブジェクトを識別するためのタグ。
Declaration
Swift
public var tag: Int -
このクラスが使用する Delegate。
Declaration
Swift
public weak var delegate: IntdashAudioDecoderDelegate? -
ログレベル。
Declaration
Swift
public var logLevel: IntdashMediaLogLevel { get set } -
AAC用デコーダー。
Declaration
Swift
public var aacDecoder: AACDecoder? -
Opus用デコーダー。
Declaration
Swift
public var opusDecoder: OpusDecoder? -
IntdashAudioDecoder を生成します。
Declaration
Swift
public init(codec: IntdashAudioCodec, option: IntdashAudioDecoderOption = IntdashAudioDecoderOption())Parameters
codec使用するコーデック。
optionデコーダー用のオプション。
-
デコードするデータを渡します。
Declaration
Swift
public func append(sampleData: Data, timestamp: TimeInterval = -1)Parameters
sampleDataエンコードされた音声サンプル。 本フィールドに渡すべきデータの形式は、使用するコーデックにより異なります。
timestampsampleDataに対応するタイムスタンプ。 デコードが成功した際に、デコードされた音声サンプルとともにdelegateに渡されます。 -
デコーダーをリセットします。
Declaration
Swift
public func reset() -
デコーダーをリセットします。
Declaration
Swift
public func reset(option: IntdashAudioDecoderOption)Parameters
optionデコーダー用オプション。
-
割り当てを解除します。
Declaration
Swift
public func dispose()
-
delegate のメソッド
AACDecoderDelegate.decodedSamples(_:sampleData:timestamp:)を呼び出します。Declaration
Swift
public func decodedSamples(_ decoder: AACDecoder, sampleData: Data, timestamp: TimeInterval) -
delegate のメソッド
AACDecoderDelegate.decodeFailedSampleData(_:error:)を呼び出します。Declaration
Swift
public func decodeFailedSampleData(_ decoder: AACDecoder, error: NSError)
-
delegate のメソッド
OpusDecoderDelegate.decodedSamples(_:sampleData:timestamp:)を呼び出します。Declaration
Swift
public func decodedSamples(_ decoder: OpusDecoder, sampleData: Data, timestamp: TimeInterval) -
delegate のメソッド
OpusDecoderDelegate.decodeFailedSampleData(_:error:)を呼び出します。Declaration
Swift
public func decodeFailedSampleData(_ decoder: OpusDecoder, error: NSError) -
AAC用のデコーダークラス。
See moreDeclaration
Swift
public class AACDecoder : NSObject -
Opus用のデコーダークラス。
See moreDeclaration
Swift
public class OpusDecoder : NSObject
IntdashAudioDecoder Class Reference