Exemplo n.º 1
0
        public uint Read(ref GenericFieldFloat1 data, IInBitStream bitstream)
        {
            var propertyMask = (uint)0;


            if (bitstream.ReadMask())
            {
                var coherenceField = bitstream.ReadFixedPoint(24, 2400);
                data.number   = coherenceToUnityConverters.ToUnityfloat(coherenceField);
                propertyMask |= 0b00000000000000000000000000000001;
            }

            return(propertyMask);
        }
        public void GenericFieldFloat1(IOutBitStream bitstream, GenericFieldFloat1 data)
        {
            var converted_number = coherenceToUnityConverters.FromUnityfloat(data.number);

            bitstream.WriteFixedPoint(converted_number, 24, 2400);
        }
Exemplo n.º 3
0
        private void DeserializeGenericFieldFloat1(Coherence.Replication.Protocol.Definition.IInBitStream protocolStream)
        {
            var ignored = new GenericFieldFloat1();

            unityReaders.Read(ref ignored, protocolStream);
        }
        public void GenericFieldFloat1(IInBitStream bitstream, ref GenericFieldFloat1 data)
        {
            var number = bitstream.ReadFixedPoint(24, 2400);

            data.number = coherenceToUnityConverters.ToUnityfloat(number);
        }