32 #ifndef COORD_POLICY_H_
33 #define COORD_POLICY_H_
35 #include <drain/Log.h>
36 #include <drain/UniTuple.h>
40 #include "drain/util/Frame.h"
41 #include "drain/util/Point.h"
42 #include "drain/util/Range.h"
43 #include "drain/util/StatusFlags.h"
57 typedef unsigned short index_t;
59 static const EdgePolicy::index_t UNDEFINED;
60 static const EdgePolicy::index_t LIMIT;
61 static const EdgePolicy::index_t WRAP;
62 static const EdgePolicy::index_t MIRROR;
63 static const EdgePolicy::index_t POLAR;
110 EdgePolicy::index_t & xUnderFlowPolicy;
111 EdgePolicy::index_t & yUnderFlowPolicy;
112 EdgePolicy::index_t & xOverFlowPolicy;
113 EdgePolicy::index_t & yOverFlowPolicy;
123 xUnderFlowPolicy(next()), yUnderFlowPolicy(next()), xOverFlowPolicy(next()), yOverFlowPolicy(next()) {
129 xUnderFlowPolicy(next()), yUnderFlowPolicy(next()), xOverFlowPolicy(next()), yOverFlowPolicy(next()) {
134 CoordinatePolicy(EdgePolicy::index_t xUnderFlowPolicy, EdgePolicy::index_t yUnderFlowPolicy, EdgePolicy::index_t xOverFlowPolicy, EdgePolicy::index_t yOverFlowPolicy) :
135 xUnderFlowPolicy(next()), yUnderFlowPolicy(next()), xOverFlowPolicy(next()), yOverFlowPolicy(next()) {
136 set(xUnderFlowPolicy, yUnderFlowPolicy, xOverFlowPolicy, yOverFlowPolicy);
147 for (EdgePolicy::index_t p: tuple()){
148 if (p == EdgePolicy::UNDEFINED)
157 std::ostream & operator<<(std::ostream & ostr,
const CoordinatePolicy & policy);
Two-way mapping between strings and objects of template class T.
Definition: Dictionary.h:63
tuplebase_t & assignSequence(T &sequence, bool LENIENT=false)
Proposed for tuples only; derived classes should not shadow this.
Definition: TupleBase.h:244
void fill(S i)
Set all the elements to i.
Definition: TupleBase.h:272
Tuple of N elements of type T.
Definition: UniTuple.h:65
Policies for coordinate underflows and overflows.
Definition: CoordinatePolicy.h:106
Definition: DataSelector.cpp:1277
Definition: CoordinatePolicy.h:55