help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave and OpenCV


From: soren
Subject: Re: Octave and OpenCV
Date: Wed, 06 Aug 2008 13:44:44 +0200
User-agent: Internet Messaging Program (IMP) H3 (4.2-RC2)

Quoting Abdul Rahman Riza <address@hidden>:
Can you share simple c code (with OpenCV)how to read image (as imread)
and display it (as imshow) using gnuplot ?

I'm not quite sure I understand your question. I don't use Octave and OpenCV together, I use them seperatly. If you want to use them together (i.e. calling OpenCV functions from Octave) then you need the OpenCV SWIG-based package I mentioned in a previous mail.

If you have questions regarding using OpenCV alone, then I recommend the OpenCV mailing list, which is a friendly and helpful list. In an attempt to answer your question, I can tell you that the following Octave program

  im = imread ("myfile.png");
  imshow (im);

roughly corresponds to the following untested OpenCV program

  #include "cv.h"
  #include "highgui.h"

  int main ()
  {
    const char *window_name = "My window name";
    cvNamedWindow (window_name, CV_WINDOW_AUTOSIZE);
    IplImage *im = cvLoadImage ("myfile.png");
    cvShowImage (window, im);
    cvWaitKey (-1);

    return 0;
  }

Does that answer your question?

Søren




reply via email to

[Prev in Thread] Current Thread [Next in Thread]