Skip to content

Commit

Permalink
adding ui for sky/black checkboxes
Browse files Browse the repository at this point in the history
  • Loading branch information
hn-88 authored Nov 1, 2023
1 parent 191f1c5 commit 014cfec
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions pan2fulldome.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,8 @@ cv::Mat dst2, dst3, dsts; // temp dst, for eachvid

// Init cvui and tell it to create a OpenCV window, i.e. cv::namedWindow(WINDOW_NAME).
cvui::init(WINDOW_NAME);
bool sky_checked = true;
bool black_checked = false;

while (true) {
// Fill the frame with a nice color
Expand All @@ -406,6 +408,20 @@ cv::Mat dst2, dst3, dsts; // temp dst, for eachvid
cvui::text(frame, 350, 10, "Preview");
cvui::button(frame, 140, 30, dstdisplay, dstdisplay, dstdisplay);


cvui::checkbox(frame, 40, 540, "Interp sky", &sky_checked);
cvui::checkbox(frame, 190, 540, "Black sky", &black_checked);
if(black_checked) {
sky_checked = false;
} else {
sky_checked = true;
}
if(sky_checked) {
black_checked = false;
} else {
black_checked = true;
}

cvui::text(frame, 35, 580, "Sky");
if (cvui::trackbar(frame, 15, 600, 135, &sky_threshold, 0, 400)) {
if (sky_threshold > 395) {
Expand Down

0 comments on commit 014cfec

Please sign in to comment.