Decomposition of still and video images with edge segments