Commit f0060718 authored by Max Kellermann's avatar Max Kellermann

decoder/opus: provide time stamps

Call decoder_timestamp(). This is not necessary currently, but will be as soon as we implement seeking.
parent 982ab9e4
...@@ -314,6 +314,11 @@ MPDOpusDecoder::HandleAudio(const ogg_packet &packet) ...@@ -314,6 +314,11 @@ MPDOpusDecoder::HandleAudio(const ogg_packet &packet)
0); 0);
if (cmd != DecoderCommand::NONE) if (cmd != DecoderCommand::NONE)
return cmd; return cmd;
if (packet.granulepos > 0)
decoder_timestamp(decoder,
double(packet.granulepos)
/ opus_sample_rate);
} }
return DecoderCommand::NONE; return DecoderCommand::NONE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment