Mercurial > hg > svcore
comparison data/fileio/MP3FileReader.h @ 317:c324d410b096
* RemoteFile -> FileSource
now it's used all over the place for local files as well.
author | Chris Cannam |
---|---|
date | Thu, 18 Oct 2007 16:20:26 +0000 |
parents | 3a6725f285d6 |
children | 1afaf98dbf11 |
comparison
equal
deleted
inserted
replaced
316:3a6725f285d6 | 317:c324d410b096 |
---|---|
33 enum DecodeMode { | 33 enum DecodeMode { |
34 DecodeAtOnce, // decode the file on construction, with progress dialog | 34 DecodeAtOnce, // decode the file on construction, with progress dialog |
35 DecodeThreaded // decode in a background thread after construction | 35 DecodeThreaded // decode in a background thread after construction |
36 }; | 36 }; |
37 | 37 |
38 MP3FileReader(RemoteFile source, | 38 MP3FileReader(FileSource source, |
39 DecodeMode decodeMode, | 39 DecodeMode decodeMode, |
40 CacheMode cacheMode, | 40 CacheMode cacheMode, |
41 size_t targetRate = 0); | 41 size_t targetRate = 0); |
42 virtual ~MP3FileReader(); | 42 virtual ~MP3FileReader(); |
43 | 43 |
46 virtual QString getTitle() const { return m_title; } | 46 virtual QString getTitle() const { return m_title; } |
47 | 47 |
48 static void getSupportedExtensions(std::set<QString> &extensions); | 48 static void getSupportedExtensions(std::set<QString> &extensions); |
49 static bool supportsExtension(QString ext); | 49 static bool supportsExtension(QString ext); |
50 static bool supportsContentType(QString type); | 50 static bool supportsContentType(QString type); |
51 static bool supports(RemoteFile &source); | 51 static bool supports(FileSource &source); |
52 | 52 |
53 virtual int getDecodeCompletion() const { return m_completion; } | 53 virtual int getDecodeCompletion() const { return m_completion; } |
54 | 54 |
55 virtual bool isUpdating() const { | 55 virtual bool isUpdating() const { |
56 return m_decodeThread && m_decodeThread->isRunning(); | 56 return m_decodeThread && m_decodeThread->isRunning(); |
57 } | 57 } |
58 | 58 |
59 protected: | 59 protected: |
60 RemoteFile m_source; | 60 FileSource m_source; |
61 QString m_path; | 61 QString m_path; |
62 QString m_error; | 62 QString m_error; |
63 QString m_title; | 63 QString m_title; |
64 size_t m_fileSize; | 64 size_t m_fileSize; |
65 double m_bitrateNum; | 65 double m_bitrateNum; |