# Struct ncollide3d::query::ContactKinematic [−][src]

pub struct ContactKinematic<N: Real> { /* fields omitted */ }

Local contact kinematic of a pair of solids around two given points.

This is used to update the localization of contact points between two solids from one frame to another. To achieve this, the local shape of the solids around the given points are approximated by either dilated lines (unbounded cylinders), planes, dilated points (spheres).

## Methods

`impl<N: Real> ContactKinematic<N>`

[src]

`impl<N: Real> ContactKinematic<N>`

`pub fn new() -> Self`

[src]

`pub fn new() -> Self`

Initializes an empty contact kinematic.

All the contact kinematic information must be filled using methods
prefixed by `set_`

.

`pub fn transform1(&mut self, m: &Isometry<N>)`

[src]

`pub fn transform1(&mut self, m: &Isometry<N>)`

Applies the given transformation to the first set of contact information.

`pub fn transform2(&mut self, m: &Isometry<N>)`

[src]

`pub fn transform2(&mut self, m: &Isometry<N>)`

Applies the given transformation to the second set of contact information.

`pub fn dilation1(&self) -> N`

[src]

`pub fn dilation1(&self) -> N`

The dilation of the first solid.

`pub fn dilation2(&self) -> N`

[src]

`pub fn dilation2(&self) -> N`

The dilation of the second solid.

`pub fn local1(&self) -> Point<N>`

[src]

`pub fn local1(&self) -> Point<N>`

The tracked point in local space of the first solid.

This may not correspond to the contact point in the local space of the first since it does not takes the dilation into account.

`pub fn local2(&self) -> Point<N>`

[src]

`pub fn local2(&self) -> Point<N>`

The tracked point in local space of the second solid.

This may not correspond to the contact point in the local space of the second solid since it does not takes the dilation into account.

`pub fn feature1(&self) -> FeatureId`

[src]

`pub fn feature1(&self) -> FeatureId`

The shape-dependent identifier of the feature of the first solid on which lies the contact point.

`pub fn feature2(&self) -> FeatureId`

[src]

`pub fn feature2(&self) -> FeatureId`

The shape-dependent identifier of the feature of the second solid on which lies the contact point.

`pub fn set_dilation1(&mut self, margin: N)`

[src]

`pub fn set_dilation1(&mut self, margin: N)`

Sets the dilation of the first solid.

`pub fn set_dilation2(&mut self, margin: N)`

[src]

`pub fn set_dilation2(&mut self, margin: N)`

Sets the dilation of the second solid.

`pub fn set_plane1(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normal: Unit<Vector<N>>

)

[src]

`pub fn set_plane1(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normal: Unit<Vector<N>>

)

Define as a plane the local approximation of the shape of the first solid.

`pub fn set_plane2(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normal: Unit<Vector<N>>

)

[src]

`pub fn set_plane2(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normal: Unit<Vector<N>>

)

Define as a plane the local approximation of the shape of the second solid.

`pub fn set_line1(`

&mut self,

fid: FeatureId,

pt: Point<N>,

dir: Unit<Vector<N>>,

normals: PolyhedralCone<N>

)

[src]

`pub fn set_line1(`

&mut self,

fid: FeatureId,

pt: Point<N>,

dir: Unit<Vector<N>>,

normals: PolyhedralCone<N>

)

Define as a line the local approximation of the shape of the second solid.

`pub fn set_line2(`

&mut self,

fid: FeatureId,

pt: Point<N>,

dir: Unit<Vector<N>>,

normals: PolyhedralCone<N>

)

[src]

`pub fn set_line2(`

&mut self,

fid: FeatureId,

pt: Point<N>,

dir: Unit<Vector<N>>,

normals: PolyhedralCone<N>

)

Define as a line the local approximation of the shape of the second solid.

`pub fn set_point1(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normals: PolyhedralCone<N>

)

[src]

`pub fn set_point1(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normals: PolyhedralCone<N>

)

Define as a point the local approximation of the shape of the second solid.

`pub fn set_point2(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normals: PolyhedralCone<N>

)

[src]

`pub fn set_point2(`

&mut self,

fid: FeatureId,

pt: Point<N>,

normals: PolyhedralCone<N>

)

Define as a point the local approximation of the shape of the second solid.

`pub fn contact(`

&self,

m1: &Isometry<N>,

m2: &Isometry<N>,

default_normal1: &Unit<Vector<N>>

) -> Option<Contact<N>>

[src]

`pub fn contact(`

&self,

m1: &Isometry<N>,

m2: &Isometry<N>,

default_normal1: &Unit<Vector<N>>

) -> Option<Contact<N>>

Computes the updated contact points with the new positions of the solids.

The vector `default_normal1`

is the normal of the resulting contactc
in the rare case where the contact normal cannot be determined by the update.
Typically, this should be set to the latest contact normal known.

## Trait Implementations

`impl<N: Clone + Real> Clone for ContactKinematic<N>`

[src]

`impl<N: Clone + Real> Clone for ContactKinematic<N>`

`fn clone(&self) -> ContactKinematic<N>`

[src]

`fn clone(&self) -> ContactKinematic<N>`

Returns a copy of the value. Read more

`fn clone_from(&mut self, source: &Self)`

1.0.0[src]

`fn clone_from(&mut self, source: &Self)`

Performs copy-assignment from `source`

. Read more

`impl<N: Debug + Real> Debug for ContactKinematic<N>`

[src]

`impl<N: Debug + Real> Debug for ContactKinematic<N>`

## Auto Trait Implementations

`impl<N> Send for ContactKinematic<N> where`

N: Scalar,

`impl<N> Send for ContactKinematic<N> where`

N: Scalar,

`impl<N> Sync for ContactKinematic<N> where`

N: Scalar,

`impl<N> Sync for ContactKinematic<N> where`

N: Scalar,