public override void Rotate(float SIN, float COS) { if (OnRotateStart != null) { if (!OnRotateStart.Invoke(this, SIN, COS)) { return; } } if (OnRotating != null) { OnRotating.Invoke(this, SIN, COS); } foreach (GlFigure F in this.figuresAmount) { F.Rotate(SIN, COS); } if (OnRotated != null) { OnRotated.Invoke(this, SIN, COS); } }
public override void Rotate(float SIN, float COS) { if (OnRotateStart != null) { if (!OnRotateStart.Invoke(this, SIN, COS)) { return; } } if (OnRotating != null) { OnRotating.Invoke(this, SIN, COS); } for (int i = 0; i < vertexes.Length; i++) { vertexes[i] = new GlVectorR2(vertexes[i].X - polyCenter.X, vertexes[i].Y - polyCenter.Y).getRotatedVector(-SIN, COS).fromPointToPoint(polyCenter); } if (OnRotated != null) { OnRotated.Invoke(this, SIN, COS); } }
public override void Rotate(float SIN, float COS) { float oldX = this.Center.X; float oldY = this.Center.Y; if (OnRotateStart != null) { if (!OnRotateStart.Invoke(this, SIN, COS)) { return; } } if (OnRotating != null) { OnRotating.Invoke(this, SIN, COS); } this.directVector = this.directVector.getRotatedVector(-SIN, COS); updatePointsPosition(); if (OnRotated != null) { OnRotated.Invoke(this, SIN, COS); } }
/// <summary> /// Rotates the point around itself /// </summary> /// <param name="SIN">sin of counter-wise rotation angle</param> /// <param name="COS">cos of counter-wise rotation angle</param> public override void Rotate(float SIN, float COS) { if (OnRotateStart != null) { if (!OnRotateStart.Invoke(this, SIN, COS)) { return; } } if (OnRotating != null) { OnRotating.Invoke(this, SIN, COS); } if (OnRotated != null) { OnRotated.Invoke(this, SIN, COS); } return; }
public override void Rotate(float SIN, float COS) { if (OnRotateStart != null) { if (!OnRotateStart.Invoke(this, SIN, COS)) { return; } } if (OnRotating != null) { OnRotating.Invoke(this, SIN, COS); } this.directVector = this.DirectVector.getRotatedVector(-SIN, COS); if (OnRotated != null) { OnRotated.Invoke(this, SIN, COS); } }