Mercurial > hg > svcore
comparison data/fileio/DataFileReaderFactory.cpp @ 1047:26cf6d5251ec cxx11
Further dedicated-types fixes
author | Chris Cannam |
---|---|
date | Tue, 10 Mar 2015 17:02:52 +0000 |
parents | 59e7fe1b1003 |
children | 1dc64d3d323c |
comparison
equal
deleted
inserted
replaced
1046:2f49be7d4264 | 1047:26cf6d5251ec |
---|---|
30 DataFileReader * | 30 DataFileReader * |
31 DataFileReaderFactory::createReader(QString path, | 31 DataFileReaderFactory::createReader(QString path, |
32 bool csv, | 32 bool csv, |
33 MIDIFileImportPreferenceAcquirer *acquirer, | 33 MIDIFileImportPreferenceAcquirer *acquirer, |
34 CSVFormat format, | 34 CSVFormat format, |
35 int mainModelSampleRate) | 35 sv_samplerate_t mainModelSampleRate) |
36 { | 36 { |
37 QString err; | 37 QString err; |
38 | 38 |
39 DataFileReader *reader = 0; | 39 DataFileReader *reader = 0; |
40 | 40 |
56 } | 56 } |
57 | 57 |
58 DataFileReader * | 58 DataFileReader * |
59 DataFileReaderFactory::createReader(QString path, | 59 DataFileReaderFactory::createReader(QString path, |
60 MIDIFileImportPreferenceAcquirer *acquirer, | 60 MIDIFileImportPreferenceAcquirer *acquirer, |
61 int mainModelSampleRate) | 61 sv_samplerate_t mainModelSampleRate) |
62 { | 62 { |
63 DataFileReader *reader = createReader | 63 DataFileReader *reader = createReader |
64 (path, false, acquirer, CSVFormat(), mainModelSampleRate); | 64 (path, false, acquirer, CSVFormat(), mainModelSampleRate); |
65 if (reader) return reader; | 65 if (reader) return reader; |
66 | 66 |
72 } | 72 } |
73 | 73 |
74 Model * | 74 Model * |
75 DataFileReaderFactory::load(QString path, | 75 DataFileReaderFactory::load(QString path, |
76 MIDIFileImportPreferenceAcquirer *acquirer, | 76 MIDIFileImportPreferenceAcquirer *acquirer, |
77 int mainModelSampleRate) | 77 sv_samplerate_t mainModelSampleRate) |
78 { | 78 { |
79 DataFileReader *reader = createReader(path, | 79 DataFileReader *reader = createReader(path, |
80 acquirer, | 80 acquirer, |
81 mainModelSampleRate); | 81 mainModelSampleRate); |
82 if (!reader) return NULL; | 82 if (!reader) return NULL; |
92 } | 92 } |
93 | 93 |
94 Model * | 94 Model * |
95 DataFileReaderFactory::loadNonCSV(QString path, | 95 DataFileReaderFactory::loadNonCSV(QString path, |
96 MIDIFileImportPreferenceAcquirer *acquirer, | 96 MIDIFileImportPreferenceAcquirer *acquirer, |
97 int mainModelSampleRate) | 97 sv_samplerate_t mainModelSampleRate) |
98 { | 98 { |
99 DataFileReader *reader = createReader(path, false, | 99 DataFileReader *reader = createReader(path, false, |
100 acquirer, | 100 acquirer, |
101 CSVFormat(), | 101 CSVFormat(), |
102 mainModelSampleRate); | 102 mainModelSampleRate); |
112 } | 112 } |
113 } | 113 } |
114 | 114 |
115 Model * | 115 Model * |
116 DataFileReaderFactory::loadCSV(QString path, CSVFormat format, | 116 DataFileReaderFactory::loadCSV(QString path, CSVFormat format, |
117 int mainModelSampleRate) | 117 sv_samplerate_t mainModelSampleRate) |
118 { | 118 { |
119 DataFileReader *reader = createReader(path, true, 0, format, | 119 DataFileReader *reader = createReader(path, true, 0, format, |
120 mainModelSampleRate); | 120 mainModelSampleRate); |
121 if (!reader) return NULL; | 121 if (!reader) return NULL; |
122 | 122 |