Optical edge detection, a part of image processing, plays an important role in extracting image information used in optical analog computation. In this Letter, we raise a new way to realize optical edge detection. This design is based on two liquid crystal polarization gratings with a period of 2.2