Added corner detection using median filter