Class AudioCaptureBase
Definition
- Namespace:
- Tizen.Multimedia
- Assembly:
- Tizen.Multimedia.AudioIO.dll
Provides the ability to directly manage the system audio input devices.
C#Copypublic abstract class AudioCaptureBase : IDisposable
- Inheritance
-
objectAudioCaptureBase
- Derived
- Implements
-
System.IDisposable
Fields
Declaration
C#Copypublic static readonly int MaxSampleRate
Field Value
Type | Description |
---|---|
int |
See Also
Declaration
C#Copypublic static readonly int MinSampleRate
Field Value
Type | Description |
---|---|
int |
See Also
Properties
Declaration
C#Copypublic AudioChannel Channel { get; }
Property Value
Type | Description |
---|---|
AudioChannel |
Declaration
C#Copypublic int SampleRate { get; }
Property Value
Type | Description |
---|---|
int |
Declaration
C#Copypublic AudioSampleType SampleType { get; }
Property Value
Type | Description |
---|---|
AudioSampleType |
Declaration
C#Copypublic double Volume { get; set; }
Property Value
Type | Description |
---|---|
double | The default value is 1.0. |
Remarks
If the value is less than 1.0, the loudness of recorded data will be decreased.
If the value is greater than 1.0, the loudness of recorded data will be increased.
Note that the volume can be clipped if the value is greater than 1.0 and the loudness of original recorded data is high enough.
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The AudioCapture has already been disposed. |
Methods
ApplyStreamPolicy(AudioStreamPolicy)
Sets the sound stream information to the audio input.
Declaration
C#Copypublic void ApplyStreamPolicy(AudioStreamPolicy streamPolicy)
Parameters
Type | Name | Description |
---|---|---|
AudioStreamPolicy | streamPolicy | The AudioStreamPolicy to apply for the AudioCapture. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ObjectDisposedException |
|
System.NotSupportedException |
|
System.ArgumentException | Not able to retrieve information from |
Declaration
C#Copypublic void Dispose()
Declaration
C#Copyprotected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
bool | disposing | true to release both managed and unmanaged resources; false to release only unmanaged resources. |
Declaration
C#Copyprotected ~AudioCaptureBase()
Declaration
C#Copypublic void Flush()
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | The current state is Idle. |
System.ObjectDisposedException | The AudioCaptureBase has already been disposed of. |
Declaration
C#Copypublic int GetBufferSize()
Returns
Type | Description |
---|---|
int | The buffer size of audio data captured. |
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The AudioCaptureBase has already been disposed of. |
Declaration
C#Copypublic void Pause()
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | The current state is Idle. |
System.ObjectDisposedException | The AudioCaptureBase has already been disposed of. |
See Also
Prepare()
Prepares the AudioCapture for reading audio data by starting buffering of audio data from the device.
Declaration
C#Copypublic void Prepare()
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | Operation failed due to an internal error. |
System.ObjectDisposedException | The AudioCaptureBase has already been disposed of. |
See Also
Declaration
C#Copypublic void Resume()
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | The current state is Idle. |
System.ObjectDisposedException | The AudioCaptureBase has already been disposed of. |
See Also
Declaration
C#Copypublic void Unprepare()
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | Operation failed due to an internal error. |
System.ObjectDisposedException | The AudioCaptureBase has already been disposed of. |
See Also
Events
Declaration
C#Copypublic event EventHandler<AudioIOStateChangedEventArgs> StateChanged
Event Type
Type | Description |
---|---|
System.EventHandler<TEventArgs><AudioIOStateChangedEventArgs> |