Ask Your Question

Adean Magarn's profile - activity

2014-11-13 02:55:23 -0600 asked a question How to display detected object width and height using CvCameraViewListener2

my android opencv app draws react of detected object on video stream using implements CvCameraViewListener2 up to here works fine.

Core.rectangle(mRgbImage, rect.tl(), rect.br(), new Scalar(255, 0, 0),2);

now i need to display detected object width (rect.height) and height(rect.width) on EditText. but the problem is onCameraFrame will not allow to display or return values. please help me. smiler question but still not answered.

2014-09-15 13:09:53 -0600 commented answer Drawing bounding box in java

Core.rectangle(contoursFrame, new Point(rect.x,rect.y), new Point(rect.x+rect.width,rect.y+rect.height), (255, 0, 0, 255), 3); is having error for me Core.rectangle(contoursFrame, rect.tl(), rect.br(), new Scalar(255, 0, 0),1, 8,0); is working perfectly

2014-09-15 11:50:14 -0600 received badge  Supporter (source)
2014-09-10 10:41:13 -0600 received badge  Organizer (source)
2014-09-10 10:30:23 -0600 received badge  Editor (source)
2014-09-10 10:27:28 -0600 asked a question OpenCV + Android + Vehicle number Plate Recognition

Hi I'm developing a Android app to detect vehicle number plate. i'm using this tutorial and i did image processing up to findContours level of image. Now i need to convert following C++ code to Opencv Based Android java. I confuse with vector::iterator Please help me.

   std::vector rects;  
   std::vector<std::vector >::iterator itc = contours.begin();  
    while (itc != contours.end())  
    {  
    cv::RotatedRect mr = cv::minAreaRect(cv::Mat(*itc));     

        float area = fabs(cv::contourArea(*itc));  
            float bbArea=mr.size.width * mr.size.height;  
            float ratio = area/bbArea;  

            if( (ratio < 0.45) || (bbArea < 400) ){  
                itc= contours.erase(itc);  
            }else{  
                ++itc;  
                rects.push_back(mr);  
            }  
    }