internal static extern float Sphere_Distance(IntPtr handle, ref Urho.Vector3 point);
internal static extern Vector3 Camera_ScreenToWorldPoint(IntPtr handle, ref Urho.Vector3 screenPos);
internal static extern float Camera_GetDistanceSquared(IntPtr handle, ref Urho.Vector3 worldPos);
internal static extern void Constraint_SetWorldPosition(IntPtr handle, ref Urho.Vector3 position);
internal static extern Vector2 Camera_WorldToScreenPoint(IntPtr handle, ref Urho.Vector3 worldPos);
/// <summary> /// Set offset transform. /// </summary> public void SetTransform(Urho.Vector3 position, Urho.Quaternion rotation) { Runtime.ValidateRefCounted(this); CollisionShape_SetTransform(handle, ref position, ref rotation); }
internal static extern void Constraint_SetOtherAxis(IntPtr handle, ref Urho.Vector3 axis);
internal static extern void CollisionShape_SetCone(IntPtr handle, float diameter, float height, ref Urho.Vector3 position, ref Urho.Quaternion rotation);
/// <summary> /// Set as a cone. /// </summary> public void SetCone(float diameter, float height, Urho.Vector3 position, Urho.Quaternion rotation) { Runtime.ValidateRefCounted(this); CollisionShape_SetCone(handle, diameter, height, ref position, ref rotation); }
internal static extern bool XmlElement_SetVector3(IntPtr handle, string name, ref Urho.Vector3 value);
/// <summary> /// Set a Vector3 attribute. /// </summary> public bool SetVector3(string name, Urho.Vector3 value) { Runtime.ValidateObject(this); return(XmlElement_SetVector3(handle, name, ref value)); }
public SphereShape(Urho.Vector3 center, float radius) { Runtime.Validate(typeof(SphereShape)); handle = Sphere_Sphere1(ref center, radius); OnSphereCreated(); }
internal static extern IntPtr Sphere_Sphere1(ref Urho.Vector3 center, float radius);
/// <summary> /// Return distance of a point to the surface, or 0 if inside. /// </summary> public float Distance(Urho.Vector3 point) { Runtime.ValidateObject(this); return(Sphere_Distance(handle, ref point)); }
/// <summary> /// Set offset position. /// </summary> private void SetPosition(Urho.Vector3 position) { Runtime.ValidateRefCounted(this); CollisionShape_SetPosition(handle, ref position); }
internal static extern void CollisionShape_SetConvexHull(IntPtr handle, IntPtr model, uint lodLevel, ref Urho.Vector3 scale, ref Urho.Vector3 position, ref Urho.Quaternion rotation);
internal static extern void CollisionShape_SetTransform(IntPtr handle, ref Urho.Vector3 position, ref Urho.Quaternion rotation);
/// <summary> /// Set as a convex hull from Model. /// </summary> public void SetConvexHull(Model model, uint lodLevel, Urho.Vector3 scale, Urho.Vector3 position, Urho.Quaternion rotation) { Runtime.ValidateRefCounted(this); CollisionShape_SetConvexHull(handle, (object)model == null ? IntPtr.Zero : model.Handle, lodLevel, ref scale, ref position, ref rotation); }
/// <summary> /// Set constraint position relative to the other body. If connected to the static world, is a world space position. /// </summary> private void SetOtherPosition(Urho.Vector3 position) { Runtime.ValidateRefCounted(this); Constraint_SetOtherPosition(handle, ref position); }
internal static extern void CollisionShape_SetCustomConvexHull(IntPtr handle, IntPtr custom, ref Urho.Vector3 scale, ref Urho.Vector3 position, ref Urho.Quaternion rotation);
/// <summary> /// Set constraint rotation relative to the other body by specifying the axis. /// </summary> public void SetOtherAxis(Urho.Vector3 axis) { Runtime.ValidateRefCounted(this); Constraint_SetOtherAxis(handle, ref axis); }
/// <summary> /// Set as a convex hull from CustomGeometry. /// </summary> public void SetCustomConvexHull(CustomGeometry custom, Urho.Vector3 scale, Urho.Vector3 position, Urho.Quaternion rotation) { Runtime.ValidateRefCounted(this); CollisionShape_SetCustomConvexHull(handle, (object)custom == null ? IntPtr.Zero : custom.Handle, ref scale, ref position, ref rotation); }
/// <summary> /// Set constraint world space position. Resets both own and other body relative position, ie. zeroes the constraint error. /// </summary> public void SetWorldPosition(Urho.Vector3 position) { Runtime.ValidateRefCounted(this); Constraint_SetWorldPosition(handle, ref position); }
internal static extern void CollisionShape_SetSize(IntPtr handle, ref Urho.Vector3 size);
/// <summary> /// Convert a world space point to normalized screen coordinates (0.0 - 1.0). /// </summary> public Vector2 WorldToScreenPoint(Urho.Vector3 worldPos) { Runtime.ValidateRefCounted(this); return(Camera_WorldToScreenPoint(handle, ref worldPos)); }
/// <summary> /// Set shape size. /// </summary> private void SetSize(Urho.Vector3 size) { Runtime.ValidateRefCounted(this); CollisionShape_SetSize(handle, ref size); }
/// <summary> /// Convert normalized screen coordinates (0.0 - 1.0) and distance (in Z coordinate) to a world space point. The distance can not be closer than the near clip plane. /// </summary> public Vector3 ScreenToWorldPoint(Urho.Vector3 screenPos) { Runtime.ValidateRefCounted(this); return(Camera_ScreenToWorldPoint(handle, ref screenPos)); }
internal static extern void CollisionShape_SetPosition(IntPtr handle, ref Urho.Vector3 position);
/// <summary> /// Return squared distance to position. In orthographic mode uses only Z coordinate. /// </summary> public float GetDistanceSquared(Urho.Vector3 worldPos) { Runtime.ValidateRefCounted(this); return(Camera_GetDistanceSquared(handle, ref worldPos)); }
/// <summary> /// Test if a point is inside. /// </summary> public Intersection IsInside(Urho.Vector3 point) { Runtime.ValidateObject(this); return(Sphere_IsInside(handle, ref point)); }