|
libclosedcaption 1.0.3
ISDB-Tb/SBTVD (Brazilian DTV) closed caption extraction from MPEG-TS
|
Interpreting the caption (closed caption) text and its state: colors, character size, position and display format. More...


Go to the source code of this file.
Data Structures | |
| struct | CC_Dimension_t |
| struct | CC_Color_t |
| struct | CaptionClosed_t |
| struct | CaptionClosed_t::APS |
Macros | |
| #define | CC_Dimension_is_equal(dimen1, dimen2) ((dimen1).width == (dimen2).width && (dimen1).height == (dimen2).height) |
| #define | CC_Color_is_equal(color1, color2) |
Functions | |
| bool | caption_closed_run (const CaptionManagement_t *m, CaptionClosed_t *cc) |
| uint8_t | char_latin9_to_utf8 (const char *const from, char *const to, uint8_t to_len) |
Interpreting the caption (closed caption) text and its state: colors, character size, position and display format.
caption_closed_run() walks the statement body (text + control commands) and:
Definition in file caption-closed.h.
| #define CC_Dimension_is_equal | ( | dimen1, | |
| dimen2 | |||
| ) | ((dimen1).width == (dimen2).width && (dimen1).height == (dimen2).height) |
Compares two CC_Dimension_t.
Definition at line 65 of file caption-closed.h.
| #define CC_Color_is_equal | ( | color1, | |
| color2 | |||
| ) |
Compares two CC_Color_t.
Definition at line 79 of file caption-closed.h.
| enum CC_CharacterSize_t |
Character size (SSZ, MSZ, NSZ and SZX commands).
| Enumerator | |
|---|---|
| CC_CharacterSize_Small | Small (SSZ). |
| CC_CharacterSize_Middle | Medium (MSZ). |
| CC_CharacterSize_Standard | Normal (NSZ). |
| CC_CharacterSize_t_eMax | Limit of the values above. |
| CC_CharacterSize_Custom | Size given by SZX; the value is in CaptionClosed_t::char_size_custom. |
| CC_CharacterSize_UNKNOWN | Unknown. |
Definition at line 26 of file caption-closed.h.
| enum CC_Format_t |
Display format (ARIB STD-B24, Table 9-7; CSI SWF command).
Definition at line 39 of file caption-closed.h.
| enum CC_Rcs_t |
Raster color (CSI RCS command, Raster Colour Command).
Definition at line 86 of file caption-closed.h.
| bool caption_closed_run | ( | const CaptionManagement_t * | m, |
| CaptionClosed_t * | cc | ||
| ) |
Processes the caption text.
Walks the statement body of m, handing each character (in UTF-8) to the text hook and running each control command (which updates cc and calls the controls hook). See caption-hooking.h.
Characters outside ISO-8859-15 and commands not supported in closed caption are ignored, along with their parameters.
| m | Content of type CAPTION_HANDLER_TYPE_STATEMENT_BODY, read by caption_management_load(). |
| cc | Caption state, kept between calls. |
| uint8_t char_latin9_to_utf8 | ( | const char *const | from, |
| char *const | to, | ||
| uint8_t | to_len | ||
| ) |
Converts an ISO-8859-15 (Latin-9) character to UTF-8.
| from | Source character (1 byte). |
| to | Receives the UTF-8 character, '\0' terminated. |
| to_len | Size of to; must be 4 or more. |
to, without the '\0' (1 to 3).