Merge pull request #31014 from vrabaud/remove_using_std

Remove std using-declarations and directives from public headers.
This commit is contained in:
Abhishek Gola
2026-12-01 19:52:01 +05:30
committed by GitHub
135 changed files with 655 additions and 706 deletions

View File

@@ -16,7 +16,7 @@ int high_H = max_value_H, high_S = max_value, high_V = max_value;
//! [low]
static void on_low_H_thresh_trackbar(int, void *)
{
low_H = min(high_H-1, low_H);
low_H = std::min(high_H-1, low_H);
setTrackbarPos("Low H", window_detection_name, low_H);
}
//! [low]
@@ -24,32 +24,32 @@ static void on_low_H_thresh_trackbar(int, void *)
//! [high]
static void on_high_H_thresh_trackbar(int, void *)
{
high_H = max(high_H, low_H+1);
high_H = std::max(high_H, low_H+1);
setTrackbarPos("High H", window_detection_name, high_H);
}
//! [high]
static void on_low_S_thresh_trackbar(int, void *)
{
low_S = min(high_S-1, low_S);
low_S = std::min(high_S-1, low_S);
setTrackbarPos("Low S", window_detection_name, low_S);
}
static void on_high_S_thresh_trackbar(int, void *)
{
high_S = max(high_S, low_S+1);
high_S = std::max(high_S, low_S+1);
setTrackbarPos("High S", window_detection_name, high_S);
}
static void on_low_V_thresh_trackbar(int, void *)
{
low_V = min(high_V-1, low_V);
low_V = std::min(high_V-1, low_V);
setTrackbarPos("Low V", window_detection_name, low_V);
}
static void on_high_V_thresh_trackbar(int, void *)
{
high_V = max(high_V, low_V+1);
high_V = std::max(high_V, low_V+1);
setTrackbarPos("High V", window_detection_name, high_V);
}

View File

@@ -35,6 +35,7 @@
#include "opencv2/imgproc.hpp"
#include "opencv2/highgui.hpp"
#include "opencv2/core.hpp"
#include <algorithm>
#include <iostream>
#include <stdlib.h>
@@ -117,10 +118,10 @@ void source(int event, int x, int y, int, void*)
for(int i=0;i<var;i++)
{
minx = min(minx,pts[i].x);
maxx = max(maxx,pts[i].x);
miny = min(miny,pts[i].y);
maxy = max(maxy,pts[i].y);
minx = std::min(minx,pts[i].x);
maxx = std::max(maxx,pts[i].x);
miny = std::min(miny,pts[i].y);
maxy = std::max(maxy,pts[i].y);
}
lenx = maxx - minx;
leny = maxy - miny;
@@ -226,10 +227,10 @@ void destination(int event, int x, int y, int, void*)
{
for(int i=0;i<flag;i++)
{
minxd = min(minxd,pts2[i].x);
maxxd = max(maxxd,pts2[i].x);
minyd = min(minyd,pts2[i].y);
maxyd = max(maxyd,pts2[i].y);
minxd = std::min(minxd,pts2[i].x);
maxxd = std::max(maxxd,pts2[i].x);
minyd = std::min(minyd,pts2[i].y);
maxyd = std::max(maxyd,pts2[i].y);
}
if(maxxd > im1.size().width || maxyd > im1.size().height || minxd < 0 || minyd < 0)
@@ -475,10 +476,10 @@ int main()
for(int i=0;i<var;i++)
{
minx = min(minx,pts[i].x);
maxx = max(maxx,pts[i].x);
miny = min(miny,pts[i].y);
maxy = max(maxy,pts[i].y);
minx = std::min(minx,pts[i].x);
maxx = std::max(maxx,pts[i].x);
miny = std::min(miny,pts[i].y);
maxy = std::max(maxy,pts[i].y);
}
lenx = maxx - minx;
leny = maxy - miny;