Commit e792ee89 authored by Vadim Pisarevsky's avatar Vadim Pisarevsky

Merge pull request #6243 from mshabunin:hal_morph

parents e547916e 83379695
......@@ -221,6 +221,18 @@ static inline IppiSize ippiSize(const cv::Size & _size)
return size;
}
static inline IppiPoint ippiPoint(const cv::Point & _point)
{
IppiPoint point = { _point.x, _point.y };
return point;
}
static inline IppiPoint ippiPoint(int x, int y)
{
IppiPoint point = { x, y };
return point;
}
static inline IppiBorderType ippiGetBorderType(int borderTypeNI)
{
return borderTypeNI == cv::BORDER_CONSTANT ? ippBorderConst :
......
......@@ -44,6 +44,22 @@ struct CV_EXPORTS SepFilter2D
virtual ~SepFilter2D() {}
};
struct CV_EXPORTS MorphContext
{
static Ptr<MorphContext> create(int op, int src_type, int dst_type, int max_width, int max_height,
int kernel_type, uchar * kernel_data, size_t kernel_step,
int kernel_width, int kernel_height,
int anchor_x, int anchor_y,
int borderType, const double borderValue[4],
int iterations, bool isSubmatrix, bool allowInplace);
virtual void apply(uchar * src_data, size_t src_step, uchar * dst_data, size_t dst_step, int width, int height,
int roi_width, int roi_height, int roi_x, int roi_y,
int roi_width2, int roi_height2, int roi_x2, int roi_y2) = 0;
virtual ~MorphContext() {}
};
//! @}
}}
......
......@@ -37,6 +37,8 @@ the use of this software, even if advised of the possibility of such damage.
#ifndef __OPENCV_IMGPROC_FILTERENGINE_HPP__
#define __OPENCV_IMGPROC_FILTERENGINE_HPP__
#include "opencv2/imgproc.hpp"
namespace cv
{
......
......@@ -21,6 +21,14 @@ inline int hal_ni_sepFilterFree(cvhalFilter2D *) { return CV_HAL_ERROR_NOT_IMPLE
#define cv_hal_sepFilter hal_ni_sepFilter
#define cv_hal_sepFilterFree hal_ni_sepFilterFree
inline int hal_ni_morphInit(cvhalFilter2D **, int, int, int, int, int, int, uchar *, size_t, int, int, int, int, int, const double[4], int, bool, bool) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
inline int hal_ni_morph(cvhalFilter2D *, uchar *, size_t, uchar *, size_t, int, int, int, int, int, int, int, int, int, int) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
inline int hal_ni_morphFree(cvhalFilter2D *) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
#define cv_hal_morphInit hal_ni_morphInit
#define cv_hal_morph hal_ni_morph
#define cv_hal_morphFree hal_ni_morphFree
#include "custom_hal.hpp"
#endif // OPENCV_IMGPROC_HAL_REPLACEMENT_HPP
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment