FarseerPhysics.Dynamics.Contacts.Contact.evaluate C# (CSharp) Method

evaluate() public method

Evaluate this contact with your own manifold and transforms.
public evaluate ( Manifold &manifold, Transform &transformA, Transform &transformB ) : void
manifold FarseerPhysics.Collision.Manifold The manifold.
transformA Transform The first transform.
transformB Transform The second transform.
return void
		void evaluate( ref Manifold manifold, ref Transform transformA, ref Transform transformB )
		{
			switch( _type )
			{
				case ContactType.Polygon:
					Collision.Collision.collidePolygons( ref manifold, (PolygonShape)fixtureA.shape, ref transformA, (PolygonShape)fixtureB.shape, ref transformB );
					break;
				case ContactType.PolygonAndCircle:
					Collision.Collision.collidePolygonAndCircle( ref manifold, (PolygonShape)fixtureA.shape, ref transformA, (CircleShape)fixtureB.shape, ref transformB );
					break;
				case ContactType.EdgeAndCircle:
					Collision.Collision.collideEdgeAndCircle( ref manifold, (EdgeShape)fixtureA.shape, ref transformA, (CircleShape)fixtureB.shape, ref transformB );
					break;
				case ContactType.EdgeAndPolygon:
					Collision.Collision.collideEdgeAndPolygon( ref manifold, (EdgeShape)fixtureA.shape, ref transformA, (PolygonShape)fixtureB.shape, ref transformB );
					break;
				case ContactType.ChainAndCircle:
					var chain = (ChainShape)fixtureA.shape;
					chain.getChildEdge( _edge, childIndexA );
					Collision.Collision.collideEdgeAndCircle( ref manifold, _edge, ref transformA, (CircleShape)fixtureB.shape, ref transformB );
					break;
				case ContactType.ChainAndPolygon:
					var loop2 = (ChainShape)fixtureA.shape;
					loop2.getChildEdge( _edge, childIndexA );
					Collision.Collision.collideEdgeAndPolygon( ref manifold, _edge, ref transformA, (PolygonShape)fixtureB.shape, ref transformB );
					break;
				case ContactType.Circle:
					Collision.Collision.collideCircles( ref manifold, (CircleShape)fixtureA.shape, ref transformA, (CircleShape)fixtureB.shape, ref transformB );
					break;
			}
		}