EFT.Trainer.UI.Render.DrawBezierLine(UnityEngine.Vector2, UnityEngine.Vector2, UnityEngine.Vector2, UnityEngine.Vector2, UnityEngine.Color, float, int)

Here are the examples of the csharp api EFT.Trainer.UI.Render.DrawBezierLine(UnityEngine.Vector2, UnityEngine.Vector2, UnityEngine.Vector2, UnityEngine.Vector2, UnityEngine.Color, float, int) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

1 Examples 7

19 View Source File : Render.cs
License : MIT License
Project Creator : sailro

public static void DrawCircle(Vector2 center, float radius, Color color, float width, int segmentsPerQuarter)
		{
			var rh = radius / 2;

			var p1 = new Vector2(center.x, center.y - radius);
			var p1TanA = new Vector2(center.x - rh, center.y - radius);
			var p1TanB = new Vector2(center.x + rh, center.y - radius);

			var p2 = new Vector2(center.x + radius, center.y);
			var p2TanA = new Vector2(center.x + radius, center.y - rh);
			var p2TanB = new Vector2(center.x + radius, center.y + rh);

			var p3 = new Vector2(center.x, center.y + radius);
			var p3TanA = new Vector2(center.x - rh, center.y + radius);
			var p3TanB = new Vector2(center.x + rh, center.y + radius);

			var p4 = new Vector2(center.x - radius, center.y);
			var p4TanA = new Vector2(center.x - radius, center.y - rh);
			var p4TanB = new Vector2(center.x - radius, center.y + rh);

			DrawBezierLine(p1, p1TanB, p2, p2TanA, color, width, segmentsPerQuarter);
			DrawBezierLine(p2, p2TanB, p3, p3TanB, color, width, segmentsPerQuarter);
			DrawBezierLine(p3, p3TanA, p4, p4TanB, color, width, segmentsPerQuarter);
			DrawBezierLine(p4, p4TanA, p1, p1TanA, color, width, segmentsPerQuarter);
		}