コード例 #1
0
 /// <summary>
 /// Expands the packed representation into a <see cref="float"/>.
 /// </summary>
 /// <returns>The <see cref="float"/>.</returns>
 public float ToSingle()
 {
     return(HalfTypeHelper.Unpack(this.PackedValue));
 }
コード例 #2
0
 /// <inheritdoc />
 public void PackFromVector4(Vector4 vector)
 {
     this.PackedValue = HalfTypeHelper.Pack(vector.X);
 }
コード例 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="HalfSingle"/> struct.
 /// </summary>
 /// <param name="single">The single component.</param>
 public HalfSingle(float single)
 {
     this.PackedValue = HalfTypeHelper.Pack(single);
 }