comparison data/model/DenseTimeValueModel.cpp @ 1038:cc27f35aa75c cxx11

Introducing the signed 64-bit frame index type, and fixing build failures from inclusion of -Wconversion with -Werror. Not finished yet.
author Chris Cannam
date Tue, 03 Mar 2015 15:18:24 +0000
parents 59e7fe1b1003
children 9f4505ac9072
comparison
equal deleted inserted replaced
1037:bf0e5944289b 1038:cc27f35aa75c
27 { 27 {
28 PlayParameterRepository::getInstance()->removePlayable(this); 28 PlayParameterRepository::getInstance()->removePlayable(this);
29 } 29 }
30 30
31 QString 31 QString
32 DenseTimeValueModel::toDelimitedDataStringSubset(QString delimiter, int f0, int f1) const 32 DenseTimeValueModel::toDelimitedDataStringSubset(QString delimiter, sv_frame_t f0, sv_frame_t f1) const
33 { 33 {
34 int ch = getChannelCount(); 34 int ch = getChannelCount();
35 35
36 cerr << "f0 = " << f0 << ", f1 = " << f1 << endl; 36 cerr << "f0 = " << f0 << ", f1 = " << f1 << endl;
37 37
40 float **all = new float *[ch]; 40 float **all = new float *[ch];
41 for (int c = 0; c < ch; ++c) { 41 for (int c = 0; c < ch; ++c) {
42 all[c] = new float[f1 - f0]; 42 all[c] = new float[f1 - f0];
43 } 43 }
44 44
45 int n = getData(0, ch - 1, f0, f1 - f0, all); 45 sv_frame_t n = getData(0, ch - 1, f0, f1 - f0, all);
46 46
47 QStringList list; 47 QStringList list;
48 for (int i = 0; i < n; ++i) { 48 for (sv_frame_t i = 0; i < n; ++i) {
49 QStringList parts; 49 QStringList parts;
50 parts << QString("%1").arg(f0 + i); 50 parts << QString("%1").arg(f0 + i);
51 for (int c = 0; c < ch; ++c) { 51 for (int c = 0; c < ch; ++c) {
52 parts << QString("%1").arg(all[c][i]); 52 parts << QString("%1").arg(all[c][i]);
53 } 53 }