Tag Parser: TagParser::WaveFormatHeader Class Reference

Tag Parser 12.5.3 C++ library for reading and writing MP4 (iTunes), ID3, Vorbis, Opus, FLAC and Matroska tags

Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
TagParser::WaveFormatHeader Class Reference

The WaveFormatHeader class parses the WAVEFORMATEX structure defined by MS. More...

`#include <waveaudiostream.h>`

## Public Member Functions
constexpr | WaveFormatHeader ()
| Constructs a new WaveFormatHeader.
std::uint64_t | parse (CppUtilities::BinaryReader &reader, std::uint64_t maxSize, Diagnostics &diag)
| Parses the WAVE "fmt " header segment using the specified reader.
MediaFormat | format () const
| Returns the media format denoted by the format tag.
constexpr std::uint32_t | bitrate () const
| Calculates the bitrate from the header data.

## Public Attributes
std::uint64_t | guid1
std::uint64_t | guid2
std::uint16_t | formatTag
std::uint16_t | channelCount
std::uint32_t | sampleRate
std::uint32_t | bytesPerSecond
std::uint16_t | chunkSize
std::uint16_t | bitsPerSample
std::uint32_t | channelMask

## Detailed Description

The WaveFormatHeader class parses the WAVEFORMATEX structure defined by MS.

Definition at line 8 of file waveaudiostream.h.

## Constructor & Destructor Documentation

## ◆ WaveFormatHeader()

TagParser::WaveFormatHeader::WaveFormatHeader | ( |  | ) |
| constexpr

Constructs a new WaveFormatHeader.

Definition at line 30 of file waveaudiostream.h.

## Member Function Documentation

## ◆ bitrate()

std::uint32_t TagParser::WaveFormatHeader::bitrate | ( |  | ) | const
| constexpr

Calculates the bitrate from the header data.

Definition at line 46 of file waveaudiostream.h.

## ◆ format()

MediaFormat TagParser::WaveFormatHeader::format | ( |  | ) | const

Returns the media format denoted by the format tag.

Definition at line 78 of file waveaudiostream.cpp.

## ◆ parse()

std::uint64_t TagParser::WaveFormatHeader::parse | ( | CppUtilities::BinaryReader & | reader,
|  | std::uint64_t | maxSize,
|  | Diagnostics & | diag )

Parses the WAVE "fmt " header segment using the specified reader.

Returns
  Returns the detected media format and the number of bytes read.

Definition at line 25 of file waveaudiostream.cpp.

## Member Data Documentation

## ◆ bitsPerSample

std::uint16_t TagParser::WaveFormatHeader::bitsPerSample

Definition at line 23 of file waveaudiostream.h.

## ◆ bytesPerSecond

std::uint32_t TagParser::WaveFormatHeader::bytesPerSecond

Definition at line 21 of file waveaudiostream.h.

## ◆ channelCount

std::uint16_t TagParser::WaveFormatHeader::channelCount

Definition at line 19 of file waveaudiostream.h.

## ◆ channelMask

std::uint32_t TagParser::WaveFormatHeader::channelMask

Definition at line 24 of file waveaudiostream.h.

## ◆ chunkSize

std::uint16_t TagParser::WaveFormatHeader::chunkSize

Definition at line 22 of file waveaudiostream.h.

## ◆ formatTag

std::uint16_t TagParser::WaveFormatHeader::formatTag

Definition at line 18 of file waveaudiostream.h.

## ◆ guid1

std::uint64_t TagParser::WaveFormatHeader::guid1

Definition at line 16 of file waveaudiostream.h.

## ◆ guid2

std::uint64_t TagParser::WaveFormatHeader::guid2

Definition at line 17 of file waveaudiostream.h.

## ◆ sampleRate

std::uint32_t TagParser::WaveFormatHeader::sampleRate

Definition at line 20 of file waveaudiostream.h.

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

- wav/waveaudiostream.h
- wav/waveaudiostream.cpp