コード例 #1
0
 /// <summary>
 /// Encode this PDU to the PduMarshaler.
 /// </summary>
 /// <param name="marshaler">This is used to encode the fields of this PDU.</param>
 public override void Encode(PduMarshaler marshaler)
 {
     marshaler.WriteUInt32(this.Header.cbSize);
     marshaler.WriteUInt32((uint)this.Header.PacketType);
     marshaler.WriteByte(this.PresentatioinId);
     marshaler.WriteByte((byte)this.Version);
     marshaler.WriteByte((byte)this.Flags);
     marshaler.WriteByte(this.Reserved);
     marshaler.WriteUInt64(this.HnsTimestamp);
     marshaler.WriteUInt64(this.HnsDuration);
     marshaler.WriteUInt16(this.CurrentPacketIndex);
     marshaler.WriteUInt16(this.PacketsInSample);
     marshaler.WriteUInt32(this.SampleNumber);
     marshaler.WriteUInt32(this.cbSample);
     if (this.pSample != null)
     {
         marshaler.WriteBytes(this.pSample);
     }
     marshaler.WriteByte(this.Reserved2);
 }
コード例 #2
0
 /// <summary>
 /// Encode this PDU to the PduMarshaler.
 /// </summary>
 /// <param name="marshaler">This is used to encode the fields of this PDU.</param>
 public override void Encode(PduMarshaler marshaler)
 {
     marshaler.WriteUInt32(this.Header.cbSize);
     marshaler.WriteUInt32((uint)this.Header.PacketType);
     marshaler.WriteByte(this.PresentatioinId);
     marshaler.WriteByte((byte)this.Version);
     marshaler.WriteByte((byte)this.Command);
     marshaler.WriteByte(this.FrameRate);
     marshaler.WriteUInt16(this.AverageBitrateKbps);
     marshaler.WriteUInt16(this.Reserved);
     marshaler.WriteUInt32(this.SourceWidth);
     marshaler.WriteUInt32(this.SourceHeight);
     marshaler.WriteUInt32(this.ScaledWidth);
     marshaler.WriteUInt32(this.ScaledHeight);
     marshaler.WriteUInt64(this.hnsTimestampOffset);
     marshaler.WriteUInt64(this.GeometryMappingId);
     marshaler.WriteBytes(this.VideoSubtypeId, 0, 16);
     marshaler.WriteUInt32(this.cbExtra);
     if (this.pExtraData != null)
     {
         marshaler.WriteBytes(this.pExtraData);
     }
     marshaler.WriteByte(this.Reserved2);
 }
コード例 #3
0
 /// <summary>
 /// Encode this PDU to the PduMarshaler.
 /// </summary>
 /// <param name="marshaler">This is used to encode the fields of this PDU.</param>
 public override void Encode(PduMarshaler marshaler)
 {
     base.Encode(marshaler);
     marshaler.WriteUInt16(this.cacheEntriesCount);
     for (ushort i = 0; i < cacheEntriesCount; i++)
     {
         marshaler.WriteUInt64(cacheEntries[i].cacheKey);
         marshaler.WriteUInt64(cacheEntries[i].bitmapLength);
     }
 }
コード例 #4
0
 /// <summary>
 /// Encode this PDU to the PduMarshaler.
 /// </summary>
 /// <param name="marshaler">This is used to encode the fields of this PDU.</param>
 public override void Encode(PduMarshaler marshaler)
 {
     base.Encode(marshaler);
     marshaler.WriteUInt16(this.surfaceId);
     marshaler.WriteUInt64(this.cacheKey);
     marshaler.WriteUInt16(this.cacheSlot);
     marshaler.WriteUInt16(this.rectSrc.left);
     marshaler.WriteUInt16(this.rectSrc.top);
     marshaler.WriteUInt16(this.rectSrc.right);
     marshaler.WriteUInt16(this.rectSrc.bottom);
 }
コード例 #5
0
 /// <summary>
 /// Encode this PDU to the PduMarshaler.
 /// </summary>
 /// <param name="marshaler">This is used to encode the fields of this PDU.</param>
 public override void Encode(PduMarshaler marshaler)
 {
     base.Encode(marshaler);
     marshaler.WriteUInt16(this.surfaceId);
     marshaler.WriteUInt64(this.windowId);
     marshaler.WriteUInt32(this.mappedWidth);
     marshaler.WriteUInt32(this.mappedHeight);
 }
コード例 #6
0
        /// <summary>
        /// Encode this PDU to the PduMarshaler.
        /// </summary>
        /// <param name="marshaler">This is used to encode the fields of this PDU.</param>
        public override void Encode(PduMarshaler marshaler)
        {
            marshaler.WriteUInt32(this.cbGeometryData);
            marshaler.WriteUInt32((uint)this.Version);
            marshaler.WriteUInt64(this.MappingId);
            marshaler.WriteUInt32((uint)this.UpdateType);
            marshaler.WriteUInt32(this.Flags);
            marshaler.WriteUInt64(this.TopLevelId);
            marshaler.WriteUInt32(this.Left);
            marshaler.WriteUInt32(this.Top);
            marshaler.WriteUInt32(this.Right);
            marshaler.WriteUInt32(this.Bottom);
            marshaler.WriteUInt32(this.TopLevelLeft);
            marshaler.WriteUInt32(this.TopLevelTop);
            marshaler.WriteUInt32(this.TopLevelRight);
            marshaler.WriteUInt32(this.TopLevelBottom);
            marshaler.WriteUInt32((uint)this.GeometryType);
            marshaler.WriteUInt32(this.cbGeometryBuffer);

            //Encode RGNDATA
            if (this.cbGeometryBuffer != 0)
            {
                marshaler.WriteUInt32(this.pGeometryBuffer.rdh.dwSize);
                marshaler.WriteUInt32(this.pGeometryBuffer.rdh.iType);
                marshaler.WriteUInt32(this.pGeometryBuffer.rdh.nCount);
                marshaler.WriteUInt32(this.pGeometryBuffer.rdh.nRgnSize);
                EncodeRect(this.pGeometryBuffer.rdh.rcBound, marshaler);

                if (this.pGeometryBuffer.Buffer != null)
                {
                    foreach (RECT rct in this.pGeometryBuffer.Buffer)
                    {
                        EncodeRect(rct, marshaler);
                    }
                }
            }
            marshaler.WriteByte(this.Reserved2);
        }