29 #define SRT_STACK_SIZE 64
46 __attribute__ ((__format__ (__printf__, 2, 3)))
82 srt_print(s,
"</%c%s>", tag, tag ==
'f' ?
"ont" :
"");
112 (c & 0xFF0000) >> 16 | c & 0xFF00 | (c & 0xFF) << 16);
168 if (color != 0xFFFFFFFF)
169 srt_print(priv,
"<font color=\"#%06x\">",
170 (color & 0xFF0000) >> 16 | color & 0xFF00 | (color & 0xFF) << 16);
177 srt_print(priv,
"<font face=\"%s\">", name);
184 srt_print(priv,
"<font size=\"%d\">", size);
202 static void srt_move_cb(
void *priv,
int x1,
int y1,
int x2,
int y2,
210 " X1:%03u X2:%03u Y1:%03u Y2:%03u", x1, x2, y1, y2);
211 if (s->
end - s->
ptr > len) {
242 unsigned char *buf,
int bufsize,
const AVSubtitle *sub)
259 for (; dialog && num--; dialog++) {
261 int sh, sm, ss, sc = 10 * dialog->
start;
262 int eh, em, es, ec = 10 * dialog->
end;
263 sh = sc/3600000; sc -= 3600000*sh;
264 sm = sc/ 60000; sc -= 60000*sm;
265 ss = sc/ 1000; sc -= 1000*ss;
266 eh = ec/3600000; ec -= 3600000*eh;
267 em = ec/ 60000; ec -= 60000*em;
268 es = ec/ 1000; ec -= 1000*es;
269 srt_print(s,
"%d\r\n%02d:%02d:%02d,%03d --> %02d:%02d:%02d,%03d\r\n",
270 ++s->
count, sh, sm, ss, sc, eh, em, es, ec);
284 if (len > bufsize-1) {
299 #if CONFIG_SRT_ENCODER
313 #if CONFIG_SUBRIP_ENCODER