41 for (
int i=0; i<length; i+=16){
43 for (j=0; j < 8 && j+i<length; j++)
44 buffer += QString(
"0x%1 ").arg(buf[i+j],16,2,QChar(
'0'));
45 for (
int r=j; r<8; r++)
50 for (j=8; j < 16 && j+i<length; j++)
51 buffer += QString(
"0x%1 ").arg(buf[i+j],16,2,QChar(
'0'));
52 for (
int r=j; r<16; r++)
55 for (j=0; j < 16 && j+i<length; j++){
59 buffer += QString(QChar(buf[i+j]));
65 LOG(VB_GENERAL, LOG_INFO, buffer);
77 if (length <0)
return -1;
79 while (found < 4 && c < length){
83 if (buf[c] == 0x00) found = 1;
87 if (buf[c] == 0x00) found = 2;
92 if (buf[c] == 0x01) found = 3;
93 else if (buf[c] != 0x00) found = 0;
97 if (buf[c] == head)
return c-3;
113 if (length <0)
return -1;
115 while (found < 4 && c < length){
119 if (buf[c] == 0x00) found = 1;
123 if (buf[c] == 0x00) found = 2;
128 if (buf[c] == 0x01) found = 3;
129 else if (buf[c] != 0x00) found = 0;
145 uint64_t wts = ((uint64_t)((
pts[0] & 0x0E) << 5) |
146 ((
pts[1] & 0xFC) >> 2)) << 24;
147 wts |= (((
pts[1] & 0x03) << 6) |
148 ((
pts[2] & 0xFC) >> 2)) << 16;
149 wts |= (((
pts[2] & 0x02) << 6) |
150 ((
pts[3] & 0xFE) >> 1)) << 8;
151 wts |= (((
pts[3] & 0x01) << 7) |
152 ((
pts[4] & 0xFE) >> 1));
186 if (
mring_peek(rbuf, &b, 1, c) <0)
return -1;
190 if (b == 0x00) found = 1;
194 if (b == 0x00) found = 2;
199 if (b == 0x01) found = 3;
200 else if (b != 0x00) found = 0;
204 if (b == head)
return c-3-off;
211 if (found)
return -2;
231 if (b == 0x00) found = 1;
235 if (b == 0x00) found = 2;
240 if (b == 0x01) found = 3;
241 else if (b != 0x00) found = 0;
251 if (found)
return -2;