Commit 8efc6e41 authored by Benjamin REIS's avatar Benjamin REIS

Merge branch 'dev_refactor_cpp' into dev_chatroom_list_subscription

parents 584de095 9e921fa3
......@@ -53,7 +53,7 @@ if(WIN32)
endif()
add_executable(linphonecsh ${LINPHONECSH_SOURCE_FILES})
target_link_libraries(linphonecsh ${LINPHONE_LIBS_FOR_TOOLS} ${ORTP_LIBRARIES})
target_link_libraries(linphonecsh ${LINPHONE_LIBS_FOR_TOOLS} ${BCTOOLBOX_CORE_LIBRARIES} ${ORTP_LIBRARIES})
set_target_properties(linphonecsh PROPERTIES LINK_FLAGS "${LINPHONE_LDFLAGS}")
set(INSTALL_TARGETS linphonec linphonecsh)
......
......@@ -83,6 +83,7 @@ set(LINPHONE_SOURCE_FILES_C
linphonecore.c
linphone_tunnel_config.c
localplayer.c
logging.c
lpc2xml.c
lpconfig.c
lsd.c
......@@ -140,6 +141,7 @@ bc_git_version(liblinphone ${PROJECT_VERSION})
add_definitions(
-DUSE_BELLESIP
-DLIBLINPHONE_EXPORTS
-DBCTBX_LOG_DOMAIN="liblinphone"
)
set(LIBS
......
......@@ -24,11 +24,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#include "c-wrapper/c-wrapper.h"
#include "dial-plan/dial-plan.h"
#if !_WIN32
#include "regex.h"
#endif
#include <bctoolbox/crypto.h>
#include <bctoolbox/regex.h>
// TODO: From coreapi. Remove me later.
#include "private.h"
......@@ -112,25 +109,6 @@ static char* _get_identity(const LinphoneAccountCreator *creator) {
return identity;
}
static bool_t is_matching_regex(const char *entry, const char* regex) {
#if _WIN32
return TRUE;
#else
regex_t regex_pattern;
char err_msg[256];
int res;
res = regcomp(&regex_pattern, regex, REG_EXTENDED | REG_NOSUB);
if(res != 0) {
regerror(res, &regex_pattern, err_msg, sizeof(err_msg));
ms_error("Could not compile regex '%s: %s", regex, err_msg);
return FALSE;
}
res = regexec(&regex_pattern, entry, 0, NULL, 0);
regfree(&regex_pattern);
return (res != REG_NOMATCH);
#endif
}
LinphoneProxyConfig * linphone_account_creator_create_proxy_config(const LinphoneAccountCreator *creator) {
LinphoneAuthInfo *info;
LinphoneProxyConfig *cfg = linphone_core_create_proxy_config(creator->core);
......@@ -383,7 +361,7 @@ LinphoneAccountCreatorUsernameStatus linphone_account_creator_set_username(Linph
return LinphoneAccountCreatorUsernameStatusTooLong;
} else if (use_phone_number && !linphone_proxy_config_is_phone_number(NULL, username)) {
return LinphoneAccountCreatorUsernameStatusInvalid;
} else if (regex && !is_matching_regex(username, regex)) {
} else if (regex && !bctbx_is_matching_regex(username, regex)) {
return LinphoneAccountCreatorUsernameStatusInvalidCharacters;
} else if (validate_uri(username, NULL, NULL) != 0) {
return LinphoneAccountCreatorUsernameStatusInvalid;
......@@ -506,10 +484,10 @@ const char * linphone_account_creator_get_display_name(const LinphoneAccountCrea
}
LinphoneAccountCreatorEmailStatus linphone_account_creator_set_email(LinphoneAccountCreator *creator, const char *email) {
if (!email || !is_matching_regex(email, "^.+@.+\\..*$")) {
if (!email || !bctbx_is_matching_regex(email, "^.+@.+\\..*$")) {
return LinphoneAccountCreatorEmailStatusMalformed;
}
if (!is_matching_regex(email, "^.+@.+\\.[A-Za-z]{2}[A-Za-z]*$")) {
if (!bctbx_is_matching_regex(email, "^.+@.+\\.[A-Za-z]{2}[A-Za-z]*$")) {
return LinphoneAccountCreatorEmailStatusInvalidCharacters;
}
set_string(&creator->email, email, TRUE);
......
This diff is collapsed.
......@@ -84,8 +84,8 @@ LinphoneChatRoom *linphone_core_get_chat_room (LinphoneCore *lc, const LinphoneA
return L_GET_C_BACK_PTR(L_GET_CPP_PTR_FROM_C_OBJECT(lc)->getOrCreateBasicChatRoom(*L_GET_CPP_PTR_FROM_C_OBJECT(addr)));
}
LinphoneChatRoom *linphone_core_create_client_group_chat_room (LinphoneCore *lc, const char *subject) {
return L_GET_C_BACK_PTR(L_GET_CPP_PTR_FROM_C_OBJECT(lc)->createClientGroupChatRoom(L_C_TO_STRING(subject)));
LinphoneChatRoom *linphone_core_create_client_group_chat_room (LinphoneCore *lc, const char *subject, bool_t fallback) {
return L_GET_C_BACK_PTR(L_GET_CPP_PTR_FROM_C_OBJECT(lc)->createClientGroupChatRoom(L_C_TO_STRING(subject), !!fallback));
}
LinphoneChatRoom *_linphone_core_create_server_group_chat_room (LinphoneCore *lc, LinphonePrivate::SalCallOp *op) {
......
......@@ -685,9 +685,12 @@ void LocalConference::onCallTerminating (LinphoneCall *call) {
ms_message("conference_check_uninit(): size=%i", getSize());
if ((remote_count == 1) && !m_terminating)
convertConferenceToCall();
if (remote_count == 0) {
if (m_localParticipantStream)
if (m_localParticipantStream){
removeLocalEndpoint();
linphone_core_soundcard_hint_check(m_core);
}
if (m_recordEndpoint) {
ms_audio_conference_remove_member(m_conf, m_recordEndpoint);
ms_audio_endpoint_destroy(m_recordEndpoint);
......
......@@ -167,6 +167,7 @@ static LinphoneCore *_linphone_factory_create_core (
LpConfig *config = lp_config_new_with_factory(config_path, factory_config_path);
LinphoneCore *lc = _linphone_core_new_with_config(cbs, config, user_data, system_context, automatically_start);
lp_config_unref(config);
bctbx_uninit_logger();
return lc;
}
......
......@@ -31,6 +31,11 @@ if (ENABLE_DOC OR ENABLE_CXX_WRAPPER OR ENABLE_CSHARP_WRAPPER OR ENABLE_JAVA_WRA
endforeach ()
string(CONCAT DOXYGEN_INPUT ${DOXYGEN_INPUT} " \"${CMAKE_CURRENT_SOURCE_DIR}\"")
string(CONCAT DOXYGEN_INPUT ${DOXYGEN_INPUT} " \"${PROJECT_SOURCE_DIR}/coreapi/help/examples/C\"")
if(ENABLE_DOC)
set(GENERATE_HTML "YES")
else()
set(GENERATE_HTML "NO")
endif()
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
set(DOC_INPUT_FILES ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
${CMAKE_CURRENT_SOURCE_DIR}/doxygen.dox
......@@ -39,14 +44,15 @@ if (ENABLE_DOC OR ENABLE_CXX_WRAPPER OR ENABLE_CSHARP_WRAPPER OR ENABLE_JAVA_WRA
set(XML_DIR "${CMAKE_CURRENT_BINARY_DIR}/xml")
set(LINPHONE_DOXYGEN_XML_DIR ${XML_DIR} PARENT_SCOPE)
add_custom_command(OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/html/index.html" "${XML_DIR}/index.xml"
COMMAND ${CMAKE_COMMAND} -E remove -f html/* xml/*
COMMAND ${CMAKE_COMMAND} -E remove -f html/* xml/*
COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
DEPENDS ${DOC_INPUT_FILES}
)
add_custom_target(linphone-doc ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/html/index.html" "${XML_DIR}/index.xml")
install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html" "${XML_DIR}"
DESTINATION "${CMAKE_INSTALL_DATADIR}/doc/linphone-${LINPHONE_VERSION}")
if(ENABLE_DOC)
install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html" "${XML_DIR}"
DESTINATION "${CMAKE_INSTALL_DATADIR}/doc/linphone-${LINPHONE_VERSION}")
endif()
else()
if (ENABLE_CXX_WRAPPER)
message(FATAL_ERROR "The dot program is needed to generate the linphone documentation. You can get it from http://www.graphviz.org/.")
......
......@@ -1045,7 +1045,7 @@ IGNORE_PREFIX =
# If the GENERATE_HTML tag is set to YES, doxygen will generate HTML output
# The default value is: YES.
GENERATE_HTML = YES
GENERATE_HTML = ${GENERATE_HTML}
# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
......@@ -1589,7 +1589,7 @@ EXTRA_SEARCH_MAPPINGS =
# If the GENERATE_LATEX tag is set to YES, doxygen will generate LaTeX output.
# The default value is: YES.
GENERATE_LATEX = YES
GENERATE_LATEX = NO
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
......@@ -1825,7 +1825,7 @@ RTF_SOURCE_CODE = NO
# classes and files.
# The default value is: NO.
GENERATE_MAN = YES
GENERATE_MAN = NO
# The MAN_OUTPUT tag is used to specify where the man pages will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
......
......@@ -21,41 +21,39 @@
############################################################################
if (ENABLE_SPHINX_DOC)
set(GENERATED_LANGUAGES c cpp csharp)
set(DOCUMENTATION_DIRS )
set(GENERATED_SPHINX_SOURCES )
foreach(LANGUAGE_ ${GENERATED_LANGUAGES})
set(DOCUMENTATION_DIR ${CMAKE_CURRENT_BINARY_DIR}/source/${LANGUAGE_})
list(APPEND DOCUMENTATION_DIRS ${DOCUMENTATION_DIR})
list(APPEND GENERATED_SPHINX_SOURCES ${DOCUMENTATION_DIR}/index.rst)
endforeach(LANGUAGE_)
set(PYTHON_SCRIPTS gendoc.py
${linphone_SOURCE_DIR}/tools/abstractapi.py
${linphone_SOURCE_DIR}/tools/genapixml.py
${linphone_SOURCE_DIR}/tools/metadoc.py
${linphone_SOURCE_DIR}/tools/metaname.py
set(doc_source_dir ${CMAKE_CURRENT_BINARY_DIR}/source)
set(doc_output_dir ${CMAKE_CURRENT_BINARY_DIR}/build)
set(reference_doc_source_dir ${doc_source_dir}/reference)
set(static_documentation_files
guides/authentication.rst
guides/buddy_list.rst
guides/call_control.rst
guides/call_logs.rst
guides/call_misc.rst
guides/chatroom.rst
guides/conferencing.rst
guides/event_api.rst
guides/initializing.rst
guides/ios_portability.rst
guides/linphone_address.rst
guides/media_parameters.rst
guides/misc.rst
guides/network_parameters.rst
guides/proxies.rst
index.rst
logo.png
samples/samples.rst
toc.rst
)
set(MUSTACHE_TEMPLATES class_page.mustache
enums_page.mustache
index_page.mustache
)
configure_file(conf.py.in source/conf.py)
configure_file(source/index.rst source/index.rst COPYONLY)
add_custom_command(OUTPUT ${GENERATED_SPHINX_SOURCES}
COMMAND ${CMAKE_COMMAND} -E remove -f ${DOCUMENTATION_DIRS}
COMMAND ${PYTHON_EXECUTABLE} '${CMAKE_CURRENT_SOURCE_DIR}/gendoc.py' '${LINPHONE_DOXYGEN_XML_DIR}' -o 'source'
DEPENDS ${PYTHON_SCRIPTS}
${MUSTACHE_TEMPLATES}
${LINPHONE_DOXYGEN_XML_DIR}/index.xml
linphone-doc
)
add_custom_command(OUTPUT build/html/index.html
COMMAND ${CMAKE_COMMAND} -E remove_directory build
COMMAND ${PYTHON_EXECUTABLE} -msphinx -M html 'source' 'build'
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/source/conf.py
${CMAKE_CURRENT_BINARY_DIR}/source/index.rst
${GENERATED_SPHINX_SOURCES}
)
add_custom_target(sphinx-doc ALL DEPENDS build/html/index.html)
configure_file(conf.py.in ${doc_source_dir}/conf.py)
foreach(file ${static_documentation_files})
configure_file(${file} ${doc_source_dir}/${file} COPYONLY)
endforeach(file)
foreach(source ${LINPHONE_C_EXAMPLES_SOURCE})
configure_file(${source} ${doc_source_dir}/samples/ COPYONLY)
endforeach(source)
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${doc_source_dir}/_static ${reference_doc_source_dir})
add_custom_target(sphinx-doc ALL ${PYTHON_EXECUTABLE} '${CMAKE_CURRENT_SOURCE_DIR}/gendoc.py' '${LINPHONE_DOXYGEN_XML_DIR}' -o '${reference_doc_source_dir}'
COMMAND ${PYTHON_EXECUTABLE} -msphinx -M html '${doc_source_dir}' '${doc_output_dir}'
DEPENDS linphone-doc)
endif()
{{#hasNamespaceDeclarator}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{namespace}}}
{{#isJava}}
:noindex:
{{/isJava}}
{{/hasNamespaceDeclarator}}
{{#make_chapter}}{{{className}}} class{{/make_chapter}}
.. {{#write_declarator}}class{{/write_declarator}}:: {{{fullClassName}}}
.. {{#write_declarator}}class{{/write_declarator}}:: {{{classDeclaration}}}
{{#briefDoc}}
{{#lines}}
......@@ -17,9 +24,24 @@
{{{selector}}}
{{#hasNamespaceDeclarator}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{fullClassName}}}
{{#isJava}}
:noindex:
{{/isJava}}
{{/hasNamespaceDeclarator}}
Summary
=======
{{#hasEnums}}
Enums
-----
{{{enumsSummary}}}
{{/hasEnums}}
{{#hasProperties}}
Properties
----------
......@@ -41,18 +63,61 @@ Class methods
{{{classMethodsSummary}}}
{{/hasClassMethods}}
Detailed descriptions
=====================
{{#hasEnums}}
Enums
-----
{{#enums}}
{{#make_subsection}}{{{name}}}{{/make_subsection}}
.. {{#write_declarator}}enum{{/write_declarator}}:: {{{declaration}}}
{{#briefDesc}}
{{#lines}}
{{{line}}}
{{/lines}}
{{/briefDesc}}
{{{selector}}}
{{#enumerators}}
{{#isNotJava}}
.. {{#write_declarator}}enumerator{{/write_declarator}}:: {{{name}}}
{{/isNotJava}}
{{#isJava}}
**{{{name}}}**
{{/isJava}}
{{#briefDesc}}
{{#lines}}
{{{line}}}
{{/lines}}
{{/briefDesc}}
{{{selector}}}
{{/enumerators}}
{{/enums}}
{{/hasEnums}}
{{#hasProperties}}
Properties
----------
{{#properties}}
.. _{{{ref_label}}}:
{{{title}}}
{{#hasNamespaceDeclarator}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{fullClassName}}}
{{#isJava}}
:noindex:
{{/isJava}}
{{/hasNamespaceDeclarator}}
{{#getter}}
......@@ -100,6 +165,9 @@ Public methods
{{#hasNamespaceDeclarator}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{fullClassName}}}
{{#isJava}}
:noindex:
{{/isJava}}
{{/hasNamespaceDeclarator}}
{{#methods}}
......@@ -128,6 +196,9 @@ Class methods
{{#hasNamespaceDeclarator}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{fullClassName}}}
{{#isJava}}
:noindex:
{{/isJava}}
{{/hasNamespaceDeclarator}}
{{#classMethods}}
......
......@@ -31,7 +31,7 @@
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = ['sphinx_csharp.csharp']
extensions = ['sphinx_csharp.csharp', 'javasphinx']
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
......@@ -83,20 +83,33 @@ todo_include_todos = False
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
#html_theme = 'alabaster'
html_theme = 'classic'
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#
# html_theme_options = {}
html_theme_options = {
'sidebarwidth': '360',
'body_max_width': '100%',
'collapsiblesidebar': 'true'
}
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
# Path to the picture to use as logo.
html_logo = 'logo.png'
# Enable html5
html_experimental_html5_writer = True
# Side bar customization
#html_sidebars = {
# 'reference/*/*' : ['searchbox.html', 'globaltoc.html']
#}
# -- Options for HTMLHelp output ------------------------------------------
......
{{#enums}}
{{{sectionName}}}
{{#namespace}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{namespace}}}
{{#isJava}}
:noindex:
{{/isJava}}
{{/namespace}}
.. {{#write_declarator}}enum{{/write_declarator}}:: {{{fullName}}}
{{#enum}}
{{#make_chapter}}{{{name}}} enum{{/make_chapter}}
.. {{#write_declarator}}enum{{/write_declarator}}:: {{{declaration}}}
{{#briefDesc}}
{{#lines}}
......@@ -11,13 +18,14 @@
{{{selector}}}
{{#hasNamespaceDeclarator}}
.. {{#write_declarator}}namespace{{/write_declarator}}:: {{{namespace}}}
{{/hasNamespaceDeclarator}}
{{#enumerators}}
.. {{#write_declarator}}enumerator{{/write_declarator}}:: {{{name}}}{{#value}} = {{{value}}}{{/value}}
{{#isNotJava}}
.. {{#write_declarator}}enumerator{{/write_declarator}}:: {{{name}}}
{{/isNotJava}}
{{#isJava}}
**{{{name}}}**
{{/isJava}}
{{#briefDesc}}
{{#lines}}
{{{line}}}
......@@ -27,4 +35,5 @@
{{{selector}}}
{{/enumerators}}
{{/enums}}
{{/enum}}
This diff is collapsed.
Managing authentication: userid and passwords
=============================================
Managing Buddies and buddy list and presence
============================================
Buddies and buddy list
----------------------
Each buddy is represented by a :cpp:type:`LinphoneFriend` object created by function :cpp:func:`linphone_friend_new`.
Buddy configuration parameters like :cpp:func:`sip uri <linphone_friend_set_addr>` or :cpp:func:`status publication <linphone_friend_set_inc_subscribe_policy>` policy for
this :cpp:type:`friend <LinphoneFriend>` are configurable for each buddy.
Here under a typical buddy creation:
.. code-block:: c
LinphoneFriend* my_friend=linphone_friend_new_with_addr("sip:joe@sip.linphone.org"); /*creates friend object for buddy joe*/
linphone_friend_enable_subscribes(my_friend,TRUE); /*configure this friend to emit SUBSCRIBE message after being added to LinphoneCore*/
linphone_friend_set_inc_subscribe_policy(my_friend,LinphoneSPAccept); /* accept Incoming subscription request for this friend*/
:cpp:type:`Friends <LinphoneFriend>` status changes are reported by callback LinphoneCoreVTable.notify_presence_recv
.. code-block:: c
static void notify_presence_recv_updated (struct _LinphoneCore *lc, LinphoneFriend *friend) {
const LinphoneAddress* friend_address = linphone_friend_get_address(friend);
printf("New state state [%s] for user id [%s] \n"
,linphone_online_status_to_string(linphone_friend_get_status(friend))
,linphone_address_as_string (friend_address));
}
Once created a buddy can be added to the buddy list using function :cpp:func:`linphone_core_add_friend`. Added friends will be notified
about :cpp:func:`local status changes <linphone_core_set_presence_info>`.
Any subsequente modifications to :cpp:type:`LinphoneFriend` must be first started by a call to function :cpp:func:`linphone_friend_edit` and validated by function :cpp:func:`linphone_friend_done`.
.. code-block:: c
linphone_friend_edit(my_friend); /* start editing friend */
linphone_friend_enable_subscribes(my_friend,FALSE); /*disable subscription for this friend*/
linphone_friend_done(my_friend); /*commit changes triggering an UNSUBSCRIBE message*/
Publishing presence status
--------------------------
Local presence status can be changed using function :cpp:func:`linphone_core_set_presence_model`. New status is propagated to all
friends :cpp:func:`previously added <linphone_core_add_friend>` to :cpp:type:`LinphoneCore`.
Handling incoming subscription request
--------------------------------------
New incoming subscription requests are process according to :cpp:func:`the incoming subscription policy state <linphone_friend_set_inc_subscribe_policy>` for subscription
initiated by :cpp:func:`members of the buddy list <linphone_core_add_friend>`.
For incoming request comming from an unknown buddy, the call back LinphoneCoreVTable.new_subscription_request is invoked.
A complete tutorial can be found at : \ref buddy_tutorials "Registration tutorial"
Placing and receiving calls
===========================
The :cpp:type:`LinphoneCall` object represents an incoming or outgoing call managed by the :cpp:type:`LinphoneCore`.
Outgoing calls can be created using :cpp:func:`linphone_core_invite` or :cpp:func:`linphone_core_invite_address`, while incoming calls are notified to the application
through the LinphoneCoreVTable::call_state_changed callback.
.. seealso:: :ref:`"Basic Call" <basic_call_code_sample>` source code.
Managing call logs
==================
Obtaining information about a running call: sound volumes, quality indicators
=============================================================================
When a call is running, it is possible to retrieve in real time current measured volumes and quality indicator.
Chat room and messaging
=======================
Exchanging text messages
------------------------
Messages are sent using :cpp:type:`LinphoneChatRoom` object. First step is to create a :cpp:func:`chat room <linphone_core_get_chat_room>`
from a peer sip uri.
.. code-block:: c
LinphoneChatRoom* chat_room = linphone_core_get_chat_room(lc,"sip:joe@sip.linphone.org");
Once created, messages are sent using function :cpp:func:`linphone_chat_room_send_message`.
.. code-block:: c
linphone_chat_room_send_message(chat_room,"Hello world"); /*sending message*/
Incoming message are received from call back LinphoneCoreVTable.text_received
.. code-block:: c
void text_received(LinphoneCore *lc, LinphoneChatRoom *room, const LinphoneAddress *from, const char *message) {
printf(" Message [%s] received from [%s] \n",message,linphone_address_as_string (from));
}
.. seealso:: A complete tutorial can be found at :ref:`"Chatroom and messaging" <chatroom_code_sample>` source code.
Making an audio conference
==========================
This API allows to create a conference entirely managed by the client. No server capabilities are required.
The way such conference is created is by doing the following:
#. The application shall makes "normal" calls to several destinations (using :cpp:func:`linphone_core_invite`), one after another.
#. While initiating the second call, the first one is automatically paused.
#. Then, once the second call is established, the application has the possibility to merge the two calls to form a conference where each participant
(the local participant, the remote destination of the first call, the remote destination of the second call) can talk together.
This must be done by adding the two calls to the conference using :cpp:func:`linphone_core_add_to_conference`.
Once merged into a conference the :cpp:type:`LinphoneCall` objects representing the calls that were established remain unchanged, except that
they are tagged as part of the conference (see :cpp:func:`linphone_call_is_in_conference`). The calls in a conference are in the :cpp:enumerator:`LinphoneCallStreamsRunning` state.
Only a single conference can be created: the purpose of this feature is to allow the local user to create, take part and manage the conference.
This API is not designed to create a conference server application.
Up to 10 calls can be merged into the conference, however depending on the CPU usage required for doing the encoding/decoding of the streams of each participants,
the effective limit can be lower.
Managing generic subscriptions and publishes
============================================
The :cpp:type:`LinphoneEvent` api allows application to control subscriptions, receive notifications and make publish to peers, in a generic manner.
Initializing liblinphone
========================
This diff is collapsed.
SIP address parser API
======================
This api is useful for manipulating SIP addresses ('from' or 'to' headers).
Controlling media parameters
============================
Multicast
---------
Call using rtp multicast addresses are supported for both audio and video with some limitations. Limitations are, no stun, no ice, no encryption.
* Incoming call with multicast address are automatically accepted. The called party switches in a media receive only mode.
* Outgoing call willing to send media to a multicast address can activate multicast using :cpp:func:`linphone_core_enable_video_multicast`
or :cpp:func:`linphone_core_enable_audio_multicast`. The calling party switches in a media listen send only mode.
Miscenalleous: logs, version strings, config storage
====================================================
Controlling network parameters (ports, mtu…)
============================================
Managing proxies
================
User registration is controled by :cpp:type:`LinphoneProxyConfig` settings.
Each :cpp:type:`LinphoneProxyConfig` object can be configured with registration informations like :cpp:func:`proxy address <linphone_proxy_config_set_server_addr>`,
:cpp:func:`user id <linphone_proxy_config_set_identity>`, :cpp:func:`refresh period <linphone_proxy_config_expires>`, and so on.
A created proxy config using :cpp:func:`linphone_proxy_config_new`, once configured, must be added to :cpp:type:`LinphoneCore` using function :cpp:func:`linphone_core_add_proxy_config`.
It is recommended to set a default :cpp:type:`proxy config <LinphoneProxyConfig>` using function :cpp:func:`linphone_core_set_default_proxy`. Once done,
if :cpp:type:`proxy config <LinphoneProxyConfig>` has been configured with attribute :cpp:func:`enable register <linphone_proxy_config_enable_register>`,
next call to :cpp:func:`linphone_core_iterate` triggers SIP register.
Registration status is reported by LinphoneCoreRegistrationStateChangedCb.