'OpenCV function list
Hi I was wondering if there is some sort of resource where I can find all the functions present in OpenCV and and their declarations; without much theory of any sort. The problem with the OpenCV guide is that there is too much theory that is involved, and I wish to have a reference that can help me, find the function as and when I want them, something like an function index? I could try the header cpp files or something. I was wondering if there is some sort of online resource already present to that end ? thank you, as always!
Solution 1:[1]
I would highly recommend the C++ interface if you are using OpenCV 2.0, as opposed to the C documentation presented in the other answer.
Solution 2:[2]
I recommend OpenCV C(or C++) reference http://opencv.willowgarage.com/documentation/cpp/index.html . The latest version is OpenCV 2.2. You should check it carefully if you come from former versions as this version includes many new features as such as Android app. Moreover, the header files, functions and .lib file are re-organized in a more specific way.
Solution 3:[3]
The top two are actually referring to the OLD OpenCV (2.0) documentation. The new documentation is hosted somewhere else, here: http://opencv.itseez.com/index.html . At itseez. Its the current version >2.4. Previous answers are outdated.
Solution 4:[4]
The following post is exclusively for Python users.
1. Listing all OpenCV functions
To get the entire list of OpenCV's functions use `dir(cv2):
import cv2
# all of cv2 functions in a list
functions_list = dir(cv2)
# display first 20 functions
functions_list[:20]
>>>['', 'ACCESS_FAST', 'ACCESS_MASK', 'ACCESS_READ', 'ACCESS_RW', 'ACCESS_WRITE', 'ADAPTIVE_THRESH_GAUSSIAN_C', 'ADAPTIVE_THRESH_MEAN_C', 'AGAST_FEATURE_DETECTOR_AGAST_5_8', 'AGAST_FEATURE_DETECTOR_AGAST_7_12D', 'AGAST_FEATURE_DETECTOR_AGAST_7_12S', 'AGAST_FEATURE_DETECTOR_NONMAX_SUPPRESSION', 'AGAST_FEATURE_DETECTOR_OAST_9_16', 'AGAST_FEATURE_DETECTOR_THRESHOLD', 'AKAZE', 'AKAZE_DESCRIPTOR_KAZE', 'AKAZE_DESCRIPTOR_KAZE_UPRIGHT', 'AKAZE_DESCRIPTOR_MLDB', 'AKAZE_DESCRIPTOR_MLDB_UPRIGHT', 'AKAZE_create']
2. Searching for a particular function in OpenCV
What if you want to look up for a function but do not remember it clearly? Or you can only recall the function partially?
For instance, there are many functions to smooth an image, but you are unable to recall which one you want specifically. Using the following, you can get a list of all the functions available in cv2 with the a keyword.
In the following scenario we are searching for functions containing the word blur:
def search_function(name):
match_list = []
for function in dir(cv2):
if name in str.lower(function):
match_list.append(function)
return match_list
search_function('blur')
The above returns the following list:
['GaussianBlur', 'blur', 'medianBlur']
Now just append cv2. before the function of your choice and proceed.
Solution 5:[5]
Latest updates can be found through: http://opencv.org/
From there, the documentation meta-site: http://docs.opencv.org/
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Ray Hidayat |
| Solution 2 | Jackypengyu |
| Solution 3 | TimZaman |
| Solution 4 | Jeru Luke |
| Solution 5 | user1270710 |
