A hole repair algorithm for skull defect repair is put forward. From the input of a set of guide points,the upper boundary ring for the hole is searched according to edge features and the position of the objective point. The expanded ring is obtained by the expansion of the upper ring along the gradient direction. And the boundaries of objective regions are recognized,while the region between this two rings is obtained. Based on two samples rings, the lower boundary ring is constructed by the inward expansion of the upper ring,and the region between the upper and lower rings is identified. Then the lower patching surface is constructed by using geometric constraints. The repair entity is constructed by stitching the upper patching surface,lower patching surface,and the region between the upper ring and lower ring. The algorithm can minimize the manual interaction steps and produce a satisfied repair result.