예제 #1
0
        public Position3 GetInverted()
        {
            Position3 result = new Position3(this);

            result.Invert();
            return(result);
        }
예제 #2
0
        public Position3 DifferenceWith(Position3 position)
        {
            Position3 result = new Position3();

            result.SetDifferenceOf(this, position);
            return(result);
        }
예제 #3
0
        public Position3(Position3 first, Position3 second)
        {
            this.Point    = Vector3.ZERO_VECTOR;
            this.Rotation = new Rotation();

            this.SetCombinationOf(first, second);
        }
예제 #4
0
 public void SetDifferenceOf(Position3 position, Position3 subtrahend)
 {
     this.Point = subtrahend.Rotation.TurnBackward(position.Point - subtrahend.Point);
     this.Rotation.SetDifferenceOf(position.Rotation, subtrahend.Rotation);
 }
예제 #5
0
 public void SetCombinationOf(Position3 first, Position3 second)
 {
     this.Point = first.Point + first.Rotation.Turn(second.Point);
     this.Rotation.SetCombinationOf(first.Rotation, second.Rotation);
 }
예제 #6
0
 public Position3 CombineWith(Position3 position)
 {
     return(new Position3(this, position));
 }
예제 #7
0
 public void SetPosition(Position3 position)
 {
     this.Point = position.Point;
     this.Rotation.SetTurn(position.Rotation);
 }
예제 #8
0
 public Position3(Position3 position)
 {
     this.Point    = position.Point;
     this.Rotation = position.Rotation;
 }
예제 #9
0
 public Vector3 ChangePositioningFrom(Position3 position, Vector3 vector)
 {
     return(this.Rotation.TurnBackward(position.Rotation.Turn(vector) + position.Point - this.Point));
 }
예제 #10
0
 public Vector3 ChangePositioningTo(Position3 position, Vector3 vector)
 {
     return(position.Rotation.TurnBackward(this.Rotation.Turn(vector) + this.Point - position.Point));
 }