distance3d.distance.point_to_disk

distance3d.distance.point_to_disk(point, center, radius, normal)[source]

Compute the shortest distance between point and disk.

Implementation adapted from 3D Game Engine Design by David H. Eberly.

Geometric Tools, Inc. http://www.geometrictools.com Copyright (c) 1998-2006. All Rights Reserved

The Wild Magic Version 4 Foundation Library source code is supplied under the terms of the license agreement (http://www.geometrictools.com/License/Wm4FoundationLicense.pdf) and may not be copied or disclosed except in accordance with the terms of that agreement.

Parameters:
pointarray, shape (3,)

3D point.

centerarray, shape (3,)

Center of the disk.

radiusfloat

Radius of the disk.

normalarray, shape (3,)

Normal to the plane in which the disk lies.

Returns:
distfloat

The shortest distance between point and disk.

closest_point_diskarray, shape (3,)

Closest point on the disk.