Added edge rendering logic