Isis Developer Reference
ProcessBySample.h
Go to the documentation of this file.
1#ifndef ProcessBySample_h
2#define ProcessBySample_h
8/* SPDX-License-Identifier: CC0-1.0 */
9#include "Buffer.h"
10#include "ProcessByBrick.h"
11
12namespace Isis {
38 public:
40 SetWrap(true);
41 };
42
44 Isis::Cube *SetInputCube(const QString &parameter,
45 int requirements = 0);
46 Isis::Cube *SetInputCube(const QString &file,
48 int requirements = 0);
49
50 void StartProcess(void funct(Isis::Buffer &inout));
51 void StartProcess(void funct(Isis::Buffer &in, Isis::Buffer &out));
52 void StartProcess(void funct(std::vector<Isis::Buffer *> &in,
53 std::vector<Isis::Buffer *> &out));
54
61 template <typename Functor>
62 void ProcessCubeInPlace(const Functor & funct, bool threaded = true) {
64 SetBricks(InPlace);
65 //SetBrickSizesForProcessCubeInPlace();
67 }
68
69
76 template <typename Functor>
77 void ProcessCube(const Functor & funct, bool threaded = true) {
79 SetBricks(InputOutput);
80 ProcessByBrick::ProcessCube(funct, threaded);
81 }
82
83
90 template <typename Functor>
91 void ProcessCubes(const Functor & funct, bool threaded = true) {
93 SetBricks(InputOutputList);
94 ProcessByBrick::ProcessCubes(funct, threaded);
95 }
96
97 private:
98 void SetBricks(IOCubes cn);
99 };
100};
101
102#endif
Buffer for reading and writing cube data.
Definition Buffer.h:53
Manipulate and parse attributes of input cube filenames.
Definition CubeAttribute.h:381
IO Handler for Isis Cubes.
Definition Cube.h:168
Process cubes by brick.
Definition ProcessByBrick.h:83
void ProcessCubeInPlace(const Functor &functor, bool threaded=true)
Operate over a single cube (either input or output).
Definition ProcessByBrick.h:167
void ProcessCubes(const Functor &functor, bool threaded=true)
Operate over an arbitrary number of input cubes given an arbitrary number of output cubes.
Definition ProcessByBrick.h:243
void VerifyCubes(IOCubes cn)
Verifies the dimensions of the input/output cubes.
Definition ProcessByBrick.cpp:120
Cube * SetInputCube(const QString &parameter, int requirements=0)
Opens an input cube specified by the user and verifies requirements are met.
Definition ProcessByBrick.cpp:58
void ProcessCube(const Functor &functor, bool threaded=true)
Operate over a single input cube creating a separate output cube.
Definition ProcessByBrick.h:204
void SetWrap(bool wrap)
This wrapping option only applys when there are two or more input cubes.
Definition ProcessByBrick.cpp:409
IOCubes
Definition ProcessByBrick.h:91
@ InputOutput
Definition ProcessByBrick.h:92
@ InputOutputList
Definition ProcessByBrick.h:93
@ InPlace
Definition ProcessByBrick.h:91
Process cubes by sample.
Definition ProcessBySample.h:37
Isis::Cube * SetInputCube(const QString &parameter, int requirements=0)
Opens an input cube specified by the user and verifies requirements are met.
Definition ProcessBySample.cpp:37
void StartProcess(void funct(Isis::Buffer &inout))
This method invokes the process by sample operation over a single input or output cube.
Definition ProcessBySample.cpp:77
ProcessBySample()
Definition ProcessBySample.h:39
void ProcessCubes(const Functor &funct, bool threaded=true)
Definition ProcessBySample.h:91
void ProcessCube(const Functor &funct, bool threaded=true)
Definition ProcessBySample.h:77
void ProcessCubeInPlace(const Functor &funct, bool threaded=true)
Definition ProcessBySample.h:62
This is free and unencumbered software released into the public domain.
Definition Apollo.h:16