Interface IAudioStream
Audio stream
Inherited Members
Namespace: Xabe.FFmpeg
Assembly: Xabe.FFmpeg.dll
Syntax
public interface IAudioStream : IStream
Properties
Bitrate
Bitrate
Declaration
long Bitrate { get; }
Property Value
Type | Description |
---|---|
System.Int64 |
Channels
Channels
Declaration
int Channels { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Default
Default
Declaration
int? Default { get; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Int32> |
Duration
Duration
Declaration
TimeSpan Duration { get; }
Property Value
Type | Description |
---|---|
System.TimeSpan |
Forced
Forced
Declaration
int? Forced { get; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Int32> |
Language
Language
Declaration
string Language { get; }
Property Value
Type | Description |
---|---|
System.String |
SampleRate
Sample Rate
Declaration
int SampleRate { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Methods
ChangeSpeed(Double)
Change speed of media
Declaration
IAudioStream ChangeSpeed(double multiplicator)
Parameters
Type | Name | Description |
---|---|---|
System.Double | multiplicator | Speed value. (0.5 - 2.0). To double the speed set this to 2.0 |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
Exceptions
Type | Condition |
---|---|
System.ArgumentOutOfRangeException | When speed isn't between 0.5 - 2.0. |
CopyStream()
Set stream to copy with orginal codec
Declaration
IAudioStream CopyStream()
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
Reverse()
Reverse audio stream
Declaration
IAudioStream Reverse()
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetBitrate(Int64)
Sets the Bitrate of the AudioStream
Declaration
IAudioStream SetBitrate(long bitRate)
Parameters
Type | Name | Description |
---|---|---|
System.Int64 | bitRate | Bitrate for the AudioStream in bytes |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetBitstreamFilter(String)
Set filter
Declaration
IAudioStream SetBitstreamFilter(string filter)
Parameters
Type | Name | Description |
---|---|---|
System.String | filter | Filter |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetBitstreamFilter(BitstreamFilter)
Set filter
Declaration
IAudioStream SetBitstreamFilter(BitstreamFilter filter)
Parameters
Type | Name | Description |
---|---|---|
BitstreamFilter | filter | Filter |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetChannels(Int32)
Set audio Channels (-ac option)
Declaration
IAudioStream SetChannels(int channels)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | channels | Number of channels to use in the output stream |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetCodec(String)
Set audio codec and bitrate
Declaration
IAudioStream SetCodec(string codec)
Parameters
Type | Name | Description |
---|---|---|
System.String | codec | Audio odec |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetCodec(AudioCodec)
Set audio codec and bitrate
Declaration
IAudioStream SetCodec(AudioCodec codec)
Parameters
Type | Name | Description |
---|---|---|
AudioCodec | codec | Audio odec |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetSampleRate(Int32)
Sets the SampleRate of the AudioStream (-ar option)
Declaration
IAudioStream SetSampleRate(int sampleRate)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | sampleRate | SampleRate in HZ for the Audio Stream |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
SetSeek(Nullable<TimeSpan>)
Seeks in input file to position. (-ss argument)
Declaration
IAudioStream SetSeek(TimeSpan? seek)
Parameters
Type | Name | Description |
---|---|---|
System.Nullable<System.TimeSpan> | seek | Position |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |
Split(TimeSpan, TimeSpan)
Get part of audio
Declaration
IAudioStream Split(TimeSpan startTime, TimeSpan duration)
Parameters
Type | Name | Description |
---|---|---|
System.TimeSpan | startTime | Start point |
System.TimeSpan | duration | Duration of new audio |
Returns
Type | Description |
---|---|
IAudioStream | IAudioStream |