How to fix points index when make some polygon

hi, i have some question if you can answer plz help me!
when i draw polygon using qt creator and opencv
the points index cahnged every time

i want to get fixed points index like fixed bottom side of a polygon index

for example)
(1) at first draw
bottom side of a polygon == cv::line(frame, cv::Point(box.at(1).x(),box.at(1).y()), cv::Point((box.at)(2).x(), box.at(2).y()),......);
(2) at second draw
bottom side of a polygon == cv::line(frame, cv::Point(box.at(2).x(),box.at(2).y()), cv::Point(box.at)(3).x(), box.at(3).y()),......);

first draw index and second draw index are not the same

how can i get fixed points index?
if you know, let me know
thanks

how do you get those box points ?
and what kind of “order” do you expect there ?
please explain !