ParsecClientSendUserData
ParsecStatusParsecClientSendUserData(Parsec *ps,uint32_tid,const char *text)
Send a user-defined string to the host.
The host may set an optional callback to process user-defined messages. These messages may be any type of data serialized via JSON or XML. Note: Parsec's peer-to-peer protocol is optimized for targeted bitrate, low-latency media streaming and not bulk file transfer. Very large messages sent via this function may unnecessarily burden both the client and the host.
Parameters
Direction | Name | Description |
---|---|---|
in | ps | Parsec instance returned by ParsecInit . |
in | id | User-defined message ID considered by the host. |
in | text | Null-terminated UTF-8 string. |
Returns
PARSEC_OK
if the message was sent successfully, otherwise a ParsecStatus
error value.