コード例 #1
0
 public Vec4(Vec4f v)
 {
     this.x = v.x;
     this.y = v.y;
     this.z = v.z;
     this.w = v.w;
 }
コード例 #2
0
 public void Set(Vec4f v)
 {
     if (v != null)
     {
         x = v.x;
         y = v.y;
         z = v.z;
         w = v.w;
     }
 }
コード例 #3
0
 /// <summary>
 /// Calculate the distance between current vector and v
 /// </summary>
 /// <param name="v">vector</param>
 public double Distance(Vec4f v)
 {
     return(System.Math.Sqrt((x - v.x) * (x - v.x) + (y - v.y) * (y - v.y) + (z - v.z) * (z - v.z) + (w - v.w) * (w - v.w)));
 }