summaryrefslogtreecommitdiff
path: root/apps/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins')
-rw-r--r--apps/plugins/codecflac.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/apps/plugins/codecflac.c b/apps/plugins/codecflac.c
index fbbf68924f..1cc95b3f2d 100644
--- a/apps/plugins/codecflac.c
+++ b/apps/plugins/codecflac.c
@@ -223,6 +223,18 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parm)
223 if (ci->stop_codec || ci->reload_codec) { 223 if (ci->stop_codec || ci->reload_codec) {
224 break; 224 break;
225 } 225 }
226
227 if (ci->seek_time) {
228 int sample_loc;
229
230 sample_loc = ci->seek_time/1000 * ci->id3->frequency;
231 if (FLAC__seekable_stream_decoder_seek_absolute(flacDecoder,sample_loc)) {
232 samplesdone=sample_loc;
233 ci->set_elapsed(samplesdone/(ci->id3->frequency/1000));
234 }
235 ci->seek_time = 0;
236 }
237
226 FLAC__seekable_stream_decoder_process_single(flacDecoder); 238 FLAC__seekable_stream_decoder_process_single(flacDecoder);
227 } 239 }
228 240