33 { 0, 0, 0, 0, 0, 0, 0, 0 },
34 { 2, 0, 0, 0, 0, 0, 0, 0 },
35 { 5, 7, 0, 0, 0, 0, 0, 0 },
36 { 5, 0, 0, 0, 0, 0, 0, 0 },
37 { 6, 0, 0, 0, 0, 0, 0, 0 },
38 { 5, 7, 5, 7, 0, 0, 0, 0 },
39 { 5, 7, 5, 0, 0, 0, 0, 0 },
40 { 5, 7, 6, 0, 0, 0, 0, 0 },
41 { 5, 5, 0, 0, 0, 0, 0, 0 },
42 { 3, 0, 0, 0, 0, 0, 0, 0 },
43 { 6, 6, 0, 0, 0, 0, 0, 0 },
44 { 2, 4, 0, 0, 0, 0, 0, 0 },
45 { 2, 4, 5, 7, 0, 0, 0, 0 },
46 { 2, 4, 5, 0, 0, 0, 0, 0 },
47 { 2, 4, 6, 0, 0, 0, 0, 0 },
48 { 2, 4, 5, 7, 5, 7, 0, 0 },
73 for (i = 0; i < 4; i++)
89 "width %d and height %d must be multiplie of 4.\n",
102 for (i = 0; i < 4; i++) {
117 for (i = 0; i < 4; i++) {
127 for (i = 0; i < 4; i++) {
128 if (mask & (1 << 7 - i))
130 if (mask & (1 << 3 - i))
131 dst[width + i] =
color;
139 for (i = 0; i < 4; i++) {
140 if (mask & (1 << 7 - i))
142 if (mask & (1 << 3 - i))
143 dst[width + i] = src[width + i];
151 int val = bytestream2_get_be16(&c->
gb);
152 int page = val >> 14;
153 int x = (val & 0x7F);
154 int y = ((val >> 7) & 0x7F);
156 *p = c->
frame[page] + x * 2 + y * 2 * c->
width;
162 uint32_t opcode_size,
offset;
167 i = bytestream2_get_byte(&c->
gb);
178 val = bytestream2_get_be16(&c->
gb);
180 x = (val & 0x7F) * 2;
181 y = ((val >> 7) & 0x7F) * 2;
184 offset = (x & 0x7F) * 2;
185 j = bytestream2_get_le16(&c->
gb) +
offset;
188 if (dst + 3 * c->
width + 4 > dend)
191 if ((offset & 0x3F) == 0)
194 }
while (offset < j);
202 if ((src + 3 * c->
width + 4 > send) ||
203 (dst + 3 * c->
width + 4 > dend))
210 }
while (i < c->video_size / 16);
212 opcode_size = bytestream2_get_le16(&c->
gb);
223 for (i = 0; i < c->
height; i += 4, dst += c->
width * 3)
224 for (j = 0; j < c->
width; j += 4, dst += 4) {
226 if (op > opcode_size)
229 opcode = opcodes[
op] & 15;
232 opcode = opcodes[
op] >> 4;
236 offset = c->
width * 2;
243 color = bytestream2_get_byte(&c->
gb);
245 mask = bytestream2_get_byte(&c->
gb);
253 if (src + offset + c->
width + 4 > send)
255 mask = bytestream2_get_byte(&c->
gb);
277 code = bytestream2_get_byte(&c->
gb);
279 for (i = 0; i < 4; i++)
295 index = bytestream2_get_byte(&c->
gb);
296 count = bytestream2_get_byte(&c->
gb) + 1;
298 if (index +
count > 256)
304 for (i = 0; i <
count; i++) {
307 r = bytestream2_get_byteu(&c->
gb);
309 g = bytestream2_get_byteu(&c->
gb);
311 b = bytestream2_get_byteu(&c->
gb);
313 *out++ = (0xFF
U << 24) | (r << 16) | (g << 8) | b;
318 switch (code & 0x0F) {
339 frame = bytestream2_get_byte(&c->
gb);
359 code = bytestream2_get_byteu(&c->
gb);
360 count =
FFABS(code) + 1;
362 if (dst + count > end)
365 memset(dst, bytestream2_get_byteu(&c->
gb), count);
406 int16_t *output_samples;
408 int frames,
ret, i, j;
419 output_samples = (int16_t *)frame->
data[0];
421 for (j = 0; j < frames; j++) {
422 for (i = 0; i < 256; i++)
427 *output_samples++ = cb[*src++];
434 #if CONFIG_PAF_VIDEO_DECODER
435 AVCodec ff_paf_video_decoder = {
448 #if CONFIG_PAF_AUDIO_DECODER
449 AVCodec ff_paf_audio_decoder = {