using System.Numerics; #pragma warning disable CS0660, CS0661 namespace ComputeSharp; /// /// A that maps the HLSL type. /// public partial struct Float3 { /// /// Creates a new value with the same value for all its components. /// /// The value to use for the components of the new instance. public static implicit operator Float3(float x) => new(x, x, x); /// /// Casts a value to a one. /// /// The input value to cast. public static unsafe implicit operator Vector3(Float3 xyz) => *(Vector3*)&xyz; /// /// Casts a value to a one. /// /// The input value to cast. public static unsafe implicit operator Float3(Vector3 xyz) => *(Float3*)&xyz; /// /// Casts a value to a one. /// /// The input value to cast. /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. public static implicit operator Double3(Float3 xyz) => default; /// /// Casts a value to a one. /// /// The input value to cast. /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. public static explicit operator Int3(Float3 xyz) => default; /// /// Casts a value to a one. /// /// The input value to cast. /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. public static explicit operator UInt3(Float3 xyz) => default; }