Extract addCorner from addCornerPos and addCornerNeg