/// <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); }
/// <summary> /// Initializes a new instance of the <see cref="Short4"/> 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 Short4(Single x, Single y, Single z, Single w) { this.X = (UInt16)PackedVectorUtils.PackSigned(PackingMask, x); this.Y = (UInt16)PackedVectorUtils.PackSigned(PackingMask, y); this.Z = (UInt16)PackedVectorUtils.PackSigned(PackingMask, z); this.W = (UInt16)PackedVectorUtils.PackSigned(PackingMask, w); }
/// <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); }
/// <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); }
/// <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); }
/// <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); }
/// <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); }
/// <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); }
/// <summary> /// Initializes a new instance of the <see cref="Int1"/> structure from the specified vector components. /// </summary> /// <param name="x">The x-component from which to create the packed instance.</param> public Int1(Single x) { this.X = (UInt32)PackedVectorUtils.PackSigned(PackingMask, x); }
/// <summary> /// Initializes a new instance of the <see cref="SByte2"/> 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 SByte2(Single x, Single y) { this.X = (Byte)PackedVectorUtils.PackSigned(PackingMask, x); this.Y = (Byte)PackedVectorUtils.PackSigned(PackingMask, y); }
/// <summary> /// Initializes a new instance of the <see cref="SByte2"/> structure from the specified vector. /// </summary> /// <param name="vector">The vector from which to create the packed instance.</param> public SByte2(Vector2 vector) { this.X = (Byte)PackedVectorUtils.PackSigned(PackingMask, vector.X); this.Y = (Byte)PackedVectorUtils.PackSigned(PackingMask, vector.Y); }
/// <summary> /// Initializes a new instance of the <see cref="SByte1"/> structure from the specified vector components. /// </summary> /// <param name="x">The x-component from which to create the packed instance.</param> public SByte1(Single x) { this.X = (Byte)PackedVectorUtils.PackSigned(PackingMask, x); }
/// <summary> /// Initializes a new instance of the <see cref="Int2"/> 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 Int2(Single x, Single y) { this.X = PackedVectorUtils.PackSigned(PackingMask, x); this.Y = PackedVectorUtils.PackSigned(PackingMask, y); }
/// <summary> /// Initializes a new instance of the <see cref="Int2"/> structure from the specified vector. /// </summary> /// <param name="vector">The vector from which to create the packed instance.</param> public Int2(Vector2 vector) { this.X = PackedVectorUtils.PackSigned(PackingMask, vector.X); this.Y = PackedVectorUtils.PackSigned(PackingMask, vector.Y); }