EdgeVisEncoderSDK::ArchiveAudio Class Reference

Detailed Description

A class containing archive audio data.

This object can be passed into the encoder for recording and is passed back out for playback.

Availability

Available in version 6.5 of Encoder SDK. Requires a server version greater than 6.5

#include <ArchiveAudio.h>

Public Member Functions

DB_EDGEVIS_SDK ArchiveAudio (int16_t format, byte_array data, int8_t bits_per_sample, int32_t sample_rate, int64_t timestamp, int8_t channels, int8_t input)
 Creates an ArchiveAudio object. More...
 
DB_EDGEVIS_SDK void Assign (int16_t format, byte_array data, int8_t bits_per_sample, int32_t sample_rate, int64_t timestamp, int8_t channels, int8_t input)
 Assign new audio data to this ArchiveAudio object.
 
DB_EDGEVIS_SDK int16_t GetFormat () const
 Returns the audio data format. More...
 
DB_EDGEVIS_SDK int8_t GetBitsPerSample () const
 Returns the bits per sample. More...
 
DB_EDGEVIS_SDK int32_t GetSampleRate () const
 Returns the bits sample rate of the audio data in Hz. More...
 
DB_EDGEVIS_SDK int64_t GetTimestamp () const
 Returns the timestamp of the audio data The timestamp in in milliseconds since 1970 (Unix time) More...
 
DB_EDGEVIS_SDK int8_t GetChannels () const
 Returns the number of audio channels within the audio data Either 1 or 2 channels. More...
 
DB_EDGEVIS_SDK int8_t GetInput () const
 Returns the video input index this audio is associated with. More...
 
DB_EDGEVIS_SDK byte_array GetData () const
 Returns the audio data. More...
 
DB_EDGEVIS_SDK std::wstring GetSDP () const
 Returns the audio sdp packet. More...
 
DB_EDGEVIS_SDK int64_t GetDuration () const
 Retrieve the duration of this frame. More...
 

Constructor & Destructor Documentation

DB_EDGEVIS_SDK EdgeVisEncoderSDK::ArchiveAudio::ArchiveAudio ( int16_t  format,
byte_array  data,
int8_t  bits_per_sample,
int32_t  sample_rate,
int64_t  timestamp,
int8_t  channels,
int8_t  input 
)

Creates an ArchiveAudio object.

Once created this can be passed into the encoder to be recorded into the archive.

The audio data formats supported are as follows:

Format Value
G.711 μlaw 0x01
PCM 0x02
Parameters
formatThe audio data format the audio data is encoded at
dataThe audio data
bits_per_sampleThe number of bits per sample
sample_rateThe sample rate of the audio in Hz
timestampThe timestamp of the audio as UTC and in milliseconds since 1970
channelsThe number of audio channels. 1 or 2
inputThe video index this audio relates to

Member Function Documentation

DB_EDGEVIS_SDK int16_t EdgeVisEncoderSDK::ArchiveAudio::GetFormat ( ) const

Returns the audio data format.

See table above for supported formats

Returns
The audio data format
DB_EDGEVIS_SDK int8_t EdgeVisEncoderSDK::ArchiveAudio::GetBitsPerSample ( ) const

Returns the bits per sample.

Returns
The audio bits per sample
DB_EDGEVIS_SDK int32_t EdgeVisEncoderSDK::ArchiveAudio::GetSampleRate ( ) const

Returns the bits sample rate of the audio data in Hz.

Returns
The audio sample rate
DB_EDGEVIS_SDK int64_t EdgeVisEncoderSDK::ArchiveAudio::GetTimestamp ( ) const

Returns the timestamp of the audio data The timestamp in in milliseconds since 1970 (Unix time)

Returns
The audio timestamp
DB_EDGEVIS_SDK int8_t EdgeVisEncoderSDK::ArchiveAudio::GetChannels ( ) const

Returns the number of audio channels within the audio data Either 1 or 2 channels.

Returns
The number of audio channels
DB_EDGEVIS_SDK int8_t EdgeVisEncoderSDK::ArchiveAudio::GetInput ( ) const

Returns the video input index this audio is associated with.

Returns
The audio input index
DB_EDGEVIS_SDK byte_array EdgeVisEncoderSDK::ArchiveAudio::GetData ( ) const

Returns the audio data.

Returns
The audio data
DB_EDGEVIS_SDK std::wstring EdgeVisEncoderSDK::ArchiveAudio::GetSDP ( ) const

Returns the audio sdp packet.

Returns
The audio sdp packet
DB_EDGEVIS_SDK int64_t EdgeVisEncoderSDK::ArchiveAudio::GetDuration ( ) const

Retrieve the duration of this frame.

Returns
The duration of the frame in milliseconds

The documentation for this class was generated from the following file: