ParsecHostHookStart
ParsecStatusParsecHostHookStart(Parsec *ps,ParsecHookModemode,ParsecHookStatusCallbackstatusCallback,ParsecHookVideoCallbackvideoCallback,ParsecHookAudioCallbackaudioCallback,void *opaque)
Hook video, audio, or both in the current process. Windows only.
The default behavior submits the hooked audio to Parsec and sends the data to connected clients. the videoCallback
or audioCallback
may be left NULL to if this default behavior is desired. Otherwise, you can set custom callback to handle the hooked data.
Parameters
Direction | Name | Description |
---|---|---|
in | ps | Parsec instance returned by ParsecInit . |
in | mode | ParsecHookMode selecting video, audio, or both. |
in | statusCallback | Called when a there is an error in the frame callback ParsecHookStatusCallback . |
in | videoCallback | Called when a video frame is acquired. May be NULL. See ParsecHookVideoCallback |
in | audioCallback | Called when audio data is acquired. May be NULL. See ParsecHookAudioCallback |
in | opaque | User supplied context to be passed through statusCallback , videoCallback , and audioCallback . |
Returns
PARSEC_OK
if the current process was successfully hooked, otherwise a ParsecStatus
error value.