C++ code for 2d/3D image segmentation and visualization with ITK and VTK packages