Normal brain segmentation is available via FreeSurfer, Vbm, and Ibaspm software. However, these software packages cannot perform segmentation of the brain for patients with brain tumors. As we know, damage from extracerebral tumors to the brain occurs mainly by way of pushing and compressing while leaving the structure of the brain intact. Three-dimensional (3D) imaging, augmented reality (AR), and virtual reality (VR) technology have begun to be applied in clinical practice. The free medical open-source software 3D Slicer allows us to perform 3D simulations on a computer and requires little user interaction. Moreover, 3D Slicer can integrate with the third-party software mentioned above. The relationship between the tumor and surrounding brain tissue can be judged, but accurate brain segmentation cannot be performed using 3D Slicer. In this study, we combine 3D Slicer and FreeSurfer to provide a novel brain segmentation method for extracerebral tumors. This method can help surgeons identify the "real" relationship between the lesion and adjacent brain tissue before surgery and improve preoperative planning.