comparison data/model/DenseTimeValueModel.h @ 1126:39019ce29178 tony-2.0-integration

Merge through to branch for Tony 2.0
author Chris Cannam
date Thu, 20 Aug 2015 14:54:21 +0100
parents 4d9816ba0ebe
children 54af1e21705c
comparison
equal deleted inserted replaced
1119:e22bfe8ca248 1126:39019ce29178
55 */ 55 */
56 virtual int getChannelCount() const = 0; 56 virtual int getChannelCount() const = 0;
57 57
58 /** 58 /**
59 * Get the specified set of samples from the given channel of the 59 * Get the specified set of samples from the given channel of the
60 * model in single-precision floating-point format. Return the 60 * model in single-precision floating-point format. Returned
61 * number of samples actually retrieved. 61 * vector may have fewer samples than requested, if the end of
62 * file was reached.
63 *
62 * If the channel is given as -1, mix all available channels and 64 * If the channel is given as -1, mix all available channels and
63 * return the result. 65 * return the result.
64 */ 66 */
65 virtual sv_frame_t getData(int channel, sv_frame_t start, sv_frame_t count, 67 virtual std::vector<float> getData(int channel, sv_frame_t start, sv_frame_t count) const = 0;
66 float *buffer) const = 0;
67 68
68 /** 69 /**
69 * Get the specified set of samples from the given channel of the 70 * Get the specified set of samples from given contiguous range of
70 * model in double-precision floating-point format. Return the 71 * channels of the model in single-precision floating-point
71 * number of samples actually retrieved. 72 * format. Returned vector may have fewer samples than requested,
72 * If the channel is given as -1, mix all available channels and 73 * if the end of file was reached.
73 * return the result.
74 */ 74 */
75 virtual sv_frame_t getData(int channel, sv_frame_t start, sv_frame_t count, 75 virtual std::vector<std::vector<float>> getMultiChannelData(int fromchannel, int tochannel, sv_frame_t start, sv_frame_t count) const = 0;
76 double *buffer) const = 0;
77
78 /**
79 * Get the specified set of samples from given contiguous range
80 * of channels of the model in single-precision floating-point
81 * format. Return the number of sample frames actually retrieved.
82 */
83 virtual sv_frame_t getData(int fromchannel, int tochannel,
84 sv_frame_t start, sv_frame_t count,
85 float **buffers) const = 0;
86 76
87 virtual bool canPlay() const { return true; } 77 virtual bool canPlay() const { return true; }
88 virtual QString getDefaultPlayClipId() const { return ""; } 78 virtual QString getDefaultPlayClipId() const { return ""; }
89 79
90 virtual QString toDelimitedDataStringSubset(QString delimiter, sv_frame_t f0, sv_frame_t f1) const; 80 virtual QString toDelimitedDataStringSubset(QString delimiter, sv_frame_t f0, sv_frame_t f1) const;