comparison data/fileio/WavFileWriter.h @ 936:0c1d6de8f44b

Merge from branch warnfix_no_size_t
author Chris Cannam
date Wed, 18 Jun 2014 13:51:16 +0100
parents 59e7fe1b1003
children cc27f35aa75c
comparison
equal deleted inserted replaced
917:49618f39ff09 936:0c1d6de8f44b
42 enum FileWriteMode { 42 enum FileWriteMode {
43 WriteToTemporary, 43 WriteToTemporary,
44 WriteToTarget 44 WriteToTarget
45 }; 45 };
46 46
47 WavFileWriter(QString path, size_t sampleRate, size_t channels, 47 WavFileWriter(QString path, int sampleRate, int channels,
48 FileWriteMode mode); 48 FileWriteMode mode);
49 virtual ~WavFileWriter(); 49 virtual ~WavFileWriter();
50 50
51 bool isOK() const; 51 bool isOK() const;
52 52
55 QString getPath() const { return m_path; } 55 QString getPath() const { return m_path; }
56 56
57 bool writeModel(DenseTimeValueModel *source, 57 bool writeModel(DenseTimeValueModel *source,
58 MultiSelection *selection = 0); 58 MultiSelection *selection = 0);
59 59
60 bool writeSamples(float **samples, size_t count); // count per channel 60 bool writeSamples(float **samples, int count); // count per channel
61 61
62 bool close(); 62 bool close();
63 63
64 protected: 64 protected:
65 QString m_path; 65 QString m_path;
66 size_t m_sampleRate; 66 int m_sampleRate;
67 size_t m_channels; 67 int m_channels;
68 TempWriteFile *m_temp; 68 TempWriteFile *m_temp;
69 SNDFILE *m_file; 69 SNDFILE *m_file;
70 QString m_error; 70 QString m_error;
71 71
72 QString getWriteFilename() const; 72 QString getWriteFilename() const;