Results 1 to 5 of 5

Thread: how sort position template in source image ?

  1. #1
    Join Date
    Jan 2012
    Posts
    4
    Qt products
    Qt4
    Platforms
    Windows

    Question how sort position template in source image ?

    Hi everyone,

    I have question about sort position template in source image. when i have position x,y,width and height of template on source image.
    i need covert position to letter 12345678.

    5.jpg

    Thank you.

  2. #2
    Join Date
    Mar 2011
    Location
    Hyderabad, India
    Posts
    1,882
    Thanks
    3
    Thanked 452 Times in 435 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Wiki edits
    15

    Default Re: how sort position template in source image ?

    It does not make any sense to me, consider re-wording the post.

    Do you want number rocognition from image file?
    When you know how to do it then you may do it wrong.
    When you don't know how to do it then it is not that you may do it wrong but you may not do it right.

  3. #3
    Join Date
    Jan 2012
    Posts
    4
    Qt products
    Qt4
    Platforms
    Windows

    Question Re: how sort position template in source image ?

    I 'm sorry. My english is really bad. and thank you for trying to help me.

    I use Opencv Template matching. Now I can get the position (x,y) of each template (example 1, 3, 2, 4, 6, 5, 7, 8)
    i want method coding to check sequence of position in template.
    From picture the result that I want is 1 2 3 4 5 6 7 8. how do i check?

    Thank you.


    Added after 1 1:


    7.jpg

    X , Y ,Width, Height,Value
    227, 153, 22, 27, 3
    247, 152, 20, 27, /
    266, 153, 21, 27, 0
    267, 120, 21, 27, S
    287, 152, 21, 27, 6
    288, 115, 17, 27, 1
    307, 153, 21, 27, 0
    327, 152, 21, 27, 9
    347, 151, 17, 27, 1
    369, 151, 21, 27, 2

    sequence is S13/060912

    Thank you.
    Last edited by woraprud; 30th January 2013 at 09:12.

  4. #4
    Join Date
    Mar 2011
    Location
    Hyderabad, India
    Posts
    1,882
    Thanks
    3
    Thanked 452 Times in 435 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Wiki edits
    15

    Default Re: how sort position template in source image ?

    I still don't understand your problem.

    You have images, and you can match them, and have their positions (x,y). Then what is stopping you in just rearranging the X, Y is the matched images?
    When you know how to do it then you may do it wrong.
    When you don't know how to do it then it is not that you may do it wrong but you may not do it right.

  5. #5
    Join Date
    Dec 2012
    Posts
    90
    Thanks
    5
    Thanked 20 Times in 18 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: how sort position template in source image ?

    I think he's trying to form a sensible string (when reading from left to right, top to bottom) from a set of detected characters.

    You can use scan line algorithm to track lines along the image and fuzzily decide what symbol goes to what line. I am afraid there is no exact algorithm.
    Consider the following case:
    problem.png
    It can be 12345 and 13425.
    Last edited by lanz; 30th January 2013 at 13:20.

Similar Threads

  1. identifying the position of a circle in image
    By qtlearner123 in forum Newbie
    Replies: 2
    Last Post: 26th April 2012, 06:14
  2. Replies: 1
    Last Post: 18th January 2012, 10:00
  3. Replies: 0
    Last Post: 26th October 2011, 22:18
  4. image source changes in animation
    By vinayaka in forum Qt Quick
    Replies: 0
    Last Post: 27th September 2011, 08:31
  5. Replies: 1
    Last Post: 3rd October 2007, 07:34

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.