[wingide-users] Problem with auto-complementation in OpenCV
support at wingware.com
Mon Apr 13 10:49:02 MDT 2009
> I have oryginaln problem with autocomplementation in WingIDE working
> with OpenCV library. Auto-comp works fine in Python Shell.
> from opencv.cv import *
> from opencv.highgui import *
> img = cvLoadImage('/tmp/image.jpg')
> I get a list of function connected with img.
> This same piece of code in editor don't tell me nothing about img, in
> Source Assistant I get a information: "Symbol: img Cannot determine type".
> Where is the mistake? Why script doesn't know what the img is?
Wing's shell uses live runtime state to offer auto-completion while
in the editor you get completion sourced from static analysis.
It looks like the opencv.cv.* modules are written in C++. Wing should
try to load and "scrape" interface information out of the extension
modules, but it's possible either it's failing to do that or you
need to add the directory that encloses the package directory opencv
to your Python Path in Wing's Project Properties.
If you check your Python Path and it still does not work, try this: Quit
and restart Wing, and then try the above in the source editor, then submit
a bug report from Wing's Help menu with the error log included. That
may show us what errors are occurring when trying to load the modules.
It's also worth trying something like these to rule out problems specific
to the form of import:
from opencv import cv
Please let us know whether or not that helps.
Wingware | Python IDE
Advancing Software Development
More information about the wingide-users