The invention relates to the technical field of computer graphic
processing, and discloses a single-layer SVG (
scalable vector graphics) image path segmentation and
processing method, which comprises the following steps of: loading an SVG file, displaying
image content in a graphic operation interface, analyzing grouping hierarchical information of the SVG file, and judging whether the SVG file is a single layer or a plurality of
layers; when the single layer is detected, identifying sub-element types in the single layer, and generating independent sub-path data; and generating sub-SVG images based on the sub-path data, performing display and selection, recombining the selected sub-path data to generate an updated SVG image, and executing
processing or rendering operation. According to the method, the grouping hierarchical information of the SVG file is analyzed and judged, efficient distinguishing between a single layer and multiple
layers is achieved, the requirements of a user for displaying, selecting and processing local graphic content can be met in combination with generation and recombination of sub-path data, and the efficiency and flexibility of SVG
image processing are improved.