1 2 /** 3 * @file WrapperIHaasImageProc.h 4 * @author HaasAI Group 5 * @version V1.0.0 6 * @date 2021-01-10 7 * @license GNU General Public License (GPL) 8 * @brief 9 * @attention 10 * This file is part of HaasAI. \n 11 * This program is free software; you can redistribute it and/or modify \n 12 * it under the terms of the GNU General Public License version 3 as \n 13 * published by the Free Software Foundation. \n 14 * You should have received a copy of the GNU General Public License \n 15 * along with HaasAI. If not, see <http://www.gnu.org/licenses/>. \n 16 * Unless required by applicable law or agreed to in writing, software \n 17 * distributed under the License is distributed on an "AS IS" BASIS, \n 18 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. \n 19 * See the License for the specific language governing permissions and \n 20 * limitations under the License. \n 21 * \n 22 * @htmlonly 23 * <span style="font-weight: bold">History</span> 24 * @endhtmlonly 25 * Version|Author|Date|Describe 26 * ------|----|------|-------- 27 * V1.0|HaasAI Group|2021-01-10|Create File 28 * <h2><center>©COPYRIGHT 2021 WELLCASA All Rights Reserved.</center></h2> 29 */ 30 #ifndef WRAPPER_IHAAS_IMAGE_PROC_H 31 #define WRAPPER_IHAAS_IMAGE_PROC_H 32 33 #include "base/include/base/HaasCommonImage.h" 34 #include "base/include/base/HaasImageProcDef.h" 35 #ifdef __cplusplus 36 extern "C" { 37 #endif 38 39 void* ImageProcCreateInstance(ImageProcType_t type); 40 void ImageProcDestoryInstance(void* instance); 41 int ImageProcOpen(void* instance); 42 int ImageProcClose(void* instance); 43 int ImageProcCvtColor(void* instance, const ImageBuffer_t* src, PixelFmt_t dst_format, 44 ImageBuffer_t** dst); 45 int ImageProcResize(void* instance, const ImageBuffer_t* src, const ImageSize_t dst_size, 46 ImageBuffer_t** dst); 47 int ImageProcImgCopy(void* instance, const ImageBuffer_t* src, ImageBuffer_t** dst); 48 int ImageProcRectangle(void* instance, const ImageBuffer_t* src, int32_t left, int32_t top, 49 int32_t right, int32_t bottom); 50 int ImageProcCircle(void* instance, const ImageBuffer_t* src, int32_t center_x, int32_t center_y, 51 int32_t radius); 52 int ImageProcDrawMarker(void* instance, const ImageBuffer_t* src, Point_t *pt, int32_t type); 53 int ImageProcFillPoly(void* instance, const ImageBuffer_t* src, Point_t** pts, int32_t color); 54 int ImageProcPutText(void* instance, const ImageBuffer_t* src, char* text, int32_t left, 55 int32_t top); 56 int ImageProcDilateErode(void* instance, const ImageBuffer_t* src, ImageBuffer_t* dst, 57 int32_t iMode, int32_t iThresh); 58 void ImageProcImageAdd(void* instance, const ImageBuffer_t* src, ImageBuffer_t* added, 59 ImageBuffer_t* dst); 60 void ImageProcImageMinus(void* instance, const ImageBuffer_t* src, ImageBuffer_t* minused, 61 ImageBuffer_t* dst); 62 void ImageProcImageElementMultiply(void* instance, const ImageBuffer_t* src, 63 ImageBuffer_t* multiplied, ImageBuffer_t* dst); 64 void ImageProcImageElementDivide(void* instance, const ImageBuffer_t* src, 65 ImageBuffer_t* divied, ImageBuffer_t* dst); 66 int ImageProcWriteImageToFile(void* instance, const ImageBuffer_t* src, char* file_name); 67 68 #ifdef __cplusplus 69 }; 70 #endif 71 72 #endif 73