video_capturer.h

This file includes the type definition for a video capturer along with several function declarations useful when working with it.

Data structures: otc_video_capturer_settings, otc_video_capturer_callbacks

Includes: config.h, video_frame.h

typedef otc_video_capturer

Video capturer type definition.

typedef struct otc_video_capturer otc_video_capturer;

enum otc_video_capturer_content_hint_type

Defines values for the content_hint parameter of the otc_video_capturer_set_content_hint function.

Name Value Description
OTC_VIDEO_CAPTURER_CONTENT_HINT_TYPE_NONE 0 No hint provided. Default value "none" will be used.
OTC_VIDEO_CAPTURER_CONTENT_HINT_TYPE_MOTION 1 value = "motion"
OTC_VIDEO_CAPTURER_CONTENT_HINT_TYPE_DETAIL 2 value = "detail".
OTC_VIDEO_CAPTURER_CONTENT_HINT_TYPE_TEXT 3 value = "text".

Functions

Name Description
otc_video_capturer_provide_frame(capturer, rotation, frame) → {otc_status} Provides a video frame to the video capturer.
otc_video_capturer_set_content_hint(capturer, content_hint) → {otc_status const} Sets the video content hint to one of the enum values in otc_video_capturer_content_hint_type.
otc_video_capturer_get_content_hint(capturer) → {enum otc_video_capturer_content_hint_type const} Returns the content_hint value for the capturer video source.

otc_video_capturer_provide_frame(capturer, rotation, frame) → {otc_status}

Provides a video frame to the video capturer.

Parameters:
Name Type Description
capturer const otc_video_capturer * A pointer to the video capturer instance.
rotation int The rotation of the video frame.
frame const otc_video_frame * A pointer to the video frame instance to be provided.

See: : - otc_video_frame

Returns:

Return value indicating either error or success.

otc_video_capturer_set_content_hint(capturer, content_hint) → {otc_status const}

Sets the video content hint to one of the enum values in otc_video_capturer_content_hint_type. If the API receives any value other than the enum values specified above, then we log a warning about the same.

Parameters:
Name Type Description
capturer const otc_video_capturer * The pointer to the capturer
content_hint enum otc_video_capturer_content_hint_type Enum value of type otc_video_capturer_content_hint_type.
Returns:

Return value indicating either failure or success.

otc_video_capturer_get_content_hint(capturer) → {enum otc_video_capturer_content_hint_type const}

Returns the content_hint value for the capturer video source.

Parameters:
Name Type Description
capturer const otc_video_capturer * The pointer to the capturer.
Returns:

Enum value of type otc_video_capturer_content_hint_type