CRgn rgn; rgn.CreateRectRgn(10, 10, 50, 50);
CRgn rgn; rgn.CreateRoundRectRgn(10, 10, 50, 50, 10, 10);
CRgn rgn1; rgn1.CreateRectRgn(10, 10, 50, 50); CRgn rgn2; rgn2.CreateRectRgn(30, 30, 70, 70); rgn1.CombineRgn(&rgn1, &rgn2, RGN_OR);This creates two rectangular regions and then combines them using the OR operation. The CRgn class is part of the MFC library, which is a package of C++ classes for developing Windows applications in Visual C++.