Click or drag to resize
Ab4d.SharpEngine logo

MathUtilsGetCenterPosition(Vector2, PositionTypes, Single, Single) Method

Calculates 2D center position from the specified position, position type and size. This method ignores the Z direction (Front and Back).

Namespace: Ab4d.SharpEngine.Utilities
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 5.0.1075+bc537c8d217949260b11f66ee86aefa6456ac517
Syntax
C#
public static Vector2 GetCenterPosition(
	 in Vector2 position,
	PositionTypes positionType,
	float width,
	float height
)

Parameters

position  Vector2
Vector3
positionType  PositionTypes
type of position
width  Single
width
height  Single
height

Return Value

Vector2
center position
See Also