comparison data/model/AggregateWaveModel.h @ 1599:ce185d4dd408 bqaudiostream

Merge from default branch
author Chris Cannam
date Wed, 23 Jan 2019 14:43:43 +0000
parents ad5f892c0c4d
children 82d03c9661f9
comparison
equal deleted inserted replaced
1598:d2555df635ec 1599:ce185d4dd408
11 published by the Free Software Foundation; either version 2 of the 11 published by the Free Software Foundation; either version 2 of the
12 License, or (at your option) any later version. See the file 12 License, or (at your option) any later version. See the file
13 COPYING included with this distribution for more information. 13 COPYING included with this distribution for more information.
14 */ 14 */
15 15
16 #ifndef _AGGREGATE_WAVE_MODEL_H_ 16 #ifndef SV_AGGREGATE_WAVE_MODEL_H
17 #define _AGGREGATE_WAVE_MODEL_H_ 17 #define SV_AGGREGATE_WAVE_MODEL_H
18 18
19 #include "RangeSummarisableTimeValueModel.h" 19 #include "RangeSummarisableTimeValueModel.h"
20 #include "PowerOfSqrtTwoZoomConstraint.h" 20 #include "PowerOfSqrtTwoZoomConstraint.h"
21 21
22 #include <vector> 22 #include <vector>
37 typedef std::vector<ModelChannelSpec> ChannelSpecList; 37 typedef std::vector<ModelChannelSpec> ChannelSpecList;
38 38
39 AggregateWaveModel(ChannelSpecList channelSpecs); 39 AggregateWaveModel(ChannelSpecList channelSpecs);
40 ~AggregateWaveModel(); 40 ~AggregateWaveModel();
41 41
42 bool isOK() const; 42 bool isOK() const override;
43 bool isReady(int *) const; 43 bool isReady(int *) const override;
44 44
45 QString getTypeName() const { return tr("Aggregate Wave"); } 45 QString getTypeName() const override { return tr("Aggregate Wave"); }
46 46
47 int getComponentCount() const; 47 int getComponentCount() const;
48 ModelChannelSpec getComponent(int c) const; 48 ModelChannelSpec getComponent(int c) const;
49 49
50 const ZoomConstraint *getZoomConstraint() const { return &m_zoomConstraint; } 50 const ZoomConstraint *getZoomConstraint() const override { return &m_zoomConstraint; }
51 51
52 sv_frame_t getFrameCount() const; 52 sv_frame_t getFrameCount() const;
53 int getChannelCount() const; 53 int getChannelCount() const override;
54 sv_samplerate_t getSampleRate() const; 54 sv_samplerate_t getSampleRate() const override;
55 55
56 float getValueMinimum() const { return -1.0f; } 56 float getValueMinimum() const override { return -1.0f; }
57 float getValueMaximum() const { return 1.0f; } 57 float getValueMaximum() const override { return 1.0f; }
58 58
59 virtual sv_frame_t getStartFrame() const { return 0; } 59 sv_frame_t getStartFrame() const override { return 0; }
60 virtual sv_frame_t getEndFrame() const { return getFrameCount(); } 60 sv_frame_t getEndFrame() const override { return getFrameCount(); }
61 61
62 virtual floatvec_t getData(int channel, sv_frame_t start, sv_frame_t count) const; 62 floatvec_t getData(int channel, sv_frame_t start, sv_frame_t count) const override;
63 63
64 virtual std::vector<floatvec_t> getMultiChannelData(int fromchannel, int tochannel, sv_frame_t start, sv_frame_t count) const; 64 std::vector<floatvec_t> getMultiChannelData(int fromchannel, int tochannel, sv_frame_t start, sv_frame_t count) const override;
65 65
66 virtual int getSummaryBlockSize(int desired) const; 66 int getSummaryBlockSize(int desired) const override;
67 67
68 virtual void getSummaries(int channel, sv_frame_t start, sv_frame_t count, 68 void getSummaries(int channel, sv_frame_t start, sv_frame_t count,
69 RangeBlock &ranges, 69 RangeBlock &ranges,
70 int &blockSize) const; 70 int &blockSize) const override;
71 71
72 virtual Range getSummary(int channel, sv_frame_t start, sv_frame_t count) const; 72 Range getSummary(int channel, sv_frame_t start, sv_frame_t count) const override;
73 73
74 virtual void toXml(QTextStream &out, 74 void toXml(QTextStream &out,
75 QString indent = "", 75 QString indent = "",
76 QString extraAttributes = "") const; 76 QString extraAttributes = "") const override;
77 77
78 signals: 78 signals:
79 void modelChanged(); 79 void modelChanged();
80 void modelChangedWithin(sv_frame_t, sv_frame_t); 80 void modelChangedWithin(sv_frame_t, sv_frame_t);
81 void completionChanged(); 81 void completionChanged();