event.width = evt.u.size.w;
/* emit */ m_event(event);
}
+ else if (evt.type == VIDEO_EVENT_FRAME_RATE_CHANGED)
+ {
+ struct iTSMPEGDecoder::videoEvent event;
+ event.type = iTSMPEGDecoder::videoEvent::eventFrameRateChanged;
+ event.framerate = evt.u.frame_rate;
+ /* emit */ m_event(event);
+ }
+ else if (evt.type == 16 /*VIDEO_EVENT_PROGRESSIVE_CHANGED*/)
+ {
+ struct iTSMPEGDecoder::videoEvent event;
+ event.type = iTSMPEGDecoder::videoEvent::eventProgressiveChanged;
+ event.progressive = evt.u.frame_rate;
+ /* emit */ m_event(event);
+ }
else
eDebug("unhandled DVBAPI Video Event %d", evt.type);
}
{
eDebug("showSinglePic %s", filename);
int f = open(filename, O_RDONLY);
- if (f)
+ if (f >= 0)
{
struct stat s;
fstat(f, &s);
++pos;
if ((iframe[3] >> 4) != 0xE) // no pes header
write(m_video_clip_fd, pes_header, sizeof(pes_header));
+ else
+ iframe[4] = iframe[5] = 0x00;
write(m_video_clip_fd, iframe, s.st_size);
if (!seq_end_avail)
write(m_video_clip_fd, seq_end, sizeof(seq_end));