Ejemplo n.º 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedUnsignedInt4"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public NormalizedUnsignedInt4(Vector4 vector)
 {
     this.X = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.X);
     this.Y = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.Y);
     this.Z = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.Z);
     this.W = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.W);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedByte4"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public NormalizedByte4(Vector4 vector)
 {
     this.X = (Byte)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.X);
     this.Y = (Byte)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.Y);
     this.Z = (Byte)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.Z);
     this.W = (Byte)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.W);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedUnsignedInt4"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 /// <param name="w">The w-component from  which to create the packed instance.</param>
 public NormalizedUnsignedInt4(Single x, Single y, Single z, Single w)
 {
     this.X = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, x);
     this.Y = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, y);
     this.Z = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, z);
     this.W = PackedVectorUtils.PackNormalizedUnsigned(PackingMask, w);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Short4"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public Short4(Vector4 vector)
 {
     this.X = (UInt16)PackedVectorUtils.PackSigned(PackingMask, vector.X);
     this.Y = (UInt16)PackedVectorUtils.PackSigned(PackingMask, vector.Y);
     this.Z = (UInt16)PackedVectorUtils.PackSigned(PackingMask, vector.Z);
     this.W = (UInt16)PackedVectorUtils.PackSigned(PackingMask, vector.W);
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Converts the <see cref="UnsignedInt3"/> instance to a <see cref="Vector3"/> instance.
 /// </summary>
 /// <returns>The <see cref="Vector3"/> instance which was created.</returns>
 public Vector3 ToVector3()
 {
     return(new Vector3(
                PackedVectorUtils.UnpackUnsigned(PackingMask, X),
                PackedVectorUtils.UnpackUnsigned(PackingMask, Y),
                PackedVectorUtils.UnpackUnsigned(PackingMask, Z)));
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Int4"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public Int4(Vector4 vector)
 {
     this.X = PackedVectorUtils.PackSigned(PackingMask, vector.X);
     this.Y = PackedVectorUtils.PackSigned(PackingMask, vector.Y);
     this.Z = PackedVectorUtils.PackSigned(PackingMask, vector.Z);
     this.W = PackedVectorUtils.PackSigned(PackingMask, vector.W);
 }
Ejemplo n.º 7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Int4"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 /// <param name="w">The w-component from  which to create the packed instance.</param>
 public Int4(Single x, Single y, Single z, Single w)
 {
     this.X = PackedVectorUtils.PackSigned(PackingMask, x);
     this.Y = PackedVectorUtils.PackSigned(PackingMask, y);
     this.Z = PackedVectorUtils.PackSigned(PackingMask, z);
     this.W = PackedVectorUtils.PackSigned(PackingMask, w);
 }
Ejemplo n.º 8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedUnsignedShort4"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 /// <param name="w">The w-component from  which to create the packed instance.</param>
 public NormalizedUnsignedShort4(Single x, Single y, Single z, Single w)
 {
     this.X = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, x);
     this.Y = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, y);
     this.Z = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, z);
     this.W = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, w);
 }
Ejemplo n.º 9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Byte4"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 /// <param name="w">The w-component from  which to create the packed instance.</param>
 public SByte4(Single x, Single y, Single z, Single w)
 {
     this.X = (Byte)PackedVectorUtils.PackSigned(PackingMask, x);
     this.Y = (Byte)PackedVectorUtils.PackSigned(PackingMask, y);
     this.Z = (Byte)PackedVectorUtils.PackSigned(PackingMask, z);
     this.W = (Byte)PackedVectorUtils.PackSigned(PackingMask, w);
 }
Ejemplo n.º 10
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedUnsignedShort4"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public NormalizedUnsignedShort4(Vector4 vector)
 {
     this.X = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.X);
     this.Y = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.Y);
     this.Z = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.Z);
     this.W = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, vector.W);
 }
Ejemplo n.º 11
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SByte4"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public SByte4(Vector4 vector)
 {
     this.X = (Byte)PackedVectorUtils.PackSigned(PackingMask, vector.X);
     this.Y = (Byte)PackedVectorUtils.PackSigned(PackingMask, vector.Y);
     this.Z = (Byte)PackedVectorUtils.PackSigned(PackingMask, vector.Z);
     this.W = (Byte)PackedVectorUtils.PackSigned(PackingMask, vector.W);
 }
Ejemplo n.º 12
0
 /// <summary>
 /// Converts the <see cref="NormalizedUnsignedShort4"/> instance to a <see cref="Vector4"/> instance.
 /// </summary>
 /// <returns>The <see cref="Vector4"/> instance which was created.</returns>
 public Vector4 ToVector4()
 {
     return(new Vector4(
                PackedVectorUtils.UnpackNormalizedUnsigned(PackingMask, X),
                PackedVectorUtils.UnpackNormalizedUnsigned(PackingMask, Y),
                PackedVectorUtils.UnpackNormalizedUnsigned(PackingMask, Z),
                PackedVectorUtils.UnpackNormalizedUnsigned(PackingMask, W)));
 }
Ejemplo n.º 13
0
 /// <summary>
 /// Converts the <see cref="Short2"/> instance to a <see cref="Vector2"/> instance.
 /// </summary>
 /// <returns>The <see cref="Vector2"/> instance which was created.</returns>
 public Vector2 ToVector2()
 {
     return(new Vector2(
                PackedVectorUtils.UnpackSigned(PackingMask, X),
                PackedVectorUtils.UnpackSigned(PackingMask, Y)));
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedUnsignedShort1"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 public NormalizedUnsignedShort1(Single x)
 {
     this.X = (UInt16)PackedVectorUtils.PackNormalizedUnsigned(PackingMask, x);
 }
Ejemplo n.º 15
0
 /// <summary>
 /// Converts the <see cref="NormalizedSByte1"/> instance to a <see cref="Single"/> instance.
 /// </summary>
 /// <returns>The <see cref="Single"/> instance which was created.</returns>
 public Single ToSingle()
 {
     return(PackedVectorUtils.UnpackNormalizedSigned(PackingMask, X));
 }
Ejemplo n.º 16
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedSByte1"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 public NormalizedSByte1(Single x)
 {
     this.X = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, x);
 }
Ejemplo n.º 17
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedShort3"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 public NormalizedShort3(Single x, Single y, Single z)
 {
     this.X = (UInt16)PackedVectorUtils.PackNormalizedSigned(PackingMask, x);
     this.Y = (UInt16)PackedVectorUtils.PackNormalizedSigned(PackingMask, y);
     this.Z = (UInt16)PackedVectorUtils.PackNormalizedSigned(PackingMask, z);
 }
Ejemplo n.º 18
0
 /// <summary>
 /// Initializes a new instance of the <see cref="UnsignedInt3"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 public UnsignedInt3(Single x, Single y, Single z)
 {
     this.X = PackedVectorUtils.PackUnsigned(PackingMask, x);
     this.Y = PackedVectorUtils.PackUnsigned(PackingMask, y);
     this.Z = PackedVectorUtils.PackUnsigned(PackingMask, z);
 }
Ejemplo n.º 19
0
 /// <summary>
 /// Converts the <see cref="Byte1"/> instance to a <see cref="Single"/> instance.
 /// </summary>
 /// <returns>The <see cref="Single"/> instance which was created.</returns>
 public Single ToSingle()
 {
     return(PackedVectorUtils.UnpackUnsigned(PackingMask, X));
 }
Ejemplo n.º 20
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Short2"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public Short2(Vector2 vector)
 {
     this.X = (UInt16)PackedVectorUtils.PackSigned(PackingMask, vector.X);
     this.Y = (UInt16)PackedVectorUtils.PackSigned(PackingMask, vector.Y);
 }
Ejemplo n.º 21
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedSByte3"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 public NormalizedSByte3(Single x, Single y, Single z)
 {
     this.X = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, x);
     this.Y = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, y);
     this.Z = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, z);
 }
Ejemplo n.º 22
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedSByte3"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public NormalizedSByte3(Vector3 vector)
 {
     this.X = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.X);
     this.Y = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.Y);
     this.Z = (Byte)PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.Z);
 }
Ejemplo n.º 23
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Byte3"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 public Byte3(Single x, Single y, Single z)
 {
     this.X = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, x);
     this.Y = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, y);
     this.Z = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, z);
 }
Ejemplo n.º 24
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Byte3"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public Byte3(Vector3 vector)
 {
     this.X = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, vector.X);
     this.Y = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, vector.Y);
     this.Z = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, vector.Z);
 }
Ejemplo n.º 25
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Byte1"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 public Byte1(Single x)
 {
     this.X = (Byte)PackedVectorUtils.PackUnsigned(PackingMask, x);
 }
Ejemplo n.º 26
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedInt3"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public NormalizedInt3(Vector3 vector)
 {
     this.X = PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.X);
     this.Y = PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.Y);
     this.Z = PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.Z);
 }
Ejemplo n.º 27
0
 /// <summary>
 /// Initializes a new instance of the <see cref="UnsignedInt3"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public UnsignedInt3(Vector3 vector)
 {
     this.X = PackedVectorUtils.PackUnsigned(PackingMask, vector.X);
     this.Y = PackedVectorUtils.PackUnsigned(PackingMask, vector.Y);
     this.Z = PackedVectorUtils.PackUnsigned(PackingMask, vector.Z);
 }
Ejemplo n.º 28
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedInt3"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 /// <param name="z">The z-component from  which to create the packed instance.</param>
 public NormalizedInt3(Single x, Single y, Single z)
 {
     this.X = PackedVectorUtils.PackNormalizedSigned(PackingMask, x);
     this.Y = PackedVectorUtils.PackNormalizedSigned(PackingMask, y);
     this.Z = PackedVectorUtils.PackNormalizedSigned(PackingMask, z);
 }
Ejemplo n.º 29
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Short3"/> structure from the specified vector components.
 /// </summary>
 /// <param name="x">The x-component from  which to create the packed instance.</param>
 /// <param name="y">The y-component from  which to create the packed instance.</param>
 public Short2(Single x, Single y)
 {
     this.X = (UInt16)PackedVectorUtils.PackSigned(PackingMask, x);
     this.Y = (UInt16)PackedVectorUtils.PackSigned(PackingMask, y);
 }
Ejemplo n.º 30
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NormalizedShort3"/> structure from the specified vector.
 /// </summary>
 /// <param name="vector">The vector from which to create the packed instance.</param>
 public NormalizedShort3(Vector3 vector)
 {
     this.X = (UInt16)PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.X);
     this.Y = (UInt16)PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.Y);
     this.Z = (UInt16)PackedVectorUtils.PackNormalizedSigned(PackingMask, vector.Z);
 }