Type Alias libvnc_sys::rfb::rfbClientRec

source ·
pub type rfbClientRec = _rfbClientRec;

Aliased Type§

struct rfbClientRec {
Show 97 fields pub screen: *mut _rfbScreenInfo, pub scaledScreen: *mut _rfbScreenInfo, pub PalmVNC: i8, pub clientData: *mut c_void, pub clientGoneHook: Option<unsafe extern "C" fn(_: *mut _rfbClientRec)>, pub sock: i32, pub host: *mut i8, pub protocolMajorVersion: i32, pub protocolMinorVersion: i32, pub client_thread: u64, pub state: u32, pub reverseConnection: i8, pub onHold: i8, pub readyForSetColourMapEntries: i8, pub useCopyRect: i8, pub preferredEncoding: i32, pub correMaxWidth: i32, pub correMaxHeight: i32, pub viewOnly: i8, pub authChallenge: [u8; 16], pub copyRegion: *mut sraRegion, pub copyDX: i32, pub copyDY: i32, pub modifiedRegion: *mut sraRegion, pub requestedRegion: *mut sraRegion, pub startDeferring: timeval, pub startPtrDeferring: timeval, pub lastPtrX: i32, pub lastPtrY: i32, pub lastPtrButtons: i32, pub translateFn: Option<unsafe extern "C" fn(_: *mut i8, _: *mut rfbPixelFormat, _: *mut rfbPixelFormat, _: *mut i8, _: *mut i8, _: i32, _: i32, _: i32)>, pub translateLookupTable: *mut i8, pub format: rfbPixelFormat, pub updateBuf: [i8; 30000], pub ublen: i32, pub statEncList: *mut _rfbStatList, pub statMsgList: *mut _rfbStatList, pub rawBytesEquivalent: i32, pub bytesSent: i32, pub compStream: z_stream_s, pub compStreamInited: i8, pub zlibCompressLevel: u32, pub tightQualityLevel: i32, pub zsStruct: [z_stream_s; 4], pub zsActive: [i8; 4], pub zsLevel: [i32; 4], pub tightCompressLevel: i32, pub compStreamInitedLZO: i8, pub lzoWrkMem: *mut i8, pub fileTransfer: _rfbFileTransferData, pub lastKeyboardLedState: i32, pub enableSupportedMessages: i8, pub enableSupportedEncodings: i8, pub enableServerIdentity: i8, pub enableKeyboardLedState: i8, pub enableLastRectEncoding: i8, pub enableCursorShapeUpdates: i8, pub enableCursorPosUpdates: i8, pub useRichCursorEncoding: i8, pub cursorWasChanged: i8, pub cursorWasMoved: i8, pub cursorX: i32, pub cursorY: i32, pub useNewFBSize: i8, pub newFBSizePending: i8, pub prev: *mut _rfbClientRec, pub next: *mut _rfbClientRec, pub refCount: i32, pub refCountMutex: pthread_mutex_t, pub deleteCond: pthread_cond_t, pub outputMutex: pthread_mutex_t, pub updateMutex: pthread_mutex_t, pub updateCond: pthread_cond_t, pub zrleData: *mut c_void, pub zywrleLevel: i32, pub zywrleBuf: [i32; 4096], pub progressiveSliceY: i32, pub extensions: *mut _rfbExtensionData, pub zrleBeforeBuf: *mut i8, pub paletteHelper: *mut c_void, pub sendMutex: pthread_mutex_t, pub beforeEncBuf: *mut i8, pub beforeEncBufSize: i32, pub afterEncBuf: *mut i8, pub afterEncBufSize: i32, pub afterEncBufLen: i32, pub tightEncoding: u32, pub turboSubsampLevel: i32, pub turboQualityLevel: i32, pub sslctx: *mut _rfbSslCtx, pub wsctx: *mut _wsCtx, pub wspath: *mut i8, pub pipe_notify_client_thread: [i32; 2], pub clientFramebufferUpdateRequestHook: Option<unsafe extern "C" fn(_: *mut _rfbClientRec, _: *mut rfbFramebufferUpdateRequestMsg)>, pub useExtDesktopSize: i8, pub requestedDesktopSizeChange: i32, pub lastDesktopSizeChangeError: i32,
}

Fields§

§screen: *mut _rfbScreenInfo

back pointer to the screen

§scaledScreen: *mut _rfbScreenInfo

points to a scaled version of the screen buffer in cl->scaledScreenList

§PalmVNC: i8

how did the client tell us it wanted the screen changed? Ultra style or palm style?

§clientData: *mut c_void

private data. You should put any application client specific data into a struct and let clientData point to it. Don’t forget to free the struct via clientGoneHook!

This is useful if the IO functions have to behave client specific.

§clientGoneHook: Option<unsafe extern "C" fn(_: *mut _rfbClientRec)>§sock: i32§host: *mut i8§protocolMajorVersion: i32§protocolMinorVersion: i32§client_thread: u64§state: u32§reverseConnection: i8§onHold: i8§readyForSetColourMapEntries: i8§useCopyRect: i8§preferredEncoding: i32§correMaxWidth: i32§correMaxHeight: i32§viewOnly: i8§authChallenge: [u8; 16]§copyRegion: *mut sraRegion

< the destination region of the copy

§copyDX: i32

< the translation by which the copy happens

§copyDY: i32

< the translation by which the copy happens

§modifiedRegion: *mut sraRegion§requestedRegion: *mut sraRegion

As part of the FramebufferUpdateRequest, a client can express interest in a subrectangle of the whole framebuffer. This is stored in the requestedRegion member. In the normal case this is the whole framebuffer if the client is ready, empty if it’s not.

§startDeferring: timeval

The following member represents the state of the “deferred update” timer

  • when the framebuffer is modified and the client is ready, in most cases it is more efficient to defer sending the update by a few milliseconds so that several changes to the framebuffer can be combined into a single update.
§startPtrDeferring: timeval§lastPtrX: i32§lastPtrY: i32§lastPtrButtons: i32§translateFn: Option<unsafe extern "C" fn(_: *mut i8, _: *mut rfbPixelFormat, _: *mut rfbPixelFormat, _: *mut i8, _: *mut i8, _: i32, _: i32, _: i32)>

translateFn points to the translation function which is used to copy and translate a rectangle from the framebuffer to an output buffer.

§translateLookupTable: *mut i8§format: rfbPixelFormat§updateBuf: [i8; 30000]§ublen: i32§statEncList: *mut _rfbStatList§statMsgList: *mut _rfbStatList§rawBytesEquivalent: i32§bytesSent: i32§compStream: z_stream_s§compStreamInited: i8§zlibCompressLevel: u32§tightQualityLevel: i32

the quality level is also used by ZYWRLE and TightPng

§zsStruct: [z_stream_s; 4]§zsActive: [i8; 4]§zsLevel: [i32; 4]§tightCompressLevel: i32§compStreamInitedLZO: i8§lzoWrkMem: *mut i8§fileTransfer: _rfbFileTransferData§lastKeyboardLedState: i32

< keep track of last value so we can send change events

§enableSupportedMessages: i8

< client supports SupportedMessages encoding

§enableSupportedEncodings: i8

< client supports SupportedEncodings encoding

§enableServerIdentity: i8

< client supports ServerIdentity encoding

§enableKeyboardLedState: i8

< client supports KeyboardState encoding

§enableLastRectEncoding: i8

< client supports LastRect encoding

§enableCursorShapeUpdates: i8

< client supports cursor shape updates

§enableCursorPosUpdates: i8

< client supports cursor position updates

§useRichCursorEncoding: i8

< rfbEncodingRichCursor is preferred

§cursorWasChanged: i8

< cursor shape update should be sent

§cursorWasMoved: i8

< cursor position update should be sent

§cursorX: i32

< the coordinates of the cursor, if enableCursorShapeUpdates = FALSE

§cursorY: i32

< the coordinates of the cursor, if enableCursorShapeUpdates = FALSE

§useNewFBSize: i8

< client supports NewFBSize encoding

§newFBSizePending: i8

< framebuffer size was changed

§prev: *mut _rfbClientRec§next: *mut _rfbClientRec§refCount: i32

whenever a client is referenced, the refCount has to be incremented and afterwards decremented, so that the client is not cleaned up while being referenced. Use the functions rfbIncrClientRef(cl) and rfbDecrClientRef(cl);

§refCountMutex: pthread_mutex_t§deleteCond: pthread_cond_t§outputMutex: pthread_mutex_t§updateMutex: pthread_mutex_t§updateCond: pthread_cond_t§zrleData: *mut c_void§zywrleLevel: i32§zywrleBuf: [i32; 4096]§progressiveSliceY: i32

if progressive updating is on, this variable holds the current y coordinate of the progressive slice.

§extensions: *mut _rfbExtensionData§zrleBeforeBuf: *mut i8

for threaded zrle

§paletteHelper: *mut c_void§sendMutex: pthread_mutex_t§beforeEncBuf: *mut i8§beforeEncBufSize: i32§afterEncBuf: *mut i8§afterEncBufSize: i32§afterEncBufLen: i32§tightEncoding: u32§turboSubsampLevel: i32§turboQualityLevel: i32§sslctx: *mut _rfbSslCtx§wsctx: *mut _wsCtx§wspath: *mut i8§pipe_notify_client_thread: [i32; 2]§clientFramebufferUpdateRequestHook: Option<unsafe extern "C" fn(_: *mut _rfbClientRec, _: *mut rfbFramebufferUpdateRequestMsg)>

clientFramebufferUpdateRequestHook is called when a client requests a frame buffer update.

§useExtDesktopSize: i8§requestedDesktopSizeChange: i32§lastDesktopSizeChangeError: i32