oocalls.h
来自「一个非常美妙的proxy。功能强大。基于sip的协议。如果还要的话」· C头文件 代码 · 共 786 行 · 第 1/3 页
H
786 行
typedef int (*cb_OnReceivedDTMF) (struct OOH323CallData *call, const char *dtmf);/** * This structure holds all of the H.323 signaling callback function * addresses. * @see ooH323EpSetH323Callbacks */typedef struct OOH323CALLBACKS { cb_OnAlerting onNewCallCreated; cb_OnAlerting onAlerting; cb_OnIncomingCall onIncomingCall; cb_OnOutgoingCall onOutgoingCall; cb_OnCallEstablished onCallEstablished; cb_OnCallForwarded onCallForwarded; cb_OnCallCleared onCallCleared; cb_OpenLogicalChannels openLogicalChannels; cb_OnReceivedDTMF onReceivedDTMF;} OOH323CALLBACKS;/** * This function is used to create a new call entry. * @param type Type of the call (incoming/outgoing) * @param callToken Call Token, an uniques identifier for the call * * @return Pointer to a newly created call */EXTERN OOH323CallData* ooCreateCall(char *type, char *callToken);/** * This function is used to add a call to the list of existing calls. * @param call Pointer to the call to be added. * @return OO_OK, on success. OO_FAILED, on failure */EXTERN int ooAddCallToList (OOH323CallData *call);/** * This function is used to set the caller ID for a call. * * @param call Handle to the call * @param callerid caller ID value * @return OO_OK, on success. OO_FAILED, otherwise. */EXTERN int ooCallSetCallerId(OOH323CallData* call, const char* callerid);/** * This function is used to set calling party number for a particular call. * @param call Handle to the call. * @param number Calling Party number value. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallSetCallingPartyNumber(OOH323CallData *call, const char *number);/** * This function is used to retrieve calling party number of a particular call. * @param call Handle to the call. * @param buffer Handle to the buffer in which value will be returned. * @param len Length of the supplied buffer. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallGetCallingPartyNumber(OOH323CallData *call, char *buffer, int len);/** * This function is used to retrieve called party number of a particular call. * @param call Handle to the call. * @param buffer Handle to the buffer in which value will be returned. * @param len Length of the supplied buffer. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallGetCalledPartyNumber(OOH323CallData *call, char *buffer, int len);/** * This function is used to set called party number for a particular call. * @param call Handle to the call. * @param number Called Party number value. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallSetCalledPartyNumber(OOH323CallData *call, const char *number);/** * This function is used to clear the local aliases used by this call. * @param call Handle to the call. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallClearAliases(OOH323CallData *call);/** * This function is used to add an H323ID alias to be used by local endpoint * for a particular call. * @param call Handle to the call * @param h323id H323ID to add for the local endpoint for the call. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddAliasH323ID(OOH323CallData *call, const char* h323id);/** * This function is used to add an dialedDigits alias to be used by local * endpoint for a particular call. * @param call Handle to the call * @param dialedDigits DialedDigits to add for the local endpoint for call. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddAliasDialedDigits (OOH323CallData *call, const char* dialedDigits);/** * This function is used to add an email-id alias to be used by local * endpoint for a particular call. * @param call Handle to the call * @param email Email-id to add for the local endpoint for call. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddAliasEmailID(OOH323CallData *call, const char* email);/** * This function is used to add an email-id alias to be used by local * endpoint for a particular call. * @param call Handle to the call * @param url URL-id to add for the local endpoint for call. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddAliasURLID(OOH323CallData *call, const char* url);/** * This is a helper function used by other call related add aliases functions * to add a particular alias. This function is not supposed to be called * directly. * @param call Handle to the call * @param aliasType Type of alias being added * @param value Alias value * @param local Whether alias is for local party or remote party * * @return OO_OK, on success. OO_FAILED, on failure. */int ooCallAddAlias (OOH323CallData *call, int aliasType, const char *value, OOBOOL local);/** * This function is used to add an dialed digits alias for the remote endpoint * involved in a particular call. * @param call Handle to the call * @param dialedDigits dialedDigits alias to add for the remote endpoint. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddRemoteAliasDialedDigits (OOH323CallData *call, const char* dialedDigits);/** * This function is used to add an H323ID alias for the remote endpoint * involved in a particular call. * @param call Handle to the call * @param h323id H323ID to add for the remote endpoint. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddRemoteAliasH323ID(OOH323CallData *call, const char* h323id);/** * This function is used to add G7231 capability for the call. The * "ooCallAdd...Capability" functions allow to override the global endpoint * capabilities and use specific capabilities for specific calls. * @param call Call for which capability has to be added. * @param cap Capability to be added. * @param txframes Number of frames per packet for transmission. * @param rxframes Number of frames per packet for reception. * @param silenceSuppression Indicates support for silenceSuppression. * @param dir Direction of capability.OORX, OOTX, OORXANDTX * @param startReceiveChannel Callback function to start receive channel. * @param startTransmitChannel Callback function to start transmit channel. * @param stopReceiveChannel Callback function to stop receive channel. * @param stopTransmitChannel Callback function to stop transmit channel. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddG7231Capability(OOH323CallData *call, int cap, int txframes, int rxframes, OOBOOL silenceSuppression, int dir, cb_StartReceiveChannel startReceiveChannel, cb_StartTransmitChannel startTransmitChannel, cb_StopReceiveChannel stopReceiveChannel, cb_StopTransmitChannel stopTransmitChannel);/** * This function is used to add G729 capability for the call. The * "ooCallAdd...Capability" functions allow to override the global endpoint * capabilities and use specific capabilities for specific calls. * @param call Call for which capability has to be added. * @param cap Capability to be added. * @param txframes Number of frames per packet for transmission. * @param rxframes Number of frames per packet for reception. * @param dir Direction of capability.OORX, OOTX, OORXANDTX * @param startReceiveChannel Callback function to start receive channel. * @param startTransmitChannel Callback function to start transmit channel. * @param stopReceiveChannel Callback function to stop receive channel. * @param stopTransmitChannel Callback function to stop transmit channel. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddG729Capability(OOH323CallData *call, int cap, int txframes, int rxframes, int dir, cb_StartReceiveChannel startReceiveChannel, cb_StartTransmitChannel startTransmitChannel, cb_StopReceiveChannel stopReceiveChannel, cb_StopTransmitChannel stopTransmitChannel);/** * This function is used to add G711 capability for the call. The * "ooCallAdd...Capability" functions allow to override the global endpoint * capabilities and use specific capabilities for specific calls. * @param call Call for which capability has to be added. * @param cap Capability to be added. * @param txframes Number of frames per packet for transmission. * @param rxframes Number of frames per packet for reception. * @param dir Direction of capability.OORX, OOTX, OORXANDTX * @param startReceiveChannel Callback function to start receive channel. * @param startTransmitChannel Callback function to start transmit channel. * @param stopReceiveChannel Callback function to stop receive channel. * @param stopTransmitChannel Callback function to stop transmit channel. * * @return OO_OK, on success. OO_FAILED, on failure. */EXTERN int ooCallAddG711Capability(OOH323CallData *call, int cap, int txframes, int rxframes, int dir, cb_StartReceiveChannel startReceiveChannel, cb_StartTransmitChannel startTransmitChannel, cb_StopReceiveChannel stopReceiveChannel, cb_StopTransmitChannel stopTransmitChannel);/** * This function is used to add GSM capability for the call. The * "ooCallAdd...Capability" functions allow to override the global endpoint * capabilities and use specific capabilities for specific calls. * @param call Call for which capability has to be added. * @param cap Type of GSM capability to be added. * @param framesPerPkt Number of GSM frames pre packet. * @param comfortNoise Comfort noise spec for the capability. * @param scrambled Scrambled enabled/disabled for the capability. * @param dir Direction of capability.OORX, OOTX, OORXANDTX * @param startReceiveChannel Callback function to start receive channel. * @param startTransmitChannel Callback function to start transmit channel. * @param stopReceiveChannel Callback function to stop receive channel. * @param stopTransmitChannel Callback function to stop transmit channel. *
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?