Tag Parser
7.0.1
C++ library for reading and writing MP4 (iTunes), ID3, Vorbis, Opus, FLAC and Matroska tags
wav
waveaudiostream.h
Go to the documentation of this file.
1
#ifndef TAG_PARSER_WAVEAUDIOSTREAM_H
2
#define TAG_PARSER_WAVEAUDIOSTREAM_H
3
4
#include "../abstracttrack.h"
5
6
namespace
TagParser
{
7
8
class
TAG_PARSER_EXPORT
WaveFormatHeader
{
9
public
:
10
WaveFormatHeader
();
11
12
void
parse(IoUtilities::BinaryReader &reader);
13
MediaFormat
format()
const
;
14
uint32
bitrate
()
const
;
15
16
uint16
formatTag
;
17
uint16
channelCount
;
18
uint16
sampleRate
;
19
uint16
bytesPerSecond
;
20
uint16
chunkSize
;
21
uint16
bitsPerSample
;
22
};
23
27
inline
uint32
WaveFormatHeader::bitrate
()
const
28
{
29
return
bitsPerSample
*
sampleRate
*
channelCount
;
30
}
31
32
class
TAG_PARSER_EXPORT
WaveAudioStream
:
public
AbstractTrack
{
33
public
:
34
WaveAudioStream
(std::iostream &stream, uint64 startOffset);
35
~
WaveAudioStream
()
override
;
36
37
TrackType
type()
const override
;
38
39
static
void
addInfo(
const
WaveFormatHeader
&waveHeader,
AbstractTrack
&track);
40
41
protected
:
42
void
internalParseHeader(
Diagnostics
&diag)
override
;
43
44
private
:
45
uint64 m_dataOffset;
46
};
47
48
}
// namespace TagParser
49
50
#endif // TAG_PARSER_WAVEAUDIOSTREAM_H
TagParser::WaveAudioStream
Definition:
waveaudiostream.h:32
TagParser::MediaFormat
Definition:
mediaformat.h:243
TagParser::MatroskaTagIds::TrackSpecific::bitrate
TAG_PARSER_EXPORT const char * bitrate()
The track's bit rate in bits per second.
Definition:
matroskatagid.h:463
TagParser::WaveFormatHeader
Definition:
waveaudiostream.h:8
TagParser::WaveFormatHeader::channelCount
uint16 channelCount
Definition:
waveaudiostream.h:17
TagParser::WaveFormatHeader::bytesPerSecond
uint16 bytesPerSecond
Definition:
waveaudiostream.h:19
TagParser::WaveFormatHeader::chunkSize
uint16 chunkSize
Definition:
waveaudiostream.h:20
TagParser::WaveFormatHeader::sampleRate
uint16 sampleRate
Definition:
waveaudiostream.h:18
TagParser::WaveFormatHeader::bitsPerSample
uint16 bitsPerSample
Definition:
waveaudiostream.h:21
TagParser::WaveFormatHeader::bitrate
uint32 bitrate() const
Calculates the bitrate from the header data.
Definition:
waveaudiostream.h:27
TagParser::WaveFormatHeader::formatTag
uint16 formatTag
Definition:
waveaudiostream.h:16
TagParser::AbstractTrack
Definition:
abstracttrack.h:39
TagParser::TrackType::WaveAudioStream
TagParser
Definition:
aaccodebook.h:9
TAG_PARSER_EXPORT
#define TAG_PARSER_EXPORT
Marks the symbol to be exported by the tagparser library.
TagParser::TrackType
TrackType
Specifies the track type.
Definition:
abstracttrack.h:28
TagParser::Diagnostics
Definition:
diagnostics.h:123
Generated on Tue May 1 2018 14:32:28 for Tag Parser by
1.8.14