This work explores the extraction of the spatial distribution and chemical composition information of pigments in colored relics through visible spectral images. An adaptive superpixel segmentation method is proposed to extract the spatial distribution information of pigments. Quadtree decomposition is applied to generate nonuniform initial seed points based on the image homogeneity. These seed points are used as the initial cluster centers in an extended simple linear iterative clustering (SLIC) algorithm for visible spectral images to create superpixels of varying sizes that reflect the homogeneity. Each superpixel is subsequently treated as an individual area in the colored relics, and a pigment identification method based on the visible spectral reflectance is proposed to identify the pigments in these areas. A standard reference database is constructed using samples that simulate the painting process of ancient wall paintings in the Mogao Grottoes. Geometric features, which are characterized by the linear combination of the normalized visible spectral reflectance, its slope and its curvature, are designed to represent the chemical composition of pigments. The geometric features of the superpixels are compared with those of the pigments in the database using the Euclidean distance to determine the pigments in each area of the colored relics. This work is expected to provide scientific guidance for pigment selection in the color restoration of colored relics.