summaryrefslogtreecommitdiff
path: root/src/lib/ffmpeg_audio_stream.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/ffmpeg_audio_stream.cc')
-rw-r--r--src/lib/ffmpeg_audio_stream.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/ffmpeg_audio_stream.cc b/src/lib/ffmpeg_audio_stream.cc
index 05e1a3fc8..9400eb60d 100644
--- a/src/lib/ffmpeg_audio_stream.cc
+++ b/src/lib/ffmpeg_audio_stream.cc
@@ -39,7 +39,8 @@ FFmpegAudioStream::FFmpegAudioStream (cxml::ConstNodePtr node, int version)
, AudioStream (
node->number_child<int>("FrameRate"),
node->optional_number_child<Frame>("Length").get_value_or(0),
- AudioMapping (node->node_child("Mapping"), version)
+ AudioMapping(node->node_child("Mapping"), version),
+ node->optional_number_child<int>("BitDepth")
)
{
optional<ContentTime::Type> const f = node->optional_number_child<ContentTime::Type>("FirstAudio");
@@ -63,4 +64,7 @@ FFmpegAudioStream::as_xml (xmlpp::Node* root) const
if (codec_name) {
root->add_child("CodecName")->add_child_text(codec_name.get());
}
+ if (bit_depth()) {
+ root->add_child("BitDepth")->add_child_text(raw_convert<string>(bit_depth().get()));
+ }
}