Results 1 to 2 of 2

Thread: openCV upside down problem

  1. #1
    Join Date
    Feb 2010
    Qt products

    Question openCV upside down problem

    Hi people, i am new here, nice to meet you all.

    i have came across a small problem with openCV outputting images upside down from my webcamera,
    i'm basically just following tutorials from the O'reilly book,

    when i use the following function,

    Qt Code:
    1. cvSmooth(source,out, smoothType, param1, param2);
    3. cvShowImage("mywindow", out);
    To copy to clipboard, switch view to plain text mode 

    the image gets reversed upside down, but not left-to-right

    i am using Qt 4,
    and openCV version 1.0

    and it seems like this problem also occurs on other functions..
    since the application by windel also appeared upside down for me

    please help thanks !!

  2. #2

    Red face Re: openCV upside down problem

    I started learning openCV and encountered same problem.. I later found out the solution. In windows, the BMP is scanned from bottom-left upward. Therefore, if you are working in windows (like me), you may want to add this line:

    out->origin = IPL_ORIGIN_BL;

    right after you allocation memory.

Similar Threads

  1. Problem wth Opencv & Qt 4
    By Casper2004 in forum Qt Programming
    Replies: 0
    Last Post: 28th September 2009, 10:33
  2. Replies: 1
    Last Post: 1st July 2009, 10:19
  3. I've got a qt&opencv problem.
    By eralvc in forum Installation and Deployment
    Replies: 2
    Last Post: 23rd October 2008, 10:58

Tags for this Thread


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.