#pragma warning disable CS0660, CS0661
namespace ComputeSharp;
///
/// A that maps the HLSL type.
///
public partial struct Bool3
{
///
/// Creates a new instance with the specified parameters.
///
/// The value to assign to the first vector component.
/// The value to assign to the second vector component.
/// The value to assign to the third vector component.
public Bool3(bool x, bool y, bool z)
{
this.x = x ? 1 : 0;
this.y = y ? 1 : 0;
this.z = z ? 1 : 0;
}
///
/// Creates a new instance with the specified parameters.
///
/// The value to assign to the first and second vector components.
/// The value to assign to the third vector component.
public Bool3(Bool2 xy, bool z)
{
this.x = xy.X ? 1 : 0;
this.y = xy.Y ? 1 : 0;
this.z = z ? 1 : 0;
}
///
/// Creates a new instance with the specified parameters.
///
/// The value to assign to the first vector component.
/// The value to assign to the second and thirt vector components.
public Bool3(bool x, Bool2 yz)
{
this.x = x ? 1 : 0;
this.y = yz.X ? 1 : 0;
this.z = yz.Y ? 1 : 0;
}
///
/// 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 Bool3(bool x) => new(x, x, x);
}