我是opencv的初学者.我正在使用opencv v2.1.我已将RGB图像转换为HSV图像.现在我想分别获得单通道Hue,Value和Saturation.我该怎么办?我在这里看到过类似的问题,但没有人回答这个问题.请帮助.
computer-science opencv image-processing hsv computer-vision
我正在使用opencv 2.4及以下版本是我正在尝试编译的代码.我使用这个命令编译我的代码
g++ -o "match" -ggdb `pkg-config --cflags opencv` match.cpp `pkg-config --libs opencv`
Run Code Online (Sandbox Code Playgroud)
为什么我收到此错误:
match.cpp: In function ‘int main(int, const char**)’:
match.cpp:18:37: error: expected type-specifier before ‘SurfFeatureDetector’
match.cpp:18:37: error: conversion from ‘int*’ to non-scalar type ‘cv::Ptr<cv::FeatureDetector>’ requested
match.cpp:18:37: error: expected ‘,’ or ‘;’ before ‘SurfFeatureDetector’
match.cpp:22:2: error: ‘SurfDescriptorExtractor’ was not declared in this scope
match.cpp:22:26: error: expected ‘;’ before ‘extractor’
match.cpp:26:2: error: ‘extractor’ was not declared in this scope
match.cpp:29:2: error: ‘BruteForceMatcher’ was not declared in this scope
match.cpp:29:30: error: …Run Code Online (Sandbox Code Playgroud) 我有一个很大的 C++ 代码,我想将它集成到 MATLAB 中,以便我可以在我的 matlab 代码中使用它。如果它是一个单独的代码来制作它的 mex 文件将是最好的选择。但是既然现在是需要编译构建才能运行的代码,我不知道如何使用这段代码中的功能。
为整个代码制作 mex 文件是唯一的选择还是有其他解决方法?另外,我想了解如何为整个代码制作 mex 文件然后构建它。
为了获得更多见解,这是我试图在 matlab http://graphics.stanford.edu/projects/drf/densecrf_v_2_2.zip 中集成的代码。谢谢你!