| 334 | } |
| 335 | |
| 336 | static int dv_extract_timecode(DVDemuxContext* c, const uint8_t* frame, char *tc) |
| 337 | { |
| 338 | const uint8_t *tc_pack; |
| 339 | |
| 340 | // For PAL systems, drop frame bit is replaced by an arbitrary |
| 341 | // bit so its value should not be considered. Drop frame timecode |
| 342 | // is only relevant for NTSC systems. |
| 343 | int prevent_df = c->sys->ltc_divisor == 25 || c->sys->ltc_divisor == 50; |
| 344 | |
| 345 | tc_pack = dv_extract_pack(frame, DV_TIMECODE); |
| 346 | if (!tc_pack) |
| 347 | return 0; |
| 348 | av_timecode_make_smpte_tc_string2(tc, av_inv_q(c->sys->time_base), AV_RB32(tc_pack + 1), prevent_df, 1); |
| 349 | return 1; |
| 350 | } |
| 351 | |
| 352 | /* The following 3 functions constitute our interface to the world */ |
| 353 |
no test coverage detected