Ask Your Question

Nagaraj's profile - activity

2020-11-02 11:18:39 -0600 received badge  Nice Question (source)
2014-05-28 01:13:16 -0600 commented answer Tilted image reconstruction

ok thanku :)

2014-05-27 06:37:24 -0600 answered a question Tilted image reconstruction

image description

@Witek, @zerog80, Hi I am beginner to opencv, I tried upto find mask.

My code goes here:

include "opencv2/highgui/highgui.hpp"

include "opencv2/imgproc/imgproc.hpp"

include <iostream>

using namespace std; using namespace cv;

int main( ){ Mat src1; Mat src=imread("img.png",1); Mat thr,gray;

cvtColor(src,gray,CV_BGR2GRAY);

//adaptiveThreshold(gray,thr,255,ADAPTIVE_THRESH_MEAN_C, THRESH_BINARY,99,7);

threshold(gray, thr, 0, 255, CV_THRESH_BINARY | CV_THRESH_OTSU); namedWindow( "gryimage", 1 ); imshow( "gryimage", thr);

vector< vector <point> > contours; // Vector for storing contour vector< Vec4i > hierarchy;

int largest_contour_index=0; int largest_area=0; Mat mask(src.rows,src.cols,CV_8UC1,Scalar::all(0)); //create destination image

findContours( thr.clone(), contours, hierarchy,CV_RETR_EXTERNAL, CV_CHAIN_APPROX_SIMPLE ); // Find the contours in the image for( int i = 0; i< contours.size(); i++ ) // iterate through each contour. { double a=contourArea( contours[i],false); // Find the area of contour if(a>largest_area){ largest_area=a; largest_contour_index=i; //Store the index of largest contour } }

vector<vector<point> >hull(1); convexHull(contours[largest_contour_index], hull[0],false,true ); drawContours( mask, hull, 0, Scalar(125), -1, 8, vector<vec4i>(), 0, Point() ); namedWindow( "mask Image", 1 ); imshow( "mask Image", mask ); waitKey(0); return 0;

}

My question is how to find angle by using corner points ?

2014-05-27 06:24:36 -0600 commented answer Tilted image reconstruction

Thanks for replay :)

2014-05-21 01:26:31 -0600 commented answer Tilted image reconstruction

Hi zerog80,

Thanks for reply .

2014-05-20 08:08:08 -0600 asked a question Tilted image reconstruction

image description

Hi,

I have attached scanned image of 500 Rs, I got extra region in green color and also image tilted at curtain angle .

At right side of my image some part has been removed or not scanned(due to tilt).

o/p expected is remove angle of tilt and i have to find exact corner points in the image .

plz plz let me know methods to solve this problem .

I have tried with finding skew angle, Hough transform but i am not find solution.

2014-03-22 02:10:34 -0600 commented question How to link tesseract to Eclipse in Ubuntu 12.04 ??

I am also facing same issue, Please let me know how you solve this problem.

2014-03-09 23:08:34 -0600 commented question Number extraction on metal surface1

@GrumbleLion thanks for the info :)

2014-03-07 06:39:14 -0600 received badge  Critic (source)
2014-03-04 11:44:32 -0600 received badge  Student (source)
2014-03-04 07:09:35 -0600 asked a question Number extraction on metal surface1

<strong>image description</strong>

Dear sir,

@Haris Moonamkunnu, my original pic is exactly like this , In my previous post I have cropped the region and i Have posted .

If this is the case what methods i have to adopt and how to proceed further. After the process the number has to detected by tessseract-ocr.

I am struggling from past 2 months plz help me .

image description

Blockquote

Hi, I have to extract the number 1 in an Image and the number recognized by tesseract.

Please suggest me the ideas to implement and process this image .

Regards Nagaraj

2014-02-20 00:00:28 -0600 received badge  Editor
2014-02-19 23:58:12 -0600 received badge  Supporter (source)