From 52c1ec39c256f6ce6b0fdab231cd78f9cad9deda Mon Sep 17 00:00:00 2001 From: Benjamin Ruesink Date: Tue, 8 Oct 2024 16:35:18 +0200 Subject: [PATCH] Set default flags, update README --- README.MD | 11 +++++++++++ samples/AiMaskStreamApp/AiMaskStreamApp.cpp | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/README.MD b/README.MD index ea39a3a..6dedecd 100644 --- a/README.MD +++ b/README.MD @@ -28,6 +28,17 @@ cmake -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake .. - Built binaries will be in `build/Release` - You might need to copy `opencv_world346.dll` from `samples/external/opencv/bin` to the binary directory to run the application +### Run +- Run the application with the following command line arguments: + +```bash +AiMaskStreamApp.exe [--camera_index=0] [--mode=0] [--ws_port=9001] [--show_window=0] +``` +- `--cam_index` (0, 1, ...) is the index of the camera to use in case multiple cameras are available, default is 0 +- `--mode` (0, 1) is the green screen mode, 0 - best quality, 1 - best performance, default is 0 +- `--ws_port` (0 ... 65535) is the port to use for the websocket server, default is 9001 +- `--show_window` (0, 1) is a flag to show windows with the processed video, default is 0 + ## NVIDIA MAXINE VideoEffects SDK: API Source Code and Sample Applications diff --git a/samples/AiMaskStreamApp/AiMaskStreamApp.cpp b/samples/AiMaskStreamApp/AiMaskStreamApp.cpp index 8746542..0ea5671 100644 --- a/samples/AiMaskStreamApp/AiMaskStreamApp.cpp +++ b/samples/AiMaskStreamApp/AiMaskStreamApp.cpp @@ -67,11 +67,11 @@ #endif // _WIN32 bool FLAG_progress = false; -bool FLAG_show = false; +bool FLAG_show = true; bool FLAG_verbose = false; -bool FLAG_webcam = false; +bool FLAG_webcam = true; bool FLAG_cudaGraph = false; -int FLAG_compMode = 3 /*compWhite*/; +int FLAG_compMode = 1 /*compWhite*/; int FLAG_mode = 0; float FLAG_blurStrength = 0.5; std::string FLAG_camRes;