Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows build fails with OpenCV 3.4.10 #5876

Open
definability opened this issue Mar 2, 2025 · 1 comment
Open

Windows build fails with OpenCV 3.4.10 #5876

definability opened this issue Mar 2, 2025 · 1 comment
Assignees
Labels
legacy:hands Hand tracking/gestures/etc os:windows MediaPipe issues on Windows platform:c++ Issues specific to C++ framework in mediapipe type:build/install For Build and Installation issues

Comments

@definability
Copy link

definability commented Mar 2, 2025

OS Platform and Distribution

Windows 11

Compiler version

MSVC 19.29.30158 for x64

Programming Language and version

C++17

Installed using virtualenv? pip? Conda?(if python)

No

MediaPipe version

v0.10.21

Bazel version

6.5.0

XCode and Tulsi versions (if iOS)

N/A

Android SDK and NDK versions (if android)

N/A

Android AAR (if android)

None

OpenCV version (if running on desktop)

3.4.10

Describe the problem

bazel-6.5.0 build --verbose_failures -c opt --define MEDIAPIPE_DISABLE_GPU=1 --define=xnn_enable_avxvnniint8=false --shell_executable="C:\msys64\usr\bin\bash.exe" --repo_env=HERMETIC_PYTHON_VERSION=3.11 -- //mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu

Constant CAP_PROP_ORIENTATION_AUTO was introduced in OpenCV 3.4.12
opencv/opencv@f0271e5#diff-702e7efcf6bd7a4c265fcdbc0cc4c4e47e8ea12325bf28d18524c194c9ab4759R181

It was used in MediaPipe in v0.10.21 226e37a

The web documentation and opencv_windows.BUILD must reflect this requirement.

Complete Logs

mediapipe/calculators/video/opencv_video_decoder_calculator.cc(116): error C2039: 'CAP_PROP_ORIENTATION_AUTO': is not a member of 'cv'
external/windows_opencv/include\opencv2/videoio.hpp(71): note: see declaration of 'cv'
mediapipe/calculators/video/opencv_video_decoder_calculator.cc(116): error C2065: 'CAP_PROP_ORIENTATION_AUTO': undeclared identifier
Target //mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu failed to build

P.S. Please fix the issue creation form: it creates a single-line text input for the problem description, which forces editing the issue after creating it to enrich it with necessary details.

@definability definability added the type:build/install For Build and Installation issues label Mar 2, 2025
definability added a commit to definability/mediapipe that referenced this issue Mar 2, 2025
Update the required OpenCV version to 3.4.12.
The project uses `CAP_PROP_ORIENTATION_AUTO` contant that was introduced in OpenCV 3.4.12,
thus is not accesible in OpenCV 3.4.10
opencv/opencv@f0271e5

Using of OpenCV 3.4.10 leads to a build error
```
mediapipe/calculators/video/opencv_video_decoder_calculator.cc(116): error C2039: 'CAP_PROP_ORIENTATION_AUTO': is not a member of 'cv'
external/windows_opencv/include\opencv2/videoio.hpp(71): note: see declaration of 'cv'
mediapipe/calculators/video/opencv_video_decoder_calculator.cc(116): error C2065: 'CAP_PROP_ORIENTATION_AUTO': undeclared identifier
Target //mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu failed to build
```
@definability
Copy link
Author

Proposed fix: #5877

@kuaashish kuaashish assigned kuaashish and unassigned kalyan2789g Mar 3, 2025
@kuaashish kuaashish added os:windows MediaPipe issues on Windows platform:c++ Issues specific to C++ framework in mediapipe legacy:hands Hand tracking/gestures/etc labels Mar 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
legacy:hands Hand tracking/gestures/etc os:windows MediaPipe issues on Windows platform:c++ Issues specific to C++ framework in mediapipe type:build/install For Build and Installation issues
Projects
None yet
Development

No branches or pull requests

3 participants