Computed tomography (CT) and X-ray images have been extensively used as a valuable diagnostic tool in dentistry for surgical planning and treatment. Nowadays, dental cone beam CT has been extensively used in dental clinics. Therefore, it is possible to employ three-dimensional (3D) data from the CT to reconstruct a two-dimensional (2D) panoramic dental image that provides a longitudinal view of the mandibular region of the patient, avoiding an additional exposure to X-ray. In this work, we developed a new automatic method for reconstructing 2D panoramic images of the dental arch based on 3D CT images, using Bézier curves and optimization techniques. The proposed method was applied to five patients, some of them with missing teeth, and smooth panoramic images with good contrast were obtained.