decoder/Client: add DecoderCommand/seek virtual methods

This commit is contained in:
Max Kellermann
2016-11-18 08:15:07 +01:00
parent 66fb352cca
commit 47a0f46ce8
24 changed files with 156 additions and 172 deletions

View File

@@ -46,30 +46,30 @@ FakeDecoder::Ready(const AudioFormat audio_format,
}
DecoderCommand
decoder_get_command(gcc_unused DecoderClient &client)
FakeDecoder::GetCommand()
{
return DecoderCommand::NONE;
}
void
decoder_command_finished(gcc_unused DecoderClient &client)
FakeDecoder::CommandFinished()
{
}
SongTime
decoder_seek_time(gcc_unused DecoderClient &client)
FakeDecoder::GetSeekTime()
{
return SongTime();
}
uint64_t
decoder_seek_where_frame(gcc_unused DecoderClient &client)
FakeDecoder::GetSeekFrame()
{
return 1;
}
void
decoder_seek_error(gcc_unused DecoderClient &client)
FakeDecoder::SeekError()
{
}

View File

@@ -34,6 +34,11 @@ struct FakeDecoder final : DecoderClient {
/* virtual methods from DecoderClient */
void Ready(AudioFormat audio_format,
bool seekable, SignedSongTime duration) override;
DecoderCommand GetCommand() override;
void CommandFinished() override;
SongTime GetSeekTime() override;
uint64_t GetSeekFrame() override;
void SeekError() override;
};
#endif