Skip to content

Commit 7980a30

Browse files
author
Clement Champetier
committed
AudioProperties: added doc to getBitRate method
1 parent e396836 commit 7980a30

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/AvTranscoder/properties/AudioProperties.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ size_t AudioProperties::getBitRate() const
128128
return _codecContext->bit_rate;
129129

130130
// else get computed bit rate from our computation (warning: way to compute bit rate of PCM audio data)
131-
int bitsPerSample = av_get_bits_per_sample(_codecContext->codec_id); // 0 if unknown for the given codec
131+
const int bitsPerSample = av_get_bits_per_sample(_codecContext->codec_id); // 0 if unknown for the given codec
132132
return _codecContext->sample_rate * _codecContext->channels * bitsPerSample;
133133
}
134134

src/AvTranscoder/properties/AudioProperties.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ class AvExport AudioProperties : public StreamProperties
2121

2222
size_t getSampleRate() const;
2323
size_t getNbChannels() const;
24-
size_t getBitRate() const; ///< 0 if unknown
24+
size_t getBitRate() const; ///< in bits/s, 0 if unknown
2525
size_t getNbSamples() const;
2626

2727
size_t getTicksPerFrame() const;

0 commit comments

Comments
 (0)