8#ifndef META_OCEAN_CV_SYNTHESIS_MAPPING_I_1_H
9#define META_OCEAN_CV_SYNTHESIS_MAPPING_I_1_H
75 MappingI1(
const unsigned int width,
const unsigned int height);
91 template <
unsigned int tChannels>
92 inline unsigned int spatialCost4Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const;
108 template <
unsigned int tChannels>
109 inline unsigned int spatialCost8Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const;
124 template <
unsigned int tChannels,
unsigned int tBorderFactor>
125 unsigned int appearanceCost5x5(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* frame,
const uint8_t* mask,
const unsigned int framePaddingElements,
const unsigned int maskPaddingElements)
const;
131 void applyMapping(
Frame& frame,
const Frame& mask,
const unsigned int xStart,
const unsigned int xWidth,
const unsigned int yStart,
const unsigned int yHeight,
Worker* worker =
nullptr)
const override;
147 template <
unsigned int tChannels>
148 inline void applyOneFrameMapping8BitPerChannel(uint8_t*
const frame,
const uint8_t*
const mask,
const unsigned int framePaddingElements,
const unsigned int maskPaddingElements,
const unsigned int xStart,
const unsigned int xWidth,
const unsigned int yStart,
const unsigned int yHeight,
Worker* worker =
nullptr)
const;
178 inline unsigned int spatialCost4Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const;
192 inline unsigned int spatialCost8Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const;
207 template <
unsigned int tChannels>
208 void applyOneFrameMapping8BitPerChannelSubset(uint8_t*
const frame,
const uint8_t*
const mask,
const unsigned int frameStrideElements,
const unsigned int maskStrideElements,
const unsigned int xStart,
const unsigned int xWidth,
const unsigned int firstRow,
const unsigned int numberRows)
const;
211template <
unsigned int tChannels>
212inline unsigned int MappingI1::spatialCost4Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const
214 const unsigned int cost =
spatialCost4Neighborhood(xTarget, yTarget, xSource, ySource, targetMask, targetMaskPaddingElements, maxCost);
216 ocean_assert(cost <= maxCost);
222 return cost * appearanceCostNormalization<tChannels>();
225template <
unsigned int tChannels>
226inline unsigned int MappingI1::spatialCost8Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const
228 const unsigned int cost =
spatialCost8Neighborhood(xTarget, yTarget, xSource, ySource, targetMask, targetMaskPaddingElements, maxCost);
230 ocean_assert(cost <= maxCost);
236 return cost * appearanceCostNormalization<tChannels>();
239template <
unsigned int tChannels>
240inline void MappingI1::applyOneFrameMapping8BitPerChannel(uint8_t*
const frame,
const uint8_t*
const mask,
const unsigned int framePaddingElements,
const unsigned int maskPaddingElements,
const unsigned int xStart,
const unsigned int xWidth,
const unsigned int yStart,
const unsigned int yHeight,
Worker* worker)
const
242 ocean_assert(frame !=
nullptr && mask !=
nullptr);
244 ocean_assert(xStart + xWidth <=
width_);
245 ocean_assert(yStart + yHeight <=
height_);
247 const unsigned int frameStrideElements =
width_ * tChannels + framePaddingElements;
248 const unsigned int maskStrideElements =
width_ + maskPaddingElements;
252 worker->
executeFunction(
Worker::Function::create(*
this, &MappingI1::applyOneFrameMapping8BitPerChannelSubset<tChannels>, frame, mask, frameStrideElements, maskStrideElements, xStart, xWidth, 0u, 0u), yStart, yHeight, 6u, 7u, 40u);
256 applyOneFrameMapping8BitPerChannelSubset<tChannels>(frame, mask, frameStrideElements, maskStrideElements, xStart, xWidth, yStart, yHeight);
268 if (
this != &pixelMapping)
276inline unsigned int MappingI1::spatialCost4Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const
278 ocean_assert(targetMask !=
nullptr);
279 ocean_assert(maxCost > 0u);
284 const unsigned int targetMaskStrideElements =
width_ + targetMaskPaddingElements;
287 ocean_assert(targetMask[yTarget * targetMaskStrideElements + xTarget] != 0xFF);
289 unsigned int cost = maxCost;
292 const uint8_t* targetMaskPointer = targetMask + (int(yTarget) - 1) *
int(targetMaskStrideElements) + xTarget;
296 if (yTarget > 0u && *targetMaskPointer != 0xFF)
298 ocean_assert(*mappingPointer);
299 ocean_assert(*mappingPointer ==
mappingI_[(yTarget - 1u) *
width_ + xTarget]);
300 ocean_assert(*targetMaskPointer == targetMask[(yTarget - 1u) * targetMaskStrideElements + xTarget]);
304 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource) +
sqr(mappingPointer->
y() - ySource + 1u);
305 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource)) +
sqr(
int(mappingPointer->
y()) -
int(ySource) + 1));
314 if (localCost < cost)
321 ocean_assert(
width_ >= 1u);
322 targetMaskPointer += targetMaskStrideElements - 1u;
323 mappingPointer +=
width_ - 1u;
326 if (xTarget > 0 && *targetMaskPointer != 0xFF)
328 ocean_assert(*mappingPointer);
329 ocean_assert(*mappingPointer ==
mappingI_[yTarget *
width_ + xTarget - 1u]);
330 ocean_assert(*targetMaskPointer == targetMask[yTarget * targetMaskStrideElements + xTarget - 1u]);
334 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource + 1u) +
sqr(mappingPointer->
y() - ySource);
335 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource) + 1) +
sqr(
int(mappingPointer->
y()) -
int(ySource)));
344 if (localCost < cost)
351 targetMaskPointer += 2;
355 if (xTarget + 1 <
width_ && *targetMaskPointer != 0xFF)
357 ocean_assert(*mappingPointer);
358 ocean_assert(*mappingPointer ==
mappingI_[yTarget *
width_ + xTarget + 1u]);
359 ocean_assert(*targetMaskPointer == targetMask[yTarget * targetMaskStrideElements + xTarget + 1u]);
363 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource - 1u) +
sqr(mappingPointer->
y() - ySource);
364 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource) - 1) +
sqr(
int(mappingPointer->
y()) -
int(ySource)));
373 if (localCost < cost)
380 targetMaskPointer += targetMaskStrideElements - 1u;
381 mappingPointer +=
width_ - 1u;
384 if (yTarget + 1 <
height_ && *targetMaskPointer != 0xFF)
386 ocean_assert(*mappingPointer);
387 ocean_assert(*mappingPointer ==
mappingI_[(yTarget + 1u) *
width_ + xTarget]);
388 ocean_assert(*targetMaskPointer == targetMask[(yTarget + 1u) * targetMaskStrideElements + xTarget]);
392 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource) +
sqr(mappingPointer->
y() - ySource - 1u);
393 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource)) +
sqr(
int(mappingPointer->
y()) -
int(ySource) - 1));
402 if (localCost < cost)
411inline unsigned int MappingI1::spatialCost8Neighborhood(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* targetMask,
const unsigned int targetMaskPaddingElements,
const unsigned int maxCost)
const
413 ocean_assert(targetMask);
418 const unsigned int targetMaskStrideElements =
width_ + targetMaskPaddingElements;
421 ocean_assert(targetMask[yTarget * targetMaskStrideElements + xTarget] != 0xFF);
423 unsigned int cost = maxCost;
425 const uint8_t* targetMaskPointer = targetMask + (int(yTarget) - 1) *
int(targetMaskStrideElements) + xTarget - 1;
429 if (yTarget > 0 && xTarget > 0 && *targetMaskPointer != 0xFF)
431 ocean_assert(*mappingPointer);
432 ocean_assert(*mappingPointer ==
mappingI_[(yTarget - 1u) *
width_ + xTarget - 1u]);
433 ocean_assert(*targetMaskPointer == targetMask[(yTarget - 1u) * targetMaskStrideElements + xTarget - 1u]);
439 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource + 1u) +
sqr(mappingPointer->
y() - ySource + 1u);
442 if (localCost == 0u) {
447 if (localCost < cost) {
457 if (yTarget > 0 && *targetMaskPointer != 0xFF)
459 ocean_assert(*mappingPointer);
460 ocean_assert(*mappingPointer ==
mappingI_[(yTarget - 1u) *
width_ + xTarget]);
461 ocean_assert(*targetMaskPointer == targetMask[(yTarget - 1u) * targetMaskStrideElements + xTarget]);
465 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource) +
sqr(mappingPointer->
y() - ySource + 1u);
466 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource)) +
sqr(
int(mappingPointer->
y()) -
int(ySource) + 1));
469 if (localCost == 0u) {
474 if (localCost < cost) {
484 if (yTarget > 0 && xTarget + 1u <
width_ && *targetMaskPointer != 0xFF)
486 ocean_assert(*mappingPointer);
487 ocean_assert(*mappingPointer ==
mappingI_[(yTarget - 1u) *
width_ + xTarget + 1u]);
488 ocean_assert(*targetMaskPointer == targetMask[(yTarget - 1u) * targetMaskStrideElements + xTarget + 1u]);
494 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource - 1u) +
sqr(mappingPointer->
y() - ySource + 1u);
497 if (localCost == 0u) {
502 if (localCost < cost) {
508 ocean_assert(
width_ >= 2u);
509 targetMaskPointer += targetMaskStrideElements - 2u;
510 mappingPointer +=
width_ - 2u;
513 if (xTarget > 0 && *targetMaskPointer != 0xFF)
515 ocean_assert(*mappingPointer);
516 ocean_assert(*mappingPointer ==
mappingI_[yTarget *
width_ + xTarget - 1u]);
517 ocean_assert(*targetMaskPointer == targetMask[yTarget * targetMaskStrideElements + xTarget - 1u]);
521 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource + 1u) +
sqr(mappingPointer->
y() - ySource);
522 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource) + 1) +
sqr(
int(mappingPointer->
y()) -
int(ySource)));
525 if (localCost == 0u) {
530 if (localCost < cost) {
536 targetMaskPointer += 2;
540 if (xTarget + 1 <
width_ && *targetMaskPointer != 0xFF)
542 ocean_assert(*mappingPointer);
543 ocean_assert(*mappingPointer ==
mappingI_[yTarget *
width_ + xTarget + 1u]);
544 ocean_assert(*targetMaskPointer == targetMask[yTarget * targetMaskStrideElements + xTarget + 1u]);
548 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource - 1u) +
sqr(mappingPointer->
y() - ySource);
549 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource) - 1) +
sqr(
int(mappingPointer->
y()) -
int(ySource)));
552 if (localCost == 0u) {
557 if (localCost < cost) {
563 ocean_assert(
width_ >= 2u);
564 targetMaskPointer += targetMaskStrideElements - 2u;
565 mappingPointer +=
width_ - 2u;
568 if (xTarget > 0 && yTarget + 1 <
height_ && * targetMaskPointer != 0xFF)
570 ocean_assert(*mappingPointer);
571 ocean_assert(*mappingPointer ==
mappingI_[(yTarget + 1u) *
width_ + xTarget - 1u]);
572 ocean_assert(*targetMaskPointer == targetMask[(yTarget + 1u) * targetMaskStrideElements + xTarget - 1u]);
578 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource + 1u) +
sqr(mappingPointer->
y() - ySource - 1u);
581 if (localCost == 0u) {
586 if (localCost < cost) {
596 if (yTarget + 1 <
height_ && *targetMaskPointer != 0xFF)
598 ocean_assert(*mappingPointer);
599 ocean_assert(*mappingPointer ==
mappingI_[(yTarget + 1u) *
width_ + xTarget]);
600 ocean_assert(*targetMaskPointer == targetMask[(yTarget + 1u) * targetMaskStrideElements + xTarget]);
604 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource) +
sqr(mappingPointer->
y() - ySource - 1u);
605 ocean_assert(localCost ==
sqr(
int(mappingPointer->
x()) -
int(xSource)) +
sqr(
int(mappingPointer->
y()) -
int(ySource) - 1));
608 if (localCost == 0u) {
613 if (localCost < cost) {
623 if (xTarget + 1 <
width_ && yTarget + 1 <
height_ && *targetMaskPointer != 0xFF)
625 ocean_assert(*mappingPointer);
626 ocean_assert(*mappingPointer ==
mappingI_[(yTarget + 1u) *
width_ + xTarget + 1u]);
627 ocean_assert(*targetMaskPointer == targetMask[(yTarget + 1u) * targetMaskStrideElements + xTarget + 1u]);
633 const unsigned int localCost =
sqr(mappingPointer->
x() - xSource - 1u) +
sqr(mappingPointer->
y() - ySource - 1u);
636 if (localCost == 0u) {
641 if (localCost < cost) {
649template <
unsigned int tChannels,
unsigned int tBorderFactor>
650unsigned int MappingI1::appearanceCost5x5(
const unsigned int xTarget,
const unsigned int yTarget,
const unsigned int xSource,
const unsigned int ySource,
const uint8_t* frame,
const uint8_t* mask,
const unsigned int framePaddingElements,
const unsigned int maskPaddingElements)
const
652 static_assert(tChannels >= 1u,
"Invalid channel number!");
653 static_assert(tBorderFactor >= 1u,
"Invalid border factor!");
655 ocean_assert(mask !=
nullptr && frame !=
nullptr);
660 const unsigned int maskStrideElements =
width_ + maskPaddingElements;
663 ocean_assert(mask[yTarget * maskStrideElements + xTarget] != 0xFF);
665 ocean_assert(mask[ySource * maskStrideElements + xSource] == 0xFF);
667 ocean_assert(
width_ >= 3u);
670 if (xSource >= 2 && ySource >= 2 && xSource + 2 <
width_ && ySource + 2 <
height_)
672 if (mask[yTarget * maskStrideElements + xTarget] == 0x00 || mask[yTarget * maskStrideElements + xTarget] >= 3)
674 ocean_assert(xTarget >= 2 && yTarget >= 2 && xTarget + 2 <
width_ && yTarget + 2 <
height_);
675 return Advanced::SumSquareDifferencesNoCenter::patch8BitPerChannel<tChannels, 5u>(frame, frame,
width_,
width_, xTarget, yTarget, xSource, ySource, framePaddingElements, framePaddingElements) * spatialCostNormalization<tChannels>() / 25u;
678 if (xTarget >= 2 && yTarget >= 2 && xTarget + 2 <
width_ && yTarget + 2 <
height_)
680 const unsigned int frameStrideElements =
width_ * tChannels + framePaddingElements;
682 const uint8_t*
const frameTargetTopLeft = frame + (yTarget - 2) * frameStrideElements + (xTarget - 2) * tChannels;
683 const uint8_t*
const frameSourceTopLeft = frame + (ySource - 2) * frameStrideElements + (xSource - 2) * tChannels;
684 const uint8_t*
const maskTopLeft = mask + (yTarget - 2) * maskStrideElements + xTarget - 2;
686 return ssd5x5MaskNoCenter<tChannels, tBorderFactor>(frameTargetTopLeft, frameSourceTopLeft, maskTopLeft,
width_,
width_, framePaddingElements, framePaddingElements, maskPaddingElements) * spatialCostNormalization<tChannels>() / 25u;
690 unsigned int cost = 0;
692 int iterOutX = int(xSource) - 2;
693 for (
int iterInX =
int(xTarget) - 2; iterInX <= int(xTarget) + 2; ++iterInX)
698 int iterOutY = int(ySource) - 2;
699 for (
int iterInY =
int(yTarget) - 2; iterInY <= int(yTarget) + 2; ++iterInY)
701 if (iterInX !=
int(xTarget) || iterInY != int(yTarget))
706 ocean_assert(mask[validIterInY * maskStrideElements + validIterInX] + 1 > 0);
708 if (mask[validIterInY * maskStrideElements + validIterInX] != 0xFF)
710 cost += CV::SumSquareDifferences::patch8BitPerChannelTemplate<tChannels, 1u>(frame, frame,
width_,
width_, validIterInX, validIterInY, validIterOutX, validIterOutY, framePaddingElements, framePaddingElements);
714 cost += CV::SumSquareDifferences::patch8BitPerChannelTemplate<tChannels, 1u>(frame, frame,
width_,
width_, validIterInX, validIterInY, validIterOutX, validIterOutY, framePaddingElements, framePaddingElements) * tBorderFactor;
724 return cost * spatialCostNormalization<tChannels>() / 25u;
727template <
unsigned int tChannels>
728void MappingI1::applyOneFrameMapping8BitPerChannelSubset(uint8_t*
const frame,
const uint8_t*
const mask,
const unsigned int frameStrideElements,
const unsigned int maskStrideElements,
const unsigned int xStart,
const unsigned int xWidth,
const unsigned int firstRow,
const unsigned int numberRows)
const
730 static_assert(tChannels >= 1u,
"Invalid channels!");
734 ocean_assert(xStart + xWidth <=
width_);
735 ocean_assert(firstRow + numberRows <=
height_);
737 ocean_assert(frameStrideElements >=
width_ * tChannels);
738 ocean_assert(maskStrideElements >=
width_);
740 for (
unsigned int y = firstRow; y < firstRow + numberRows; ++y)
742 DataType* framePixel = ((
DataType*)(frame + y * frameStrideElements)) + xStart;
743 const uint8_t* maskPixel = mask + y * maskStrideElements + xStart;
747 for (
unsigned int n = 0u; n < xWidth; ++n)
749 if (*maskPixel != 0xFF)
751 ocean_assert(mappingPixel->
isValid());
753 *framePixel = ((
const DataType*)(frame + mappingPixel->
y() * frameStrideElements))[mappingPixel->
x()];
bool isValid() const
Returns whether this pixel position object holds two valid parameters.
T y() const
Returns the vertical coordinate position of this object.
Definition PixelPosition.h:468
T x() const
Returns the horizontal coordinate position of this object.
Definition PixelPosition.h:456
unsigned int width_
Width of this pixel mapping object in pixel.
Definition Mapping.h:147
unsigned int height_
Height of this pixel mapping object in pixel.
Definition Mapping.h:150
This class implements the pixel mapping between source and target frames.
Definition MappingI1.h:49
MappingI1()
Creates an empty mapping object.
unsigned int spatialCost4Neighborhood(const unsigned int xTarget, const unsigned int yTarget, const unsigned int xSource, const unsigned int ySource, const uint8_t *targetMask, const unsigned int targetMaskPaddingElements, const unsigned int maxCost) const
Calculates the smallest/cheapest spatial cost for a given point in a four-neighborhood and normalizes...
Definition MappingI1.h:212
MappingI1 & operator=(const MappingI1 &pixelMapping)
Assigns another pixel mapping object to this one.
Definition MappingI1.h:260
unsigned int spatialCost8Neighborhood(const unsigned int xTarget, const unsigned int yTarget, const unsigned int xSource, const unsigned int ySource, const uint8_t *targetMask, const unsigned int targetMaskPaddingElements, const unsigned int maxCost) const
Calculates the smallest/cheapest spatial cost for a given point in a eight-neighborhood and normalize...
Definition MappingI1.h:226
unsigned int appearanceCost5x5(const unsigned int xTarget, const unsigned int yTarget, const unsigned int xSource, const unsigned int ySource, const uint8_t *frame, const uint8_t *mask, const unsigned int framePaddingElements, const unsigned int maskPaddingElements) const
Calculates the appearance cost for a given point in a given frame.
Definition MappingI1.h:650
void applyMapping(Frame &frame, const Frame &mask, const unsigned int xStart, const unsigned int xWidth, const unsigned int yStart, const unsigned int yHeight, Worker *worker=nullptr) const override
Applies the current mapping for one given frame.
void applyOneFrameMapping8BitPerChannel(uint8_t *const frame, const uint8_t *const mask, const unsigned int framePaddingElements, const unsigned int maskPaddingElements, const unsigned int xStart, const unsigned int xWidth, const unsigned int yStart, const unsigned int yHeight, Worker *worker=nullptr) const
Applies the current mapping for one given frame.
Definition MappingI1.h:240
MappingI1(const MappingI1 &pixelMapping)
Copies a mapping from a given mapping object.
void applyOneFrameMapping8BitPerChannelSubset(uint8_t *const frame, const uint8_t *const mask, const unsigned int frameStrideElements, const unsigned int maskStrideElements, const unsigned int xStart, const unsigned int xWidth, const unsigned int firstRow, const unsigned int numberRows) const
Applies the current mapping in a subset of one given frame.
Definition MappingI1.h:728
MappingI1(const unsigned int width, const unsigned int height)
Creates a new mapping object with defined dimension.
MappingI1(MappingI1 &&pixelMapping) noexcept
Move constructor.
This class implements a mapping with integer accuracy.
Definition MappingI.h:30
MappingI & operator=(const MappingI &pixelMapping)
Assign operator.
Definition MappingI.h:321
PixelPosition * mappingI_
Pixel mappings for each pixel.
Definition MappingI.h:171
static Caller< void > create(CT &object, typename MemberFunctionPointerMaker< CT, void, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass, NullClass >::Type function)
Creates a new caller container for a member function with no function parameter.
Definition Caller.h:3024
Template class allowing to define an array of data types.
Definition DataType.h:27
This class implements Ocean's image class.
Definition Frame.h:1808
This class implements a worker able to distribute function calls over different threads.
Definition Worker.h:33
bool executeFunction(const Function &function, const unsigned int first, const unsigned int size, const unsigned int firstIndex=(unsigned int)(-1), const unsigned int sizeIndex=(unsigned int)(-1), const unsigned int minimalIterations=1u, const unsigned int threadIndex=(unsigned int)(-1))
Executes a callback function separable by two function parameters.
unsigned int sqr(const char value)
Returns the square value of a given value.
Definition base/Utilities.h:1053
static unsigned int mirrorValue(const int value, const unsigned int size)
Mirrors a given value if necessary.
Definition base/Utilities.h:1231
The namespace covering the entire Ocean framework.
Definition Accessor.h:15
Default definition of a type with tBytes bytes.
Definition DataType.h:32