Skip to content

Comments

Deprecated OpenCV consts leading to compilation error#2693

Merged
ronghanghu merged 1 commit intoBVLC:masterfrom
AdamStelmaszczyk:patch-1
Nov 27, 2015
Merged

Deprecated OpenCV consts leading to compilation error#2693
ronghanghu merged 1 commit intoBVLC:masterfrom
AdamStelmaszczyk:patch-1

Conversation

@AdamStelmaszczyk
Copy link
Contributor

When compiling Caffe I got the same compilation error as here:
https://groups.google.com/forum/#!topic/caffe-users/mZDi02lgcj0

This is because constants such as CV_BGRA2GRAY are deprecated in OpenCV 2 and 3.
The replacements are constants such as cv::COLOR_BGRA2GRAY.

@flx42
Copy link
Contributor

flx42 commented Jul 5, 2015

LGTM

@flx42
Copy link
Contributor

flx42 commented Jul 6, 2015

... aside from the commit message where there is a typo in the title and you should remove the first paragraph.

@AdamStelmaszczyk AdamStelmaszczyk changed the title Compilation error fix, depracated OpenCV consts Deprecated OpenCV consts leading to compilation error Jul 6, 2015
@AdamStelmaszczyk
Copy link
Contributor Author

@flx42 I edited the commit message and title of this pull request.

@flx42
Copy link
Contributor

flx42 commented Jul 6, 2015

You should have kept the message about OpenCV versions

But actually, I installed OpenCV 3.0.0 and I couldn't repro the issue, which version of OpenCV are you using exactly?

@AdamStelmaszczyk
Copy link
Contributor Author

I used OpenCV 3.0.0.

Wesley from earlier mentioned Google Group thread also used 3.0.0.

These consts come from this OpenCV file: https://github.com/Itseez/opencv/blob/master/modules/imgproc/include/opencv2/imgproc.hpp

Why you can't reproduce this issue: maybe you haven't correctly uninstalled previous version of OpenCV or haven't done make clean.

Not sure if this is relevant, but me and Wesley are building with CPU_ONLY := 1 in Makefile.config:8.

@flx42
Copy link
Contributor

flx42 commented Jul 6, 2015

Sure, it's deprecated, but I don't understand why it's not compiling for you, the constants still exist:
https://github.com/Itseez/opencv/blob/master/modules/imgproc/include/opencv2/imgproc/types_c.h#L103-L128

ronghanghu added a commit that referenced this pull request Nov 27, 2015
Deprecated OpenCV consts leading to compilation error
@ronghanghu ronghanghu merged commit c9086ca into BVLC:master Nov 27, 2015
@AdamStelmaszczyk AdamStelmaszczyk deleted the patch-1 branch April 18, 2016 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants