]> sjero.net Git - linphone/blobdiff - coreapi/linphonecore.h
improve call quality indicator (takes into account video)
[linphone] / coreapi / linphonecore.h
index ab8836a5d7d475559c4c0a9aa884f851abb3d569..37001d367a4663dd5ce8c5369aa6da8f41a91a44 100644 (file)
@@ -47,14 +47,30 @@ typedef struct _LinphoneCore LinphoneCore;
 struct _LpConfig;
 
 
-struct _LCSipTransports{
+/**
+ * Linphone core SIP transport ports.
+ * Use with #linphone_core_set_sip_transports
+ * @ingroup initializing
+ */
+typedef struct _LCSipTransports{
+       /**
+        * udp port to listening on, negative value if not set
+        * */
        int udp_port;
+       /**
+        * tcp port to listening on, negative value if not set
+        * */
        int tcp_port;
+       /**
+        * dtls port to listening on, negative value if not set
+        * */
        int dtls_port;
+       /**
+        * tls port to listening on, negative value if not set
+        * */
        int tls_port;
-};
+} LCSipTransports;
 
-typedef struct _LCSipTransports LCSipTransports;
 
 /**
  * Object that represents a SIP address.
@@ -327,14 +343,16 @@ struct _LinphoneCallStats {
        LinphoneUpnpState       upnp_state; /**< State of uPnP processing. */
        float download_bandwidth; /**<Download bandwidth measurement of received stream, expressed in kbit/s, including IP/UDP/RTP headers*/
        float upload_bandwidth; /**<Download bandwidth measurement of sent stream, expressed in kbit/s, including IP/UDP/RTP headers*/
+       float local_late_rate; /**<percentage of packet received too late over last second*/
+       float local_loss_rate; /**<percentage of lost packet over last second*/
 };
 
 /**
  * @}
 **/
 
-const LinphoneCallStats *linphone_call_get_audio_stats(const LinphoneCall *call);
-const LinphoneCallStats *linphone_call_get_video_stats(const LinphoneCall *call);
+const LinphoneCallStats *linphone_call_get_audio_stats(LinphoneCall *call);
+const LinphoneCallStats *linphone_call_get_video_stats(LinphoneCall *call);
 
 
 /** Callback prototype */
@@ -934,7 +952,12 @@ int linphone_core_update_call(LinphoneCore *lc, LinphoneCall *call, const Linpho
 int linphone_core_defer_call_update(LinphoneCore *lc, LinphoneCall *call);
 
 int linphone_core_accept_call_update(LinphoneCore *lc, LinphoneCall *call, const LinphoneCallParams *params);
-
+/**
+ * @ingroup media_parameters
+ * Get default call parameters reflecting current linphone core configuration
+ * @param LinphoneCore object
+ * @return  LinphoneCallParams
+ */
 LinphoneCallParams *linphone_core_create_default_call_parameters(LinphoneCore *lc);
 
 LinphoneCall *linphone_core_get_call_by_remote_address(LinphoneCore *lc, const char *remote_address);
@@ -982,16 +1005,23 @@ const MSList *linphone_core_get_video_codecs(const LinphoneCore *lc);
 int linphone_core_set_video_codecs(LinphoneCore *lc, MSList *codecs);
 
 bool_t linphone_core_payload_type_enabled(LinphoneCore *lc, const PayloadType *pt);
-
+/**
+ * Enable payload type
+ * @param linphone core
+ * @param pt payload type to enable, can be retrieve from #linphone_core_find_payload_type
+ * @param TRUE if enabled
+ * @return 0 if succed
+ *
+ */
 int linphone_core_enable_payload_type(LinphoneCore *lc, PayloadType *pt, bool_t enable);
 
 /**
- * Wildcard value used by #linphone_core_find_payload_type to ignore rate in search algirithm
+ * Wildcard value used by #linphone_core_find_payload_type to ignore rate in search algorithm
  * @ingroup media_parameters
  */
 #define LINPHONE_FIND_PAYLOAD_IGNORE_RATE -1
 /**
- * Wildcard value used by #linphone_core_find_payload_type to ignore channel in search algirithm
+ * Wildcard value used by #linphone_core_find_payload_type to ignore channel in search algorithm
  * @ingroup media_parameters
  */
 #define LINPHONE_FIND_PAYLOAD_IGNORE_CHANNELS -1
@@ -1370,7 +1400,13 @@ void linphone_core_refresh_registers(LinphoneCore* lc);
 /* Path to the file storing secrets cache */
 void linphone_core_set_zrtp_secrets_file(LinphoneCore *lc, const char* file);
 const char *linphone_core_get_zrtp_secrets_file(LinphoneCore *lc);
-
+/**
+ * Search from the list of current calls if a remote address match uri
+ * @ingroup call_control
+ * @param lc
+ * @param uri which should match call remote uri
+ * @return LinphoneCall or NULL is no match is found
+ */
 const LinphoneCall* linphone_core_find_call_from_uri(LinphoneCore *lc, const char *uri);
 
 int linphone_core_add_to_conference(LinphoneCore *lc, LinphoneCall *call);
@@ -1385,8 +1421,19 @@ int linphone_core_terminate_conference(LinphoneCore *lc);
 int linphone_core_get_conference_size(LinphoneCore *lc);
 int linphone_core_start_conference_recording(LinphoneCore *lc, const char *path);
 int linphone_core_stop_conference_recording(LinphoneCore *lc);
-
+/**
+ * Get the maximum number of simultaneous calls Linphone core can manage at a time. All new call above this limit are declined with a busy answer
+ * @ingroup initializing
+ * @param lc core
+ * @return max number of simultaneous calls
+ */
 int linphone_core_get_max_calls(LinphoneCore *lc);
+/**
+ * Set the maximum number of simultaneous calls Linphone core can manage at a time. All new call above this limit are declined with a busy answer
+ * @ingroup initializing
+ * @param lc core
+ * @param max number of simultaneous calls
+ */
 void linphone_core_set_max_calls(LinphoneCore *lc, int max);
 
 bool_t linphone_core_sound_resources_locked(LinphoneCore *lc);