Tizen Native API
6.5
|
It provides capability information of the media recorder.
Required Header
#include <recorder.h>
Overview
The Capability API allows you to retrieve the recorder capabilities mentioned below:
- Supported file formats
- Supported audio and video encoders
To get all supported file formats, call recorder_foreach_supported_file_format(). This function will internally invoke recorder_supported_file_format_cb() for each file format.
Related Features
This API is related with the following features:
- http://tizen.org/feature/media.audio_recording
- http://tizen.org/feature/media.video_recording
It is recommended to design feature related codes in your application for reliability.
You can check if a device supports the related features for this API by using System Information, thereby controlling the procedure of your application.
To ensure your application is only running on the device with specific features, please define the features in your manifest file using the manifest editor in the SDK.
More details on featuring your application can be found from Feature Element.
Functions | |
int | recorder_foreach_supported_file_format (recorder_h recorder, recorder_supported_file_format_cb callback, void *user_data) |
Retrieves all supported file formats by invoking a specific callback for each supported file format. | |
int | recorder_foreach_supported_audio_encoder (recorder_h recorder, recorder_supported_audio_encoder_cb callback, void *user_data) |
Retrieves all supported audio encoders by invoking a specific callback for each supported audio encoder. | |
int | recorder_foreach_supported_video_resolution (recorder_h recorder, recorder_supported_video_resolution_cb foreach_cb, void *user_data) |
Retrieves all supported video resolutions by invoking callback function once for each supported video resolution. | |
int | recorder_foreach_supported_video_encoder (recorder_h recorder, recorder_supported_video_encoder_cb callback, void *user_data) |
Retrieves all supported video encoders by invoking a specific callback for each supported video encoder. | |
Typedefs | |
typedef bool(* | recorder_supported_file_format_cb )(recorder_file_format_e format, void *user_data) |
Called iteratively to notify about the supported file formats. | |
typedef bool(* | recorder_supported_audio_encoder_cb )(recorder_audio_codec_e codec, void *user_data) |
Called iteratively to notify about the supported audio encoders. | |
typedef bool(* | recorder_supported_video_encoder_cb )(recorder_video_codec_e codec, void *user_data) |
Called iteratively to notify about the supported video encoders. |
Typedef Documentation
typedef bool(* recorder_supported_audio_encoder_cb)(recorder_audio_codec_e codec, void *user_data) |
Called iteratively to notify about the supported audio encoders.
- Since :
- 2.3.1
- Parameters:
-
[in] codec The codec of audio encoder [in] user_data The user data passed from the foreach function
- Returns:
true
to continue with the next iteration of the loop,
otherwisefalse
to break out of the loop
- Precondition:
- recorder_foreach_supported_audio_encoder() will invoke this callback.
typedef bool(* recorder_supported_file_format_cb)(recorder_file_format_e format, void *user_data) |
Called iteratively to notify about the supported file formats.
- Since :
- 2.3.1
- Parameters:
-
[in] format The format of recording files [in] user_data The user data passed from the foreach function
- Returns:
true
to continue with the next iteration of the loop,
otherwisefalse
to break out of the loop
- Precondition:
- recorder_foreach_supported_file_format() will invoke this callback.
typedef bool(* recorder_supported_video_encoder_cb)(recorder_video_codec_e codec, void *user_data) |
Called iteratively to notify about the supported video encoders.
- Since :
- 2.3.1
- Parameters:
-
[in] codec The codec of video encoder [in] user_data The user data passed from the foreach function
- Returns:
true
to continue with the next iteration of the loop,
otherwisefalse
to break out of the loop
- Precondition:
- recorder_foreach_supported_video_encoder() will invoke this callback.
Function Documentation
int recorder_foreach_supported_audio_encoder | ( | recorder_h | recorder, |
recorder_supported_audio_encoder_cb | callback, | ||
void * | user_data | ||
) |
Retrieves all supported audio encoders by invoking a specific callback for each supported audio encoder.
- Since :
- 2.3.1
- Parameters:
-
[in] recorder The handle to the media recorder [in] callback The iteration callback [in] user_data The user data to be passed to the callback function
- Returns:
0
on success, otherwise a negative error value
- Return values:
-
RECORDER_ERROR_NONE Successful RECORDER_ERROR_INVALID_PARAMETER Invalid parameter RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted RECORDER_ERROR_NOT_SUPPORTED The feature is not supported RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- Postcondition:
- recorder_supported_audio_encoder_cb() will be invoked.
int recorder_foreach_supported_file_format | ( | recorder_h | recorder, |
recorder_supported_file_format_cb | callback, | ||
void * | user_data | ||
) |
Retrieves all supported file formats by invoking a specific callback for each supported file format.
- Since :
- 2.3.1
- Parameters:
-
[in] recorder The handle to the media recorder [in] callback The iteration callback [in] user_data The user data to be passed to the callback function
- Returns:
0
on success, otherwise a negative error value
- Return values:
-
RECORDER_ERROR_NONE Successful RECORDER_ERROR_INVALID_PARAMETER Invalid parameter RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted RECORDER_ERROR_NOT_SUPPORTED The feature is not supported RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- Postcondition:
- recorder_supported_file_format_cb() will be invoked.
int recorder_foreach_supported_video_encoder | ( | recorder_h | recorder, |
recorder_supported_video_encoder_cb | callback, | ||
void * | user_data | ||
) |
Retrieves all supported video encoders by invoking a specific callback for each supported video encoder.
- Since :
- 2.3.1
- Parameters:
-
[in] recorder The handle to the media recorder [in] callback The iteration callback [in] user_data The user data to be passed to the callback function
- Returns:
0
on success, otherwise a negative error value
- Return values:
-
RECORDER_ERROR_NONE Successful RECORDER_ERROR_INVALID_PARAMETER Invalid parameter RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted RECORDER_ERROR_NOT_SUPPORTED The feature is not supported RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- Postcondition:
- recorder_supported_video_encoder_cb() will be invoked.
int recorder_foreach_supported_video_resolution | ( | recorder_h | recorder, |
recorder_supported_video_resolution_cb | foreach_cb, | ||
void * | user_data | ||
) |
Retrieves all supported video resolutions by invoking callback function once for each supported video resolution.
- Since :
- 2.3.1
- Parameters:
-
[in] recorder The handle to the media recorder [in] foreach_cb The callback function to be invoked [in] user_data The user data to be passed to the callback function
- Returns:
0
on success, otherwise a negative error value
- Return values:
-
RECORDER_ERROR_NONE Successful RECORDER_ERROR_INVALID_PARAMETER Invalid parameter RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted RECORDER_ERROR_NOT_SUPPORTED The feature is not supported RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- Postcondition:
- This function invokes recorder_supported_video_resolution_cb() repeatedly to retrieve each supported video resolution.