Optical coherence tomography (OCT), which can noninvasively obtain high-resolution three-dimensional images of retina, is widely used for diagnosis in ophthalmology. The retinal layers need to be segmented from OCT images to diagnose glaucoma and age-related macular degeneration, which changes the thickness of retina. The state-of-the-art methods are to flatten OCT images based on the major line of retinal layer and use CNN to find the boundaries between layers. These methods consist of two branches: the first gives layer labels for each pixel, and the second finds the boundaries between layers. These methods cannot segment the fine shapes of the retinal layers. To address this problem, we propose a novel method for estimating surface positions to segment the retinal layers from OCT images.