def METHOD_NAME(self, textlines, raw_mask, mask, img_w, img_h):
    raw_mask = np.ascontiguousarray(np.rot90(raw_mask))
    if mask is not None:
        mask = np.ascontiguousarray(np.rot90(mask).astype(np.uint8))
    for i, txtln in enumerate(textlines):
        rotated_pts = txtln.pts[:,[1,0]]
        rotated_pts[:,1] = -rotated_pts[:,1] + img_h
        textlines[i] = Quadrilateral(rotated_pts, txtln.text, txtln.prob)
    return textlines, raw_mask, mask