HughPH.Box2D
Organised dotnet bindings for Box2D 3.1.0
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Properties | List of all members
Box2D.ShapeProxy Struct Reference

A distance proxy is used by the GJK algorithm. It encapsulates any shape. You can provide between 1 and Constants.MAX_POLYGON_VERTICES and a radius. More...

Public Member Functions

 ShapeProxy (ReadOnlySpan< Vec2 > points, float radius)
 Constructs a new ShapeProxy object with the given parameters.
 
 ShapeProxy ()
 Constructs a new ShapeProxy object with default values.
 

Public Attributes

float Radius
 The radius of the shape.
 

Properties

ReadOnlySpan< Vec2 > Points [get, set]
 The points of the shape in local coordinates.
 

Detailed Description

A distance proxy is used by the GJK algorithm. It encapsulates any shape. You can provide between 1 and Constants.MAX_POLYGON_VERTICES and a radius.

Constructor & Destructor Documentation

◆ ShapeProxy()

Box2D.ShapeProxy.ShapeProxy ( ReadOnlySpan< Vec2 >  points,
float  radius 
)
inline

Constructs a new ShapeProxy object with the given parameters.

Parameters
pointsThe points of the shape in local coordinates.
radiusThe radius of the shape.
Exceptions
ArgumentExceptionThrown when the number of points exceeds the maximum allowed.
ArgumentNullExceptionThrown when the points array is null.
ArgumentOutOfRangeExceptionThrown when the number of points is less than 1.

The documentation for this struct was generated from the following file: