annotate base/ProgressReporter.h @ 1288:5ef9b4d4bbdb 3.0-integration

Filter out Xing/LAME info frames, rather than letting them go to the mp3 decoder as if they were audio frames. Fixes the 1152-sample zero pad at start of some decoded mp3 files (distinct from decoder delay). The logic here is based on the madplay code.
author Chris Cannam
date Thu, 24 Nov 2016 13:32:04 +0000
parents beb2948baa77
children 1dc64d3d323c
rev   line source
Chris@392 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
Chris@392 2
Chris@392 3 /*
Chris@392 4 Sonic Visualiser
Chris@392 5 An audio file viewer and annotation editor.
Chris@392 6 Centre for Digital Music, Queen Mary, University of London.
Chris@392 7 This file copyright 2007-2008 QMUL.
Chris@392 8
Chris@392 9 This program is free software; you can redistribute it and/or
Chris@392 10 modify it under the terms of the GNU General Public License as
Chris@392 11 published by the Free Software Foundation; either version 2 of the
Chris@392 12 License, or (at your option) any later version. See the file
Chris@392 13 COPYING included with this distribution for more information.
Chris@392 14 */
Chris@392 15
Chris@392 16 #ifndef _PROGRESS_REPORTER_H_
Chris@439 17 #define _PROGRESS_REPORTER_H_
Chris@392 18
Chris@392 19 #include <QObject>
Chris@392 20 #include <QString>
Chris@392 21
Chris@392 22 class ProgressReporter : public QObject
Chris@392 23 {
Chris@392 24 Q_OBJECT
Chris@392 25
Chris@392 26 public:
Chris@392 27 ProgressReporter(QObject *parent = 0);
Chris@392 28 virtual ~ProgressReporter();
Chris@392 29
Chris@439 30 virtual bool isDefinite() const = 0;
Chris@439 31 virtual void setDefinite(bool definite) = 0; // default should be definite
Chris@439 32
Chris@439 33 virtual bool wasCancelled() const = 0;
Chris@439 34
Chris@392 35 signals:
Chris@392 36 void cancelled();
Chris@392 37
Chris@392 38 public slots:
Chris@392 39 virtual void setMessage(QString text) = 0;
Chris@392 40 virtual void setProgress(int percentage) = 0;
Chris@392 41 };
Chris@392 42
Chris@392 43 #endif