public float ReadFloat() { IntFloatUnion ifu = new IntFloatUnion(); ifu.i = IPAddress.NetworkToHostOrder(br.ReadInt32()); return(ifu.f); }
public void WriteFloat(float _v) { IntFloatUnion ifu = new IntFloatUnion(); ifu.f = _v; WriteInt(ifu.i); }
public static int FloatAsInt(float value) { IntFloatUnion u = new IntFloatUnion { b = value }; return(u.a); }
public static float IntAsFloat(int value) { IntFloatUnion u = new IntFloatUnion { a = value }; return(u.b); }