Mercurial > hg > sonic-visualiser
comparison document/Document.h @ 27:61259228d029
* More to do with passing around step/blocksize etc from plugin dialog to
plugins. Still some puzzling unresolved details.
author | Chris Cannam |
---|---|
date | Tue, 19 Sep 2006 14:37:06 +0000 |
parents | cd5d7ff8ef38 |
children | ca1e3f5657d5 |
comparison
equal
deleted
inserted
replaced
26:d88d117e0c34 | 27:61259228d029 |
---|---|
16 #ifndef _DOCUMENT_H_ | 16 #ifndef _DOCUMENT_H_ |
17 #define _DOCUMENT_H_ | 17 #define _DOCUMENT_H_ |
18 | 18 |
19 #include "layer/LayerFactory.h" | 19 #include "layer/LayerFactory.h" |
20 #include "transform/Transform.h" | 20 #include "transform/Transform.h" |
21 #include "transform/PluginTransform.h" | |
21 #include "base/Command.h" | 22 #include "base/Command.h" |
22 | 23 |
23 #include <map> | 24 #include <map> |
24 #include <set> | 25 #include <set> |
25 | 26 |
111 * running the transform and associating the resulting model with | 112 * running the transform and associating the resulting model with |
112 * the new layer. | 113 * the new layer. |
113 */ | 114 */ |
114 Layer *createDerivedLayer(TransformName, | 115 Layer *createDerivedLayer(TransformName, |
115 Model *inputModel, | 116 Model *inputModel, |
116 int inputChannel, // -1 -> all | 117 const PluginTransform::ExecutionContext &context, |
117 QString configurationXml); | 118 QString configurationXml); |
118 | 119 |
119 /** | 120 /** |
120 * Set the main model (the source for playback sample rate, etc) | 121 * Set the main model (the source for playback sample rate, etc) |
121 * to the given wave file model. This will regenerate any derived | 122 * to the given wave file model. This will regenerate any derived |
134 * created by the document using | 135 * created by the document using |
135 * e.g. createDerivedLayer(TransformName) above. | 136 * e.g. createDerivedLayer(TransformName) above. |
136 */ | 137 */ |
137 void addDerivedModel(TransformName, | 138 void addDerivedModel(TransformName, |
138 Model *inputModel, | 139 Model *inputModel, |
139 int inputChannel, // -1 -> all | 140 const PluginTransform::ExecutionContext &context, |
140 Model *outputModelToAdd, | 141 Model *outputModelToAdd, |
141 QString configurationXml); | 142 QString configurationXml); |
142 | 143 |
143 /** | 144 /** |
144 * Add an imported (non-derived, non-main) model. This is | 145 * Add an imported (non-derived, non-main) model. This is |
192 void modelRegenerationFailed(QString layerName, QString transformName); | 193 void modelRegenerationFailed(QString layerName, QString transformName); |
193 | 194 |
194 protected: | 195 protected: |
195 Model *createModelForTransform(TransformName transform, | 196 Model *createModelForTransform(TransformName transform, |
196 Model *inputModel, | 197 Model *inputModel, |
197 int channel, | 198 const PluginTransform::ExecutionContext &context, |
198 QString configurationXml); | 199 QString configurationXml); |
199 void releaseModel(Model *model); | 200 void releaseModel(Model *model); |
200 | 201 |
201 /** | 202 /** |
202 * Delete the given layer, and also its associated model if no | 203 * Delete the given layer, and also its associated model if no |
228 // transform name is set but source is NULL, then there was a | 229 // transform name is set but source is NULL, then there was a |
229 // transform involved but the (target) model has been modified | 230 // transform involved but the (target) model has been modified |
230 // since being generated from it. | 231 // since being generated from it. |
231 const Model *source; | 232 const Model *source; |
232 TransformName transform; | 233 TransformName transform; |
233 int channel; | 234 PluginTransform::ExecutionContext context; |
234 QString configurationXml; | 235 QString configurationXml; |
235 | 236 |
236 // Count of the number of layers using this model. | 237 // Count of the number of layers using this model. |
237 int refcount; | 238 int refcount; |
238 }; | 239 }; |