Ask Your Question

123ezone's profile - activity

2020-11-14 15:35:39 -0600 received badge  Famous Question (source)
2018-06-02 08:00:27 -0600 received badge  Notable Question (source)
2018-03-10 00:46:44 -0600 received badge  Notable Question (source)
2017-07-20 16:53:51 -0600 received badge  Popular Question (source)
2017-05-02 13:33:21 -0600 received badge  Popular Question (source)
2017-04-02 07:56:52 -0600 received badge  Famous Question (source)
2017-01-02 08:12:57 -0600 received badge  Popular Question (source)
2014-09-30 08:51:41 -0600 received badge  Notable Question (source)
2014-01-29 06:34:07 -0600 received badge  Popular Question (source)
2013-11-06 11:48:05 -0600 asked a question cvCreateTrackbar() problem when creating a forms application

This is my main program that I wrote to rotate character slant manually(at run time) by using shearing algorithm. This is a console application and I don't know how can I do the same task using windows forms application. The problem occurred since the console app create track bar using cvCreateTrackbar() function and now I need to do it in another form. Please can anyone help me?

        IplImage* img;
        IplImage* rotated_img;
        int trackCount = 0;
        cvNamedWindow("MyWindow");
        cvCreateTrackbar("Angle", "MyWindow", &trackCount, 500, 0);

      while(true){
          //load the original image
          img = cvLoadImage("Original.jpg");

          //rotate the image
          rotated_img=SlantCorrection(img,trackCount);

          //display the rotated image
          cvShowImage("MyWindow", rotated_img);

          //clean up
          cvReleaseImage(&img);
          cvReleaseImage(&rotated_img);

          //if user press 'ESC' button, program quit the while loop
          int c=cvWaitKey(50);              
          if(c==27) break;
      }

      int height=rotated_img->height;
      int *linecount = new int[height];
      int width=rotated_img->width;
      int *wordcount = new int[width];

      int count=0;
      int countPositions=0;
      int *pos = new int[height];
      Horizontal_projection(rotated_img,width,height,countPositions,pos);
      count = Vertical_Projection(width,height);

      cvDestroyWindow("MyWindow");

      return 0;

Thank You !

2013-09-26 10:57:02 -0600 asked a question Convert Binary image to gray scale

I I have a doubt that can we convert binary image again to a gray scale image. Is there any methods or can we use cvCvtColor() and do that task. Thanks.

2013-09-24 05:37:46 -0600 asked a question How to do shear transformation

image description

I'm trying to remove slant of cursive text by using shearing transformation. Can someone tell me where I can find any tutorials regarding shear transformation in opencv or solution for that. Thank You Very much !

2013-09-23 15:00:54 -0600 asked a question How to create a Rhombus using openCV

When we want to crop a section from an image what we normally use is cvSetImageROI() method and pass a rectangle as a parameter. In my case, I want to crop a rhombus from an image so that I have to pass a rhombus as the parameter. So I need to know how to draw a rhombus in opencv. Can someone help me with this problem. Thank You !

2013-07-02 12:06:07 -0600 commented question Character Slant Correction

std::vector<cv::Point> points;

cv::Mat_<uchar>::iterator it = img.begin<uchar>();

cv::Mat_<uchar>::iterator end = img.end<uchar>();

for (; it != end; ++it)

if (*it)

points.push_back(it.pos());

Can someone help me with converting this into opencv version 2.4.3. I have tried that but it didn't work.

2013-07-02 12:03:16 -0600 commented answer Character Slant Correction

Thank You!

2013-07-02 05:08:08 -0600 asked a question Character Slant Correction

Hi, I'm Trying to correct slant of cursive handwritten characters before do the segmentation.What I need is to rotate the letters so they are upright. Can someone please help with opencv code to find a solution. Thank You very much !

2013-06-16 04:39:09 -0600 asked a question OCR Character Segmentation for cursive handwriting

I have done a OCR application for handwritten normal characters.For the segmentation of characters I have used histogram profile method. That successfully works for normal English characters.

I have used horizontal projection for line segmentation and vertical projection for character segmentation.

To segment lines of cursive hand written article I can use horizontal projection as previous. But I can't use same methodology for cursive English character segmentation since they are merged each other and also slanted. Can anyone please help me with a way to segment cursive characters.Thank You very much.

2013-06-15 06:04:15 -0600 asked a question Issues in Reading set of images
            for(int i=22; i<24; i++){
            IplImage *img = cvLoadImage("%d.jpg",i);
            }

Please tell me how can I Load set of images from project file.It works for loading one image but when I code it like this it do not work.Please help me for load the set of images in a loop.

2013-06-14 05:16:49 -0600 received badge  Student (source)
2013-06-03 12:02:03 -0600 asked a question Errors in Converting console application to windows form application C++

Hi, I am doing OCR application using opencv 2.4.3 in visual c++ windows forms(visual studio 2010 ultimate). I did this OCR application as a c++ console application and it works fine. But when I was converting it to windows forms it gives this error.

Error 1 error LNK2001: unresolved external symbol "public: virtual void __thiscall cv::HOGDescriptor::setSVMDetector(class cv::_InputArray const &)" (?setSVMDetector@HOGDescriptor@cv@@UAEXABV_InputArray@2@@Z)

Can someone help me to fix this error.I have no idea of correcting that error.I used same additional libraries which I used for console application here also.Thank You

2013-06-03 09:35:39 -0600 asked a question IplImage vector in C++/Clr

I have converted a console application of a OCR application to a windows form application.The program runs accurately on console application but after converting it gives error for the vector that I have used to store image set.I have changed the configuration properties to Common Language Runtime Support (/clr) and I changed the header file cliext since clr does not support for std/vector. This is my code.But still it has errors.

ref class Segmentation { public:
    IplImage *PreprocessedImage;
    cliext::vector<IplImage *> Lineimgs;
    cliext::vector<IplImage *> Characterimgs;
    Segmentation(IplImage *);
    ~Segmentation(void);
    IplImage* Resize(IplImage *);
    void Horizontal_projection(int,int,int,int
*);
    int Vertical_Projection(int,int); };``

Error is, Error 1 error C3225: generic type argument for 'TValue' cannot be '_IplImage *', it must be a value type or a handle to a reference type C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\cliext\vector 14 1 Prototype 3

Please help me with this problem.Thank You

2013-05-25 09:00:14 -0600 asked a question How to return IplImage Array

I want to create an image array using IplImage.Here is my code for that.But it provides some memory leaks.Please help me with this to solve this problem.

    IplImage *result[200];  
    for(int i=0;i<160;i++)
{
    result[i]=cvCreateImage(cvGetSize(Segimg), 8, 1);
}
    *result=method();

cvNamedWindow("B:");
cvShowImage("B:", result[1]);
cvWaitKey(0);
cvDestroyWindow("B:");

cvReleaseImage(&result[1]);
2013-05-11 05:27:52 -0600 asked a question Character Segmentation for cursive characters

I have segmented normal characters using horizontal and vertical projection. Now I'm trying to segment cursive characters. I have no idea of segmenting cursive characters since they are slanted. Please help me with this problem. Thank You.

2013-03-26 01:26:38 -0600 asked a question Morphological Skeleton in OpenCV

I want to get the skeleton image of a character and I have tried that from OpenCV.But it runs a never ending loop.Please help me with this.Here is my code.Thanks.

bool done;
IplConvKernel* element = cvCreateStructuringElementEx( 3, 3,0, 0, CV_SHAPE_CROSS, NULL );
do
{
    cvErode(gray,erode,element,1);
    cvDilate(erode,temp,element,1);
    cvAbsDiff(gray,temp,temp);
    cvOr(skel,temp,skel,NULL);
    cvCopy(erode, gray, NULL);
done = (cvCountNonZero(gray) == 0);
} while (!done);