8 #ifndef META_OCEAN_CV_FRAME_FILTER_SCHARR_H
9 #define META_OCEAN_CV_FRAME_FILTER_SCHARR_H
123 template <
typename TTarget,
unsigned int tSourceChannels>
124 static inline void filterHorizontalVertical8BitPerChannel(
const uint8_t* source, TTarget* target,
const unsigned int width,
const unsigned int height,
const unsigned int sourcePaddingElements,
const unsigned int targetPaddingElements,
Worker* worker =
nullptr);
141 template <
typename TTarget,
unsigned int tSourceChannels>
142 static inline void filterDiagonal8BitPerChannel(
const uint8_t* source, TTarget* target,
const unsigned int width,
const unsigned int height,
const unsigned int sourcePaddingElements,
const unsigned int targetPaddingElements,
Worker* worker =
nullptr);
159 template <
typename TTarget,
unsigned int tSourceChannels>
160 static inline void filter8BitPerChannel(
const uint8_t* source, TTarget* target,
const unsigned int width,
const unsigned int height,
const unsigned int sourcePaddingElements,
const unsigned int targetPaddingElements,
Worker* worker =
nullptr);
177 template <
typename TTarget,
unsigned int tSourceChannels>
178 static inline void filterHorizontalVerticalMaximumAbsolute8BitPerChannel(
const uint8_t* source, TTarget* target,
const unsigned int width,
const unsigned int height,
const unsigned int sourcePaddingElements,
const unsigned int targetPaddingElements,
Worker* worker =
nullptr);
195 template <
typename TTarget,
unsigned int tSourceChannels>
196 static inline void filterMaximumAbsolute8BitPerChannel(
const uint8_t* source, TTarget* target,
const unsigned int width,
const unsigned int height,
const unsigned int sourcePaddingElements,
const unsigned int targetPaddingElements,
Worker* worker =
nullptr);
214 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
215 static void filterHorizontalVerticalRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int targetStrideElements);
231 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
232 static void filterDiagonalRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int targetStrideElements);
248 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
249 static void filterRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int targetStrideElements);
265 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
266 static void filterHorizontalVerticalMaximumAbsoluteRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int targetStrideElements);
282 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
283 static void filterMaximumAbsoluteRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int targetStrideElements);
286 template <
typename TTarget,
unsigned int tSourceChannels>
289 static_assert(std::is_same<TTarget, int8_t>::value || std::is_same<TTarget, int16_t>::value,
"Invalid target data type!");
290 static_assert(tSourceChannels >= 1u,
"Invalid channel number!");
292 ocean_assert(source !=
nullptr && target !=
nullptr);
293 ocean_assert(width >= 3u && height >= 3u);
296 constexpr
unsigned int tTargetChannels = tSourceChannels * 2u;
298 FrameChannels::applyRowOperator<uint8_t, TTarget, tSourceChannels, tTargetChannels>(source, target, width, height, sourcePaddingElements, targetPaddingElements, &filterHorizontalVerticalRow<uint8_t, TTarget, tSourceChannels, tTargetChannels>, worker);
301 template <
typename TTarget,
unsigned int tSourceChannels>
304 static_assert(std::is_same<TTarget, int8_t>::value || std::is_same<TTarget, int16_t>::value,
"Invalid target data type!");
305 static_assert(tSourceChannels >= 1u,
"Invalid channel number!");
307 ocean_assert(source !=
nullptr && target !=
nullptr);
308 ocean_assert(width >= 3u && height >= 3u);
311 constexpr
unsigned int tTargetChannels = tSourceChannels * 2u;
313 FrameChannels::applyRowOperator<uint8_t, TTarget, tSourceChannels, tTargetChannels>(source, target, width, height, sourcePaddingElements, targetPaddingElements, &filterDiagonalRow<uint8_t, TTarget, tSourceChannels, tTargetChannels>, worker);
316 template <
typename TTarget,
unsigned int tSourceChannels>
317 inline void FrameFilterScharr::filter8BitPerChannel(
const uint8_t* source, TTarget* target,
const unsigned int width,
const unsigned int height,
const unsigned int sourcePaddingElements,
const unsigned int targetPaddingElements,
Worker* worker)
319 static_assert(std::is_same<TTarget, int8_t>::value || std::is_same<TTarget, int16_t>::value,
"Invalid target data type!");
320 static_assert(tSourceChannels >= 1u,
"Invalid channel number!");
322 ocean_assert(source !=
nullptr && target !=
nullptr);
323 ocean_assert(width >= 3u && height >= 3u);
326 constexpr
unsigned int tTargetChannels = tSourceChannels * 4u;
328 FrameChannels::applyRowOperator<uint8_t, TTarget, tSourceChannels, tTargetChannels>(source, target, width, height, sourcePaddingElements, targetPaddingElements, &filterRow<uint8_t, TTarget, tSourceChannels, tTargetChannels>, worker);
331 template <
typename TTarget,
unsigned int tSourceChannels>
334 static_assert(std::is_same<TTarget, uint8_t>::value || std::is_same<TTarget, uint16_t>::value,
"Invalid target data type!");
335 static_assert(tSourceChannels >= 1u,
"Invalid channel number!");
337 ocean_assert(source !=
nullptr && target !=
nullptr);
338 ocean_assert(width >= 3u && height >= 3u);
341 constexpr
unsigned int tTargetChannels = tSourceChannels;
343 FrameChannels::applyRowOperator<uint8_t, TTarget, tSourceChannels, tTargetChannels>(source, target, width, height, sourcePaddingElements, targetPaddingElements, &filterHorizontalVerticalMaximumAbsoluteRow<uint8_t, TTarget, tSourceChannels, tTargetChannels>, worker);
346 template <
typename TTarget,
unsigned int tSourceChannels>
349 static_assert(std::is_same<TTarget, uint8_t>::value || std::is_same<TTarget, uint16_t>::value,
"Invalid target data type!");
350 static_assert(tSourceChannels >= 1u,
"Invalid channel number!");
352 ocean_assert(source !=
nullptr && target !=
nullptr);
353 ocean_assert(width >= 3u && height >= 3u);
356 constexpr
unsigned int tTargetChannels = tSourceChannels;
358 FrameChannels::applyRowOperator<uint8_t, TTarget, tSourceChannels, tTargetChannels>(source, target, width, height, sourcePaddingElements, targetPaddingElements, &filterMaximumAbsoluteRow<uint8_t, TTarget, tSourceChannels, tTargetChannels>, worker);
361 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
364 static_assert(std::is_same<TSource, uint8_t>::value,
"Invalid source data type!");
365 static_assert(std::is_same<TTarget, int8_t>::value || std::is_same<TTarget, int16_t>::value,
"Invalid target data type!");
367 static_assert(tSourceChannels >= 1u,
"Invalid source channel number!");
368 static_assert(tTargetChannels == tSourceChannels * 2u,
"Invalid target channel number!");
370 ocean_assert(width >= 3u && height >= 3u);
372 if (rowIndex == 0u || rowIndex == height - 1u)
376 memset(targetRow, 0, width * tTargetChannels *
sizeof(TTarget));
380 const uint8_t* source0 = sourceRow - sourceStrideElements;
381 const uint8_t* source1 = sourceRow;
382 const uint8_t* source2 = sourceRow + sourceStrideElements;
386 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
388 targetRow[n] = TTarget(0);
391 targetRow += tTargetChannels;
393 for (
unsigned int x = 1u; x < width - 1u; ++x)
395 if constexpr (std::is_same<TTarget, int8_t>::value)
397 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
403 *targetRow++ = TTarget((3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1))) / 32);
409 *targetRow++ = TTarget((3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels))) / 32);
418 ocean_assert((std::is_same<TTarget, int16_t>::value));
420 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
426 *targetRow++ = TTarget(3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1)));
432 *targetRow++ = TTarget(3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels)));
442 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
444 targetRow[n] = TTarget(0);
448 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
449 void FrameFilterScharr::filterDiagonalRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int )
451 static_assert(std::is_same<TSource, uint8_t>::value,
"Invalid source data type!");
452 static_assert(std::is_same<TTarget, int8_t>::value || std::is_same<TTarget, int16_t>::value,
"Invalid target data type!");
454 static_assert(tSourceChannels >= 1u,
"Invalid source channel number!");
455 static_assert(tTargetChannels == tSourceChannels * 2u,
"Invalid target channel number!");
457 ocean_assert(width >= 3u && height >= 3u);
459 if (rowIndex == 0u || rowIndex == height - 1u)
463 memset(targetRow, 0, width * tTargetChannels *
sizeof(TTarget));
467 const uint8_t* source0 = sourceRow - sourceStrideElements;
468 const uint8_t* source1 = sourceRow;
469 const uint8_t* source2 = sourceRow + sourceStrideElements;
473 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
475 targetRow[n] = TTarget(0);
478 targetRow += tTargetChannels;
480 for (
unsigned int x = 1u; x < width - 1u; ++x)
482 if constexpr (std::is_same<TTarget, int8_t>::value)
484 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
490 *targetRow++ = TTarget((3 * (*(source1 + tSourceChannels * 2u) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1)) + 10 * (*(source2 + tSourceChannels * 2u) - *(source0))) / 32);
496 *targetRow++ = TTarget((3 * (*(source1) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1 + tSourceChannels * 2u)) + 10 * (*(source2) - *(source0 + tSourceChannels * 2u))) / 32);
505 ocean_assert((std::is_same<TTarget, int16_t>::value));
507 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
513 *targetRow++ = TTarget(3 * (*(source1 + tSourceChannels * 2u) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1)) + 10 * (*(source2 + tSourceChannels * 2u) - *(source0)));
519 *targetRow++ = TTarget(3 * (*(source1) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1 + tSourceChannels * 2u)) + 10 * (*(source2) - *(source0 + tSourceChannels * 2u)));
529 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
531 targetRow[n] = TTarget(0);
535 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
536 void FrameFilterScharr::filterRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int )
538 static_assert(std::is_same<TSource, uint8_t>::value,
"Invalid source data type!");
539 static_assert(std::is_same<TTarget, int8_t>::value || std::is_same<TTarget, int16_t>::value,
"Invalid target data type!");
541 static_assert(tSourceChannels >= 1u,
"Invalid source channel number!");
542 static_assert(tTargetChannels == tSourceChannels * 4u,
"Invalid target channel number!");
544 ocean_assert(width >= 3u && height >= 3u);
546 if (rowIndex == 0u || rowIndex == height - 1u)
550 memset(targetRow, 0, width * tTargetChannels *
sizeof(TTarget));
554 const uint8_t* source0 = sourceRow - sourceStrideElements;
555 const uint8_t* source1 = sourceRow;
556 const uint8_t* source2 = sourceRow + sourceStrideElements;
560 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
562 targetRow[n] = TTarget(0);
565 targetRow += tTargetChannels;
567 for (
unsigned int x = 1u; x < width - 1u; ++x)
569 if constexpr (std::is_same<TTarget, int8_t>::value)
571 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
577 *targetRow++ = TTarget((3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1))) / 32);
583 *targetRow++ = TTarget((3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels))) / 32);
589 *targetRow++ = TTarget((3 * (*(source1 + tSourceChannels * 2u) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1)) + 10 * (*(source2 + tSourceChannels * 2u) - *(source0))) / 32);
595 *targetRow++ = TTarget((3 * (*(source1) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1 + tSourceChannels * 2u)) + 10 * (*(source2) - *(source0 + tSourceChannels * 2u))) / 32);
604 ocean_assert((std::is_same<TTarget, int16_t>::value));
606 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
612 *targetRow++ = TTarget(3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1)));
618 *targetRow++ = TTarget(3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels)));
624 *targetRow++ = TTarget(3 * (*(source1 + tSourceChannels * 2u) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1)) + 10 * (*(source2 + tSourceChannels * 2u) - *(source0)));
630 *targetRow++ = TTarget(3 * (*(source1) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1 + tSourceChannels * 2u)) + 10 * (*(source2) - *(source0 + tSourceChannels * 2u)));
640 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
642 targetRow[n] = TTarget(0);
646 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
649 static_assert(std::is_same<TSource, uint8_t>::value,
"Invalid source data type!");
650 static_assert(std::is_same<TTarget, uint8_t>::value || std::is_same<TTarget, uint16_t>::value,
"Invalid target data type!");
652 static_assert(tSourceChannels >= 1u,
"Invalid source channel number!");
653 static_assert(tTargetChannels == tSourceChannels,
"Invalid target channel number!");
655 ocean_assert(width >= 3u && height >= 3u);
657 if (rowIndex == 0u || rowIndex == height - 1u)
661 memset(targetRow, 0, width * tTargetChannels *
sizeof(TTarget));
665 const uint8_t* source0 = sourceRow - sourceStrideElements;
666 const uint8_t* source1 = sourceRow;
667 const uint8_t* source2 = sourceRow + sourceStrideElements;
671 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
673 targetRow[n] = TTarget(0);
676 targetRow += tTargetChannels;
678 for (
unsigned int x = 1u; x < width - 1u; ++x)
680 if constexpr (std::is_same<TTarget, uint8_t>::value)
682 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
688 *targetRow++ = TTarget((max(abs(int16_t(3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1)))),
694 abs(int16_t(3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels))))) + 8u) / 16u);
703 ocean_assert((std::is_same<TTarget, uint16_t>::value));
705 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
711 *targetRow++ = TTarget(max(abs(int16_t(3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1)))),
717 abs(int16_t(3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels))))));
727 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
729 targetRow[n] = TTarget(0);
733 template <
typename TSource,
typename TTarget,
unsigned int tSourceChannels,
unsigned int tTargetChannels>
734 void FrameFilterScharr::filterMaximumAbsoluteRow(
const TSource* sourceRow, TTarget* targetRow,
const unsigned int width,
const unsigned int height,
unsigned int rowIndex,
const unsigned int sourceStrideElements,
const unsigned int )
736 static_assert(std::is_same<TSource, uint8_t>::value,
"Invalid source data type!");
737 static_assert(std::is_same<TTarget, uint8_t>::value || std::is_same<TTarget, uint16_t>::value,
"Invalid target data type!");
739 static_assert(tSourceChannels >= 1u,
"Invalid source channel number!");
740 static_assert(tTargetChannels == tSourceChannels,
"Invalid target channel number!");
742 ocean_assert(width >= 3u && height >= 3u);
744 if (rowIndex == 0u || rowIndex == height - 1u)
748 memset(targetRow, 0, width * tTargetChannels *
sizeof(TTarget));
752 const uint8_t* source0 = sourceRow - sourceStrideElements;
753 const uint8_t* source1 = sourceRow;
754 const uint8_t* source2 = sourceRow + sourceStrideElements;
758 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
760 targetRow[n] = TTarget(0);
763 targetRow += tTargetChannels;
765 for (
unsigned int x = 1u; x < width - 1u; ++x)
767 if constexpr (std::is_same<TTarget, uint8_t>::value)
769 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
775 *targetRow++ = TTarget((max(max(abs(int16_t(3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1)))),
781 abs(int16_t(3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels))))),
787 max(abs(int16_t(3 * (*(source1 + tSourceChannels * 2u) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1)) + 10 * (*(source2 + tSourceChannels * 2u) - *(source0)))),
793 abs(int16_t(3 * (*(source1) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1 + tSourceChannels * 2u)) + 10 * (*(source2) - *(source0 + tSourceChannels * 2u)))))) + 8u) / 16u);
802 ocean_assert((std::is_same<TTarget, uint16_t>::value));
804 for (
unsigned int n = 0u; n < tSourceChannels; ++n)
810 *targetRow++ = TTarget(max(max(abs(int16_t(3 * (*(source0 + tSourceChannels * 2u) - *(source0) + *(source2 + tSourceChannels * 2u) - *(source2)) + 10 * (*(source1 + tSourceChannels * 2u) - *(source1)))),
816 abs(int16_t(3 * (*(source2) + *(source2 + tSourceChannels * 2u) - *(source0) - *(source0 + tSourceChannels * 2u)) + 10 * (*(source2 + tSourceChannels) - *(source0 + tSourceChannels))))),
822 max(abs(int16_t(3 * (*(source1 + tSourceChannels * 2u) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1)) + 10 * (*(source2 + tSourceChannels * 2u) - *(source0)))),
828 abs(int16_t(3 * (*(source1) + *(source2 + tSourceChannels) - *(source0 + tSourceChannels) - *(source1 + tSourceChannels * 2u)) + 10 * (*(source2) - *(source0 + tSourceChannels * 2u)))))));
838 for (
unsigned int n = 0u; n < tTargetChannels; ++n)
840 targetRow[n] = TTarget(0);
The following comfort class provides comfortable functions simplifying prototyping applications but a...
Definition: FrameFilterScharr.h:52
static bool filterDiagonal(const Frame &source, Frame &target, Worker *worker=nullptr)
Diagonal (45 and 135 degree) Scharr filer for images.
static bool filterHorizontalVerticalMaximumAbsolute(const Frame &source, Frame &target, Worker *worker=nullptr)
Determines the maximum of the absolute horizontal and vertical Scharr filter.
static bool filter(const Frame &source, Frame &target, Worker *worker=nullptr)
Horizontal, vertical, and diagonal Scharr filer for images.
static bool filterMaximumAbsolute(const Frame &source, Frame &target, Worker *worker=nullptr)
Determines the maximum of the absolute horizontal, vertical, and diagonal Scharr filter.
static bool filterHorizontalVertical(const Frame &source, Frame &target, Worker *worker=nullptr)
Horizontal and vertical Scharr filer for images.
This class implements a Scharr filter.
Definition: FrameFilterScharr.h:43
static void filterHorizontalVerticalRow(const TSource *sourceRow, TTarget *targetRow, const unsigned int width, const unsigned int height, unsigned int rowIndex, const unsigned int sourceStrideElements, const unsigned int targetStrideElements)
Applies the horizontal and vertical Scharr filter to one row of a source frame.
Definition: FrameFilterScharr.h:362
static void filterHorizontalVertical8BitPerChannel(const uint8_t *source, TTarget *target, const unsigned int width, const unsigned int height, const unsigned int sourcePaddingElements, const unsigned int targetPaddingElements, Worker *worker=nullptr)
Horizontal and vertical Scharr filer for images.
Definition: FrameFilterScharr.h:287
static void filter8BitPerChannel(const uint8_t *source, TTarget *target, const unsigned int width, const unsigned int height, const unsigned int sourcePaddingElements, const unsigned int targetPaddingElements, Worker *worker=nullptr)
Horizontal, vertical, and diagonal Scharr filer for images.
Definition: FrameFilterScharr.h:317
static void filterMaximumAbsolute8BitPerChannel(const uint8_t *source, TTarget *target, const unsigned int width, const unsigned int height, const unsigned int sourcePaddingElements, const unsigned int targetPaddingElements, Worker *worker=nullptr)
Determines the maximum of the absolute horizontal, vertical, and diagonal Scharr filter.
Definition: FrameFilterScharr.h:347
static void filterHorizontalVerticalMaximumAbsoluteRow(const TSource *sourceRow, TTarget *targetRow, const unsigned int width, const unsigned int height, unsigned int rowIndex, const unsigned int sourceStrideElements, const unsigned int targetStrideElements)
Applies the maximum of the absolute horizontal and vertical Scharr filter to one row of a source fram...
Definition: FrameFilterScharr.h:647
static void filterDiagonalRow(const TSource *sourceRow, TTarget *targetRow, const unsigned int width, const unsigned int height, unsigned int rowIndex, const unsigned int sourceStrideElements, const unsigned int targetStrideElements)
Applies the diagonal Scharr filter to one row of a source frame.
Definition: FrameFilterScharr.h:449
static void filterRow(const TSource *sourceRow, TTarget *targetRow, const unsigned int width, const unsigned int height, unsigned int rowIndex, const unsigned int sourceStrideElements, const unsigned int targetStrideElements)
Applies the horizontal, vertical, and diagonal Scharr filter to one row of a source frame.
Definition: FrameFilterScharr.h:536
static void filterHorizontalVerticalMaximumAbsolute8BitPerChannel(const uint8_t *source, TTarget *target, const unsigned int width, const unsigned int height, const unsigned int sourcePaddingElements, const unsigned int targetPaddingElements, Worker *worker=nullptr)
Determines the maximum of the absolute horizontal and vertical Scharr filter.
Definition: FrameFilterScharr.h:332
static void filterDiagonal8BitPerChannel(const uint8_t *source, TTarget *target, const unsigned int width, const unsigned int height, const unsigned int sourcePaddingElements, const unsigned int targetPaddingElements, Worker *worker=nullptr)
Diagonal (45 and 135 degree) Scharr filer for images.
Definition: FrameFilterScharr.h:302
static void filterMaximumAbsoluteRow(const TSource *sourceRow, TTarget *targetRow, const unsigned int width, const unsigned int height, unsigned int rowIndex, const unsigned int sourceStrideElements, const unsigned int targetStrideElements)
Applies the maximum of the absolute horizontal, vertical, and diagonal Scharr filter to one row of a ...
Definition: FrameFilterScharr.h:734
This class implements Ocean's image class.
Definition: Frame.h:1792
This class implements a worker able to distribute function calls over different threads.
Definition: Worker.h:33
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15