未验证 提交 3efca965 编写于 作者: H huzhiqiang 提交者: GitHub

[CV Lib] Fix the issue that tiny_publish dynamic lib can not link to cv_lib

上级 56a3e8d2
...@@ -30,6 +30,7 @@ namespace cv { ...@@ -30,6 +30,7 @@ namespace cv {
#define Radians2Degrees(radians) ((radians) * (180 / SK_ScalarPI)) #define Radians2Degrees(radians) ((radians) * (180 / SK_ScalarPI))
#define ScalarNearlyZero (1.0f / (1 << 12)) #define ScalarNearlyZero (1.0f / (1 << 12))
// init // init
__attribute__((visibility("default")))
ImagePreprocess::ImagePreprocess(ImageFormat srcFormat, ImagePreprocess::ImagePreprocess(ImageFormat srcFormat,
ImageFormat dstFormat, ImageFormat dstFormat,
TransParam param) { TransParam param) {
...@@ -37,7 +38,8 @@ ImagePreprocess::ImagePreprocess(ImageFormat srcFormat, ...@@ -37,7 +38,8 @@ ImagePreprocess::ImagePreprocess(ImageFormat srcFormat,
this->dstFormat_ = dstFormat; this->dstFormat_ = dstFormat;
this->transParam_ = param; this->transParam_ = param;
} }
void ImagePreprocess::imageConvert(const uint8_t* src, uint8_t* dst) { __attribute__((visibility("default"))) void ImagePreprocess::imageConvert(
const uint8_t* src, uint8_t* dst) {
ImageConvert img_convert; ImageConvert img_convert;
img_convert.choose(src, img_convert.choose(src,
dst, dst,
...@@ -47,7 +49,8 @@ void ImagePreprocess::imageConvert(const uint8_t* src, uint8_t* dst) { ...@@ -47,7 +49,8 @@ void ImagePreprocess::imageConvert(const uint8_t* src, uint8_t* dst) {
this->transParam_.ih); this->transParam_.ih);
} }
void ImagePreprocess::imageConvert(const uint8_t* src, __attribute__((visibility("default"))) void ImagePreprocess::imageConvert(
const uint8_t* src,
uint8_t* dst, uint8_t* dst,
ImageFormat srcFormat, ImageFormat srcFormat,
ImageFormat dstFormat) { ImageFormat dstFormat) {
...@@ -60,7 +63,8 @@ void ImagePreprocess::imageConvert(const uint8_t* src, ...@@ -60,7 +63,8 @@ void ImagePreprocess::imageConvert(const uint8_t* src,
this->transParam_.ih); this->transParam_.ih);
} }
void ImagePreprocess::imageResize(const uint8_t* src, __attribute__((visibility("default"))) void ImagePreprocess::imageResize(
const uint8_t* src,
uint8_t* dst, uint8_t* dst,
ImageFormat srcFormat, ImageFormat srcFormat,
int srcw, int srcw,
...@@ -71,7 +75,8 @@ void ImagePreprocess::imageResize(const uint8_t* src, ...@@ -71,7 +75,8 @@ void ImagePreprocess::imageResize(const uint8_t* src,
img_resize.choose(src, dst, srcFormat, srcw, srch, dstw, dsth); img_resize.choose(src, dst, srcFormat, srcw, srch, dstw, dsth);
} }
void ImagePreprocess::imageResize(const uint8_t* src, uint8_t* dst) { __attribute__((visibility("default"))) void ImagePreprocess::imageResize(
const uint8_t* src, uint8_t* dst) {
int srcw = this->transParam_.iw; int srcw = this->transParam_.iw;
int srch = this->transParam_.ih; int srch = this->transParam_.ih;
int dstw = this->transParam_.ow; int dstw = this->transParam_.ow;
...@@ -81,7 +86,8 @@ void ImagePreprocess::imageResize(const uint8_t* src, uint8_t* dst) { ...@@ -81,7 +86,8 @@ void ImagePreprocess::imageResize(const uint8_t* src, uint8_t* dst) {
img_resize.choose(src, dst, srcFormat, srcw, srch, dstw, dsth); img_resize.choose(src, dst, srcFormat, srcw, srch, dstw, dsth);
} }
void ImagePreprocess::imageRotate(const uint8_t* src, __attribute__((visibility("default"))) void ImagePreprocess::imageRotate(
const uint8_t* src,
uint8_t* dst, uint8_t* dst,
ImageFormat srcFormat, ImageFormat srcFormat,
int srcw, int srcw,
...@@ -91,7 +97,8 @@ void ImagePreprocess::imageRotate(const uint8_t* src, ...@@ -91,7 +97,8 @@ void ImagePreprocess::imageRotate(const uint8_t* src,
img_rotate.choose(src, dst, srcFormat, srcw, srch, degree); img_rotate.choose(src, dst, srcFormat, srcw, srch, degree);
} }
void ImagePreprocess::imageRotate(const uint8_t* src, uint8_t* dst) { __attribute__((visibility("default"))) void ImagePreprocess::imageRotate(
const uint8_t* src, uint8_t* dst) {
auto srcw = this->transParam_.ow; auto srcw = this->transParam_.ow;
auto srch = this->transParam_.oh; auto srch = this->transParam_.oh;
auto srcFormat = this->dstFormat_; auto srcFormat = this->dstFormat_;
...@@ -100,7 +107,8 @@ void ImagePreprocess::imageRotate(const uint8_t* src, uint8_t* dst) { ...@@ -100,7 +107,8 @@ void ImagePreprocess::imageRotate(const uint8_t* src, uint8_t* dst) {
img_rotate.choose(src, dst, srcFormat, srcw, srch, degree); img_rotate.choose(src, dst, srcFormat, srcw, srch, degree);
} }
void ImagePreprocess::imageFlip(const uint8_t* src, __attribute__((visibility("default"))) void ImagePreprocess::imageFlip(
const uint8_t* src,
uint8_t* dst, uint8_t* dst,
ImageFormat srcFormat, ImageFormat srcFormat,
int srcw, int srcw,
...@@ -110,7 +118,8 @@ void ImagePreprocess::imageFlip(const uint8_t* src, ...@@ -110,7 +118,8 @@ void ImagePreprocess::imageFlip(const uint8_t* src,
img_flip.choose(src, dst, srcFormat, srcw, srch, flip_param); img_flip.choose(src, dst, srcFormat, srcw, srch, flip_param);
} }
void ImagePreprocess::imageFlip(const uint8_t* src, uint8_t* dst) { __attribute__((visibility("default"))) void ImagePreprocess::imageFlip(
const uint8_t* src, uint8_t* dst) {
auto srcw = this->transParam_.ow; auto srcw = this->transParam_.ow;
auto srch = this->transParam_.oh; auto srch = this->transParam_.oh;
auto srcFormat = this->dstFormat_; auto srcFormat = this->dstFormat_;
...@@ -119,7 +128,8 @@ void ImagePreprocess::imageFlip(const uint8_t* src, uint8_t* dst) { ...@@ -119,7 +128,8 @@ void ImagePreprocess::imageFlip(const uint8_t* src, uint8_t* dst) {
img_flip.choose(src, dst, srcFormat, srcw, srch, flip_param); img_flip.choose(src, dst, srcFormat, srcw, srch, flip_param);
} }
void ImagePreprocess::image2Tensor(const uint8_t* src, __attribute__((visibility("default"))) void ImagePreprocess::image2Tensor(
const uint8_t* src,
Tensor* dstTensor, Tensor* dstTensor,
ImageFormat srcFormat, ImageFormat srcFormat,
int srcw, int srcw,
...@@ -132,7 +142,8 @@ void ImagePreprocess::image2Tensor(const uint8_t* src, ...@@ -132,7 +142,8 @@ void ImagePreprocess::image2Tensor(const uint8_t* src,
src, dstTensor, srcFormat, layout, srcw, srch, means, scales); src, dstTensor, srcFormat, layout, srcw, srch, means, scales);
} }
void ImagePreprocess::image2Tensor(const uint8_t* src, __attribute__((visibility("default"))) void ImagePreprocess::image2Tensor(
const uint8_t* src,
Tensor* dstTensor, Tensor* dstTensor,
LayoutType layout, LayoutType layout,
float* means, float* means,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册