using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace StgSharp_Geometry { internal class PointOnCircle : Point { private Circle _bindedItem; public Circle geometryItem { get { return _bindedItem; } set { _bindedItem = value; } } private float _angle; public float Angle { get { return _angle; } set { _angle = value; } } private float[] _angularVelocity; public PointOnCircle(Circle c, float p, float angle, int counts) { _bindedItem = c; _angle = (angle + counts * (360.0f / counts))*(float)(2*Math.PI/360); } public void AddRotation(float[] aFunc) { if (aFunc.Length==10) { _angularVelocity=aFunc; } else { throw new Exception("Parameters are too much or too few!"); } } public void onRender() { if (_angularVelocity!=null) { for (int i = 0; i < 10; i++) { } } this.X = (float)(_bindedItem.Center.X + _bindedItem.Radius * Math.Cos(_angle)); this.Y = (float)(_bindedItem.Center.X + _bindedItem.Radius * Math.Sin(_angle)); } } }