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

How to set OpenCV environment variables to open advanced configurations of OpenCV #1694

Open
GodOMG opened this issue Aug 17, 2024 · 0 comments

Comments

@GodOMG
Copy link

GodOMG commented Aug 17, 2024

By consulting OpenCV, it was found that the function can be configured through environment variables

OpenCV document https://docs.opencv.org/4.10.0/d6/dea/tutorial_env_reference.html

Environment

win 10 64bit
.NET 8
opencvsharp 4.10.0.20240616

Problem

I tried the following code to configure OpenCV, but it didn't work. According to the documentation and code of OpenCV, if the log is enabled, it should display the output window during Visual Studio debugging and the bitrate during video recording.

Cv2.SetLogLevel(LogLevel.DEBUG);

Environment.SetEnvironmentVariable("OPENCV_LOG_LEVEL", "DEBUG");
Environment.SetEnvironmentVariable("OPENCV_VIDEOIO_DEBUG", "1");

Environment.SetEnvironmentVariable("OPENCV_FFMPEG_WRITER_OPTIONS", "bitrate;1000");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant