Lines Matching defs:frame
85 static const uint8_t *dv_extract_pack(const uint8_t *frame, enum dv_pack_type t)
110 if (frame[offs] == t)
114 return frame[offs] == t ? &frame[offs] : NULL;
129 static int dv_extract_audio(const uint8_t *frame, uint8_t **ppcm,
137 as_pack = dv_extract_pack(frame, dv_audio_source);
141 smpls = as_pack[1] & 0x3f; /* samples in this frame - min. samples */
156 ipcm = (sys->height == 720 && !(frame[1] & 0x0C)) ? 2 : 0;
172 frame += 6 * 80; /* skip DIF segment header */
192 pcm[of * 2] = frame[d + 1];
193 pcm[of * 2 + 1] = frame[d];
198 lc = ((uint16_t)frame[d] << 4) |
199 ((uint16_t)frame[d + 2] >> 4);
200 rc = ((uint16_t)frame[d + 1] << 4) |
201 ((uint16_t)frame[d + 2] & 0x0f);
224 frame += 16 * 80; /* 15 Video DIFs + 1 Audio DIF */
232 static int dv_extract_audio_info(DVDemuxContext *c, const uint8_t *frame)
237 as_pack = dv_extract_pack(frame, dv_audio_source);
243 smpls = as_pack[1] & 0x3f; /* samples in this frame - min. samples */
293 static int dv_extract_video_info(DVDemuxContext *c, const uint8_t *frame)
306 vsc_pack = dv_extract_pack(frame, dv_video_control);
307 apt = frame[4] & 0x07;
317 static int dv_extract_timecode(DVDemuxContext* c, const uint8_t* frame, char *tc)
321 // For PAL systems, drop frame bit is replaced by an arbitrary
322 // bit so its value should not be considered. Drop frame timecode
326 tc_pack = dv_extract_pack(frame, dv_timecode);
402 return -1; /* Broken frame, or not enough data */
613 // should appear around every 12000 bytes, at least 10 per frame