In order to mark occluded regions explicitly on the disparity map
the dynamic programming is employed to search optimal disparity curve on base of the calculating disparity space at first.Each point on the optimal disparity curve must be in one of three states:matching state or other two occlusion states.To guarantee the disparity curve passing through ground control points (GCP)
an algorithm of dynamic programming in segments is proposed
that is
the disparity space image is divided into ground control regions and non-ground control regions.In the ground control region
the searching path is forced to pass GCPs.In the non-ground control region
the optimal path searching is under dynamic programming.For the reliability of the GCP
four criterions are presented to choose a point as a GCP.Experimental results show that the new algorithm has certain enhancement in the precision of occlusion detection and matching
and is more reliable and faster than conventional dynamic algorithms.