/// <summary> /// Reads the server's Initialization message, specifically the remote Framebuffer's properties. See RFB Doc v. 3.8 section 6.1.5. /// </summary> /// <returns>Returns a Framebuffer object representing the geometry and properties of the remote host.</returns> public FrameBufferInfos ReadServerInit() { int w = (int)reader.ReadUInt16(); int h = (int)reader.ReadUInt16(); FrameBufferInfos buffer = FrameBufferInfos.FromPixelFormat(reader.ReadBytes(16), w, h); int length = (int)reader.ReadUInt32(); buffer.DesktopName = GetString(reader.ReadBytes(length)); return(buffer); }