IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
PlanIndexedSplitOperators.h
Go to the documentation of this file.
1 // PlanIndexedSplitOperators.h:
3 // ----------------------------
4 //
15 
16 #ifndef __IPSDKIMAGEPROCESSING_PLANINDEXEDSPLITOPERATORS_H__
17 #define __IPSDKIMAGEPROCESSING_PLANINDEXEDSPLITOPERATORS_H__
18 
20 #include <IPSDKImageProcessing/DataSplit/PlanIndexed/PlanIndexedSplit.h>
21 #include <IPSDKImageProcessing/Attribute/PlanIndexed/BasePlanIndexedAttribute.h>
22 #include <IPSDKImage/Image/BaseImage.h>
23 #include <boost/make_shared.hpp>
24 #include <boost/utility/enable_if.hpp>
25 #include <boost/type_traits.hpp>
26 
27 namespace ipsdk {
28 namespace imaproc {
29 
32 
36 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
37 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
38  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
39 splitPlans(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
40  const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT)
41 {
43  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
44  pDataSplit->init(pPlanIndexed,
45  sizeZ, sizeC, sizeT,
46  false);
47 
48  return pDataSplit;
49 }
50 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
51 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
52  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
53 splitPlans(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
54  const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT)
55 {
57  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
58  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
59  sizeZ, sizeC, sizeT,
60  false);
61 
62  return pDataSplit;
63 }
64 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
65 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
66  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
67 splitPlans(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
68  const image::ImageConstPtr& pImage)
69 {
71  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
72  pDataSplit->init(pPlanIndexed,
73  pImage->getSizeZ(), pImage->getSizeC(), pImage->getSizeT(),
74  false);
75 
76  return pDataSplit;
77 }
78 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
79 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
80  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
81 splitPlans(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
82  const image::ImageConstPtr& pImage)
83 {
85  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
86  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
87  pImage->getSizeZ(), pImage->getSizeC(), pImage->getSizeT(),
88  false);
89 
90  return pDataSplit;
91 }
92 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
93 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
94  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
95 splitPlans(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed)
96 {
98  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
99  pDataSplit->init(pPlanIndexed,
100  pPlanIndexed->getMaxSizeZ(),
101  pPlanIndexed->getMaxSizeC(),
102  pPlanIndexed->getMaxSizeT(),
103  false);
104 
105  return pDataSplit;
106 }
107 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
108 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
109  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
110 splitPlans(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute)
111 {
113  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
114  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
115  pPlanIndexedAttribute->getMaxSizeZ(),
116  pPlanIndexedAttribute->getMaxSizeC(),
117  pPlanIndexedAttribute->getMaxSizeT(),
118  false);
119 
120  return pDataSplit;
121 }
123 
127 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
128 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
129  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
130 splitPlans3d(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
131  const image::ImageConstPtr& pImage)
132 {
134  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
135  pDataSplit->init(pPlanIndexed,
136  1, pImage->getSizeC(), pImage->getSizeT(),
137  false);
138 
139  return pDataSplit;
140 }
141 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
142 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
143  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
144 splitPlans3d(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
145  const image::ImageConstPtr& pImage)
146 {
148  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
149  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
150  1, pImage->getSizeC(), pImage->getSizeT(),
151  false);
152 
153  return pDataSplit;
154 }
155 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
156 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
157  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
158 splitPlans3d(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
159  const ipUInt64 sizeC,
160  const ipUInt64 sizeT)
161 {
163  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
164  pDataSplit->init(pPlanIndexed,
165  1, sizeC, sizeT,
166  false);
167 
168  return pDataSplit;
169 }
170 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
171 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
172  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
173 splitPlans3d(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
174  const ipUInt64 sizeC,
175  const ipUInt64 sizeT)
176 {
178  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
179  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
180  1, sizeC, sizeT,
181  false);
182 
183  return pDataSplit;
184 }
185 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
186 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
187  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
188 splitPlans3d(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed)
189 {
191  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
192  pDataSplit->init(pPlanIndexed,
193  1,
194  pPlanIndexed->getMaxSizeC(),
195  pPlanIndexed->getMaxSizeT(),
196  false);
197 
198  return pDataSplit;
199 }
200 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
201 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
202  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
203 splitPlans3d(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute)
204 {
206  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
207  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
208  1,
209  pPlanIndexedAttribute->getMaxSizeC(),
210  pPlanIndexedAttribute->getMaxSizeT(),
211  false);
212 
213  return pDataSplit;
214 }
216 
220 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
221 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
222  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
223 splitPlansColor(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
224  const image::ImageConstPtr& pImage)
225 {
227  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
228  pDataSplit->init(pPlanIndexed,
229  pImage->getSizeZ(), 1, pImage->getSizeT(),
230  false);
231 
232  return pDataSplit;
233 }
234 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
235 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
236  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
237 splitPlansColor(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
238  const image::ImageConstPtr& pImage)
239 {
241  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
242  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
243  pImage->getSizeZ(), 1, pImage->getSizeT(),
244  false);
245 
246  return pDataSplit;
247 }
248 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
249 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
250  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
251 splitPlansColor(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
252  const ipUInt64 sizeZ,
253  const ipUInt64 sizeT)
254 {
256  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
257  pDataSplit->init(pPlanIndexed,
258  sizeZ, 1, sizeT,
259  false);
260 
261  return pDataSplit;
262 }
263 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
264 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
265  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
266 splitPlansColor(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
267  const ipUInt64 sizeZ,
268  const ipUInt64 sizeT)
269 {
271  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
272  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
273  sizeZ, 1, sizeT,
274  false);
275 
276  return pDataSplit;
277 }
278 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
279 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
280  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
281 splitPlansColor(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed)
282 {
284  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
285  pDataSplit->init(pPlanIndexed,
286  pPlanIndexed->getMaxSizeZ(),
287  1,
288  pPlanIndexed->getMaxSizeT(),
289  false);
290 
291  return pDataSplit;
292 }
293 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
294 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
295  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
296 splitPlansColor(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute)
297 {
299  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
300  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
301  pPlanIndexedAttribute->getMaxSizeZ(),
302  1,
303  pPlanIndexedAttribute->getMaxSizeT(),
304  false);
305 
306  return pDataSplit;
307 }
309 
313 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
314 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
315  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
316 splitPlans3dColor(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
317  const image::ImageConstPtr& pImage)
318 {
320  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
321  pDataSplit->init(pPlanIndexed,
322  1, 1, pImage->getSizeT(),
323  false);
324 
325  return pDataSplit;
326 }
327 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
328 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
329  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
330 splitPlans3dColor(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
331  const image::ImageConstPtr& pImage)
332 {
334  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
335  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
336  1, 1, pImage->getSizeT(),
337  false);
338 
339  return pDataSplit;
340 }
341 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
342 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
343  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
344 splitPlans3dColor(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
345  const ipUInt64 sizeT)
346 {
348  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
349  pDataSplit->init(pPlanIndexed,
350  1, 1, sizeT,
351  false);
352 
353  return pDataSplit;
354 }
355 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
356 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
357  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
358 splitPlans3dColor(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
359  const ipUInt64 sizeT)
360 {
362  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
363  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
364  1, 1, sizeT,
365  false);
366 
367  return pDataSplit;
368 }
369 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
370 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
371  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
372 splitPlans3dColor(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed)
373 {
375  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
376  pDataSplit->init(pPlanIndexed,
377  1,
378  1,
379  pPlanIndexed->getMaxSizeT(),
380  false);
381 
382  return pDataSplit;
383 }
384 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
385 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
386  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
387 splitPlans3dColor(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute)
388 {
390  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
391  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
392  1,
393  1,
394  pPlanIndexedAttribute->getMaxSizeT(),
395  false);
396 
397  return pDataSplit;
398 }
400 
406 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
407 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
408  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
409 splitPlansOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
410  const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT)
411 {
413  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
414  pDataSplit->init(pPlanIndexed,
415  sizeZ, sizeC, sizeT,
416  true);
417 
418  return pDataSplit;
419 }
420 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
421 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
422  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
423 splitPlansOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
424  const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT)
425 {
427  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
428  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
429  sizeZ, sizeC, sizeT,
430  true);
431 
432  return pDataSplit;
433 }
434 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
435 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
436  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
437 splitPlansOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
438  const image::ImageConstPtr& pImage)
439 {
441  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
442  pDataSplit->init(pPlanIndexed,
443  pImage->getSizeZ(), pImage->getSizeC(), pImage->getSizeT(),
444  true);
445 
446  return pDataSplit;
447 }
448 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
449 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
450  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
451 splitPlansOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
452  const image::ImageConstPtr& pImage)
453 {
455  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
456  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
457  pImage->getSizeZ(), pImage->getSizeC(), pImage->getSizeT(),
458  true);
459 
460  return pDataSplit;
461 }
463 
469 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
470 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
471  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
472 splitPlans3dOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
473  const image::ImageConstPtr& pImage)
474 {
476  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
477  pDataSplit->init(pPlanIndexed,
478  1, pImage->getSizeC(), pImage->getSizeT(),
479  true);
480 
481  return pDataSplit;
482 }
483 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
484 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
485  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
486 splitPlans3dOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
487  const image::ImageConstPtr& pImage)
488 {
490  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
491  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
492  1, pImage->getSizeC(), pImage->getSizeT(),
493  true);
494 
495  return pDataSplit;
496 }
497 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
498 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
499  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
500 splitPlans3dOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
501  const ipUInt64 sizeC,
502  const ipUInt64 sizeT)
503 {
505  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
506  pDataSplit->init(pPlanIndexed,
507  1, sizeC, sizeT,
508  true);
509 
510  return pDataSplit;
511 }
512 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
513 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
514  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
515 splitPlans3dOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
516  const ipUInt64 sizeC,
517  const ipUInt64 sizeT)
518 {
520  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
521  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
522  1, sizeC, sizeT,
523  true);
524 
525  return pDataSplit;
526 }
528 
534 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
535 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
536  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
537 splitPlansColorOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
538  const image::ImageConstPtr& pImage)
539 {
541  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
542  pDataSplit->init(pPlanIndexed,
543  pImage->getSizeZ(), 1, pImage->getSizeT(),
544  true);
545 
546  return pDataSplit;
547 }
548 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
549 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
550  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
551 splitPlansColorOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
552  const image::ImageConstPtr& pImage)
553 {
555  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
556  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
557  pImage->getSizeZ(), 1, pImage->getSizeT(),
558  true);
559 
560  return pDataSplit;
561 }
562 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
563 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
564  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
565 splitPlansColorOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
566  const ipUInt64 sizeZ,
567  const ipUInt64 sizeT)
568 {
570  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
571  pDataSplit->init(pPlanIndexed,
572  sizeZ, 1, sizeT,
573  true);
574 
575  return pDataSplit;
576 }
577 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
578 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
579  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
580 splitPlansColorOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
581  const ipUInt64 sizeZ,
582  const ipUInt64 sizeT)
583 {
585  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
586  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
587  sizeZ, 1, sizeT,
588  true);
589 
590  return pDataSplit;
591 }
593 
599 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
600 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
601  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
602 splitPlans3dColorOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
603  const image::ImageConstPtr& pImage)
604 {
606  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
607  pDataSplit->init(pPlanIndexed,
608  1, 1, pImage->getSizeT(),
609  true);
610 
611  return pDataSplit;
612 }
613 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
614 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
615  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
616 splitPlans3dColorOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
617  const image::ImageConstPtr& pImage)
618 {
620  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
621  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
622  1, 1, pImage->getSizeT(),
623  true);
624 
625  return pDataSplit;
626 }
627 template <typename TProcessor, typename TAttribute, typename PlanIndexedType>
628 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedColl, PlanIndexedType>::type,
629  boost::shared_ptr<PlanIndexedSplit<TProcessor, boost::shared_ptr<PlanIndexedType>, TAttribute> > >::type
630 splitPlans3dColorOrSingle(const boost::shared_ptr<PlanIndexedType>& pPlanIndexed,
631  const ipUInt64 sizeT)
632 {
634  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
635  pDataSplit->init(pPlanIndexed,
636  1, 1, sizeT,
637  true);
638 
639  return pDataSplit;
640 }
641 template <typename TProcessor, typename TAttribute, typename InputAttributeType>
642 inline typename boost::enable_if<typename boost::is_base_of<BasePlanIndexedAttribute, InputAttributeType>::type,
643  boost::shared_ptr<PlanIndexedSplit<TProcessor, typename InputAttributeType::StorageType, TAttribute> > >::type
644 splitPlans3dColorOrSingle(const boost::shared_ptr<InputAttributeType>& pPlanIndexedAttribute,
645  const ipUInt64 sizeT)
646 {
648  boost::shared_ptr<DataSplit> pDataSplit = boost::make_shared<DataSplit>();
649  pDataSplit->init(pPlanIndexedAttribute->getStorage(),
650  1, 1, sizeT,
651  true);
652 
653  return pDataSplit;
654 }
656 
659 
660 } // end of namespace imaproc
661 } // end of namespace ipsdk
662 
663 #endif // __IPSDKIMAGEPROCESSING_PLANINDEXEDSPLITOPERATORS_H__
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlansColor(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const image::ImageConstPtr &pImage)
create a splitted image operation used for data dispatch where all color plans of image are considere...
Definition: PlanIndexedSplitOperators.h:223
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
uint64_t ipUInt64
Base types definition.
Definition: BaseTypes.h:55
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlans3dOrSingle(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const image::ImageConstPtr &pImage)
create a splitted image operation used for data dispatch where all 3d plans of image are considered a...
Definition: PlanIndexedSplitOperators.h:472
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlans3dColor(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const image::ImageConstPtr &pImage)
create a splitted image operation used for data dispatch where all color plans of image are considere...
Definition: PlanIndexedSplitOperators.h:316
Concrete class for split operation using input plan indexed data.
Definition: PlanIndexedSplit.h:28
boost::shared_ptr< const BaseImage > ImageConstPtr
Definition: ImageTypes.h:140
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlans3d(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const image::ImageConstPtr &pImage)
create a splitted image operation used for data dispatch where all 3d plans of image are considered a...
Definition: PlanIndexedSplitOperators.h:130
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlans3dColorOrSingle(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const image::ImageConstPtr &pImage)
create a splitted image operation used for data dispatch where all color plans of image are considere...
Definition: PlanIndexedSplitOperators.h:602
void init(const InputStorageType &pPlanIndexedColl, const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT, const bool bCanBeSingle=false)
initialization method for splitted objects
Definition: PlanIndexedSplit.h:108
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlans(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT)
create a splitted image operation used for data dispatch where all 2d plans of image are considered a...
Definition: PlanIndexedSplitOperators.h:39
Predefined operators for static data split used for data dispatch.
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlansOrSingle(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const ipUInt64 sizeZ, const ipUInt64 sizeC, const ipUInt64 sizeT)
create a splitted image operation used for data dispatch where all 2d plans of image are considered a...
Definition: PlanIndexedSplitOperators.h:409
boost::enable_if< typename boost::is_base_of< BasePlanIndexedColl, PlanIndexedType >::type, boost::shared_ptr< PlanIndexedSplit< TProcessor, boost::shared_ptr< PlanIndexedType >, TAttribute > > >::type splitPlansColorOrSingle(const boost::shared_ptr< PlanIndexedType > &pPlanIndexed, const image::ImageConstPtr &pImage)
create a splitted image operation used for data dispatch where all color plans of image are considere...
Definition: PlanIndexedSplitOperators.h:537