def METHOD_NAME(rect: ObscRectangle, out: Optional[ArrayLike] = None) -> ArrayLike:
    if out is None:
        out = np.empty((4,))
    e = np.array([np.cos(rect.theta), np.sin(rect.theta)])
    if rect.width > rect.height:
        n = np.array([-e[1], e[0]])
        thickness = rect.height / 2.0
    else:
        n = e
        thickness = rect.width / 2.0
    center = np.array([rect.x, rect.y])
    d = n.dot(center)
    out[:2] = n
    out[2] = d
    out[3] = thickness
    return out