# LeeYangOpencvToolBox **Repository Path**: yuliyang/LeeYangOpencvToolBox ## Basic Information - **Project Name**: LeeYangOpencvToolBox - **Description**: opencv toolbox for myself - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2015-03-27 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README #GetRectInfo > this tool is build in Qt Platform and Opencv , it import image from drag movement,and get the Rect information Select By Mouse ![](GetRectInfo/2015-03-19_00001.jpg) ![](GetRectInfo/2015-03-19_00002.jpg) ![](GetRectInfo/2015-03-19_00003.jpg) ![](GetRectInfo/2015-03-19_00004.jpg) #testrect test rect is a class wrapped that get Rect Information From mouse Select it is easy to use ####example ``` #include #include "initrect.h" using namespace std; int main() { String filename ="C:\\Users\\leeyoung\\Desktop\\GetRectInfo\\2015-03-19_00001.jpg"; Mat image = imread(filename.c_str ()); /** * @brief object init from cv::Mat */ InitRect object(image,String("Window Title")); /** * @brief object init from image file */ // InitRect object(filename,String("Window Title")); Rect myrect = object.Select (); // press ESC to finished Select printf ("x: %d y: %d width: %d height: %d",myrect.x,myrect.y,myrect.width,myrect.height); return 0; } ``` ![](images/2015-03-19_00009.jpg) ![](images/2015-03-19_00010.jpg) ![](images/2015-03-19_00011.jpg)