Lines Matching defs:buf

238 makegammatable (double gamma, int highlight, unsigned char *buf)
245 buf[0] = 0x04;
246 buf[1] = 0x70;
247 buf[2] = 0x00;
248 buf[3] = 0x01;
253 buf[in + 4] = (unsigned char) out;
259 buf[in + 4] = maxout;
270 unsigned char buf[260];
272 makegammatable (chndl->table_gamma, chndl->highlight_other, buf);
273 cp2155_write_gamma_block (fd, 0x000, buf);
274 cp2155_write_gamma_block (fd, 0x100, buf);
275 cp2155_write_gamma_block (fd, 0x200, buf);
282 unsigned char buf[260];
284 makegammatable (chndl->table_gamma, chndl->highlight_red_enhanced, buf);
285 cp2155_write_gamma_block (fd, 0x000, buf);
286 makegammatable (chndl->table_gamma, chndl->highlight_other, buf);
287 cp2155_write_gamma_block (fd, 0x100, buf);
289 buf);
290 cp2155_write_gamma_block (fd, 0x200, buf);
295 unsigned char *buf)
302 top_value = buf[start_descent - 2] + 256 * buf[start_descent - 1];
303 DBG (1, "buf[start_descent-2] = %02x buf[start_descent-1] = %02x\n",
304 buf[start_descent - 2], buf[start_descent - 1]);
305 count = buf[2] + 256 * buf[3];
315 buf[position] = value_lo;
316 buf[position + 1] = value_hi;
318 "position = %03lx buf[position]= %02x buf[position+1] = %02x\n",
319 position, buf[position], buf[position + 1]);
326 unsigned char *buf)
333 buf[0] = 0x04;
334 buf[1] = 0x70;
335 buf[2] = (count - 4) & 0xff;
336 buf[3] = ((count - 4) >> 8) & 0xff;
339 buf[i] = hilo;
341 buf[i] = hihi;
343 buf[i] = lolo;
345 buf[i] = lohi;
352 double coefficient, unsigned char *buf)
357 buf[0] = 0x04;
358 buf[1] = 0x70;
359 buf[2] = (count - 4) & 0xff;
360 buf[3] = ((count - 4) >> 8) & 0xff;
363 buf[i] = lo;
365 buf[i] = hi;
368 make_descending_slope (start_descent, coefficient, buf);
372 write_buf (int fd, size_t count, unsigned char *buf,
390 sanei_usb_write_bulk (fd, buf, &count);
394 big_write (int fd, size_t count, unsigned char *buf)
396 make_constant_buf (count, 62756, 20918, buf);
397 write_buf (fd, count, buf, 0x00, 0x00);
398 write_buf (fd, count, buf, 0x00, 0xb0);
399 write_buf (fd, count, buf, 0x01, 0x60);
400 write_buf (fd, count, buf, 0x02, 0x10);
404 big_write_2224 (int fd, size_t count, unsigned char *buf)
406 make_constant_buf (count, 62756, 30918, buf);
407 write_buf (fd, count, buf, 0x00, 0x00);
408 write_buf (fd, count, buf, 0x00, 0xb0);
409 write_buf (fd, count, buf, 0x01, 0x60);
410 write_buf (fd, count, buf, 0x02, 0x10);
414 big_write_film (int fd, size_t count, unsigned char *buf)
416 make_constant_buf (count, 62756, 20918, buf);
417 write_buf (fd, count, buf, 0x00, 0x00);
418 write_buf (fd, count, buf, 0x02, 0x00);
419 write_buf (fd, count, buf, 0x04, 0x00);
420 write_buf (fd, count, buf, 0x06, 0x00);
464 register_table (int fd, unsigned char register_value, unsigned char *buf)
487 cp2155_set (fd, 0x23 + buffer_index, buf[buffer_index]);
488 cp2155_set (fd, 0x33 + buffer_index, buf[buffer_index]);
492 cp2155_set (fd, 0x23 + buffer_index, buf[buffer_index]);
493 cp2155_set (fd, 0x33 + buffer_index, buf[buffer_index]);
494 cp2155_set (fd, 0x43 - buffer_index, buf[buffer_index]);
495 cp2155_set (fd, 0x33 - buffer_index, buf[buffer_index]);
507 register_table_4800 (int fd, unsigned char register_value, unsigned char *buf)
530 cp2155_set (fd, 0x23 + buffer_index, buf[buffer_index]);
531 cp2155_set (fd, 0x33 + buffer_index, buf[buffer_index]);
535 cp2155_set (fd, 0x23 + buffer_index, buf[buffer_index]);
536 cp2155_set (fd, 0x33 + buffer_index, buf[buffer_index]);
537 cp2155_set (fd, 0x43 - buffer_index, buf[buffer_index]);
538 cp2155_set (fd, 0x33 - buffer_index, buf[buffer_index]);
550 startblob_2225_0075 (CANON_Handle * chndl, unsigned char *buf)
618 big_write (fd, 0x5174, buf);
644 memcpy (buf, "\x28\x27\x25\x21\x1c\x16\x0f\x08\x00", 9);
645 register_table (fd, 0, buf);
649 make_slope_table (count, top_value, 0x6a, 0.021739, buf);
651 write_buf (fd, count, buf, 0x03, 0x00);
652 write_buf (fd, count, buf, 0x03, 0x02);
653 write_buf (fd, count, buf, 0x03, 0x06);
656 make_slope_table (count, top_value, 0x06, 0.15217, buf);
658 write_buf (fd, count, buf, 0x03, 0x04);
659 write_buf (fd, count, buf, 0x03, 0x08);
665 startblob_2225_0150 (CANON_Handle * chndl, unsigned char *buf)
732 big_write (fd, 0x5174, buf);
758 memcpy (buf, "\x28\x27\x25\x21\x1c\x16\x0f\x08\x00", 9);
759 register_table (fd, 0, buf);
763 make_slope_table (count, top_value, 0x06, 0.0089185, buf);
765 write_buf (fd, count, buf, 0x03, 0x00);
766 write_buf (fd, count, buf, 0x03, 0x02);
767 write_buf (fd, count, buf, 0x03, 0x06);
770 make_slope_table (count, top_value, 0x06, 0.102968, buf);
772 write_buf (fd, count, buf, 0x03, 0x04);
773 write_buf (fd, count, buf, 0x03, 0x08);
779 startblob_2225_0300 (CANON_Handle * chndl, unsigned char *buf)
846 big_write (fd, 0x5174, buf);
872 register_table (fd, 0x14, buf);
876 make_slope_table (count, top_value, 0x06, 0.0038363, buf);
878 write_buf (fd, count, buf, 0x03, 0x00);
879 write_buf (fd, count, buf, 0x03, 0x02);
880 write_buf (fd, count, buf, 0x03, 0x06);
883 make_slope_table (count, top_value, 0x06, 0.0080213, buf);
885 write_buf (fd, count, buf, 0x03, 0x04);
886 write_buf (fd, count, buf, 0x03, 0x08);
892 startblob_2225_0600 (CANON_Handle * chndl, unsigned char *buf)
982 register_table (fd, 0x14, buf);
986 make_slope_table (count, top_value, 0x06, 0.0020408, buf);
988 write_buf (fd, count, buf, 0x03, 0x00);
989 write_buf (fd, count, buf, 0x03, 0x02);
990 write_buf (fd, count, buf, 0x03, 0x06);
993 make_slope_table (count, top_value, 0x06, 0.0064935, buf);
995 write_buf (fd, count, buf, 0x03, 0x04);
996 write_buf (fd, count, buf, 0x03, 0x08);
1002 startblob_2225_1200 (CANON_Handle * chndl, unsigned char *buf)
1068 big_write (fd, 0xa1a4, buf);
1094 memcpy (buf, "\x14\x14\x12\x11\x0e\x0b\x08\x04\x00", 9);
1095 register_table (fd, 0, buf);
1099 make_slope_table (count, top_value, 0x06, 0.0, buf);
1101 write_buf (fd, count, buf, 0x03, 0x00);
1102 write_buf (fd, count, buf, 0x03, 0x02);
1103 write_buf (fd, count, buf, 0x03, 0x06);
1104 write_buf (fd, count, buf, 0x03, 0x04);
1105 write_buf (fd, count, buf, 0x03, 0x08);
1111 startblob_2224_0075 (CANON_Handle * chndl, unsigned char *buf)
1181 big_write (fd, 0x5694, buf);
1207 register_table (fd, 0x0f, buf);
1211 make_slope_table (count, top_value, 0x6a, 0.0084116, buf);
1213 write_buf (fd, count, buf, 0x03, 0x00);
1214 write_buf (fd, count, buf, 0x03, 0x02);
1215 write_buf (fd, count, buf, 0x03, 0x06);
1218 make_slope_table (count, top_value, 0x06, 0.15217, buf);
1220 write_buf (fd, count, buf, 0x03, 0x04);
1221 write_buf (fd, count, buf, 0x03, 0x08);
1228 startblob_2224_0150 (CANON_Handle * chndl, unsigned char *buf)
1298 big_write (fd, 0x5694, buf);
1324 register_table (fd, 0x0d, buf);
1328 make_slope_table (count, top_value, 0x86, 0.017979, buf);
1330 write_buf (fd, count, buf, 0x03, 0x00);
1331 write_buf (fd, count, buf, 0x03, 0x02);
1332 write_buf (fd, count, buf, 0x03, 0x06);
1335 make_slope_table (count, top_value, 0x06, 0.102968, buf);
1337 write_buf (fd, count, buf, 0x03, 0x04);
1338 write_buf (fd, count, buf, 0x03, 0x08);
1345 startblob_2224_0300 (CANON_Handle * chndl, unsigned char *buf)
1437 register_table (fd, 0x0a, buf);
1441 make_slope_table (count, top_value, 0x66, 0.0129596, buf);
1443 write_buf (fd, count, buf, 0x03, 0x00);
1444 write_buf (fd, count, buf, 0x03, 0x02);
1445 write_buf (fd, count, buf, 0x03, 0x06);
1448 make_slope_table (count, top_value, 0x06, 0.09307359, buf);
1450 write_buf (fd, count, buf, 0x03, 0x04);
1451 write_buf (fd, count, buf, 0x03, 0x08);
1458 startblob_2224_0600 (CANON_Handle * chndl, unsigned char *buf)
1528 big_write_2224 (fd, 0x5694, buf);
1554 register_table (fd, 0x0c, buf);
1558 make_slope_table (count, top_value, 0x06, 0.0, buf);
1560 write_buf (fd, count, buf, 0x03, 0x00);
1561 write_buf (fd, count, buf, 0x03, 0x02);
1562 write_buf (fd, count, buf, 0x03, 0x06);
1563 write_buf (fd, count, buf, 0x03, 0x04);
1564 write_buf (fd, count, buf, 0x03, 0x08);
1571 startblob_2224_1200 (CANON_Handle * chndl, unsigned char *buf)
1654 big_write (fd, 0xa1a4, buf);
1655 /* big_write_film (fd, 0xf004, buf); */
1681 memcpy (buf, "\x01\x03\x05\x07\x09\x0a\x0b\x0c\x0c", 9);
1682 register_table (fd, 0, buf);
1686 make_slope_table (count, top_value, 0x06, 0.0, buf);
1688 write_buf (fd, count, buf, 0x03, 0x00);
1689 write_buf (fd, count, buf, 0x03, 0x02);
1690 write_buf (fd, count, buf, 0x03, 0x06);
1693 make_slope_table (count, top_value, 0x06, 0.0, buf);
1695 write_buf (fd, count, buf, 0x03, 0x04);
1696 write_buf (fd, count, buf, 0x03, 0x08);
1703 startblob_2224_2400 (CANON_Handle * chndl, unsigned char *buf)
1792 big_write (fd, 0xa1a4, buf);
1793 big_write_film (fd, 0xf004, buf);
1819 memcpy (buf, "\x02\x04\x04\x06\x06\x08\x08\x0a\x0a", 9);
1820 register_table (fd, 0, buf);
1824 make_slope_table (count, top_value, 0x06, 0.0, buf);
1826 write_buf (fd, count, buf, 0x03, 0x00);
1827 write_buf (fd, count, buf, 0x03, 0x02);
1828 write_buf (fd, count, buf, 0x03, 0x06);
1831 make_slope_table (count, top_value, 0x06, 0.0, buf);
1833 write_buf (fd, count, buf, 0x03, 0x04);
1834 write_buf (fd, count, buf, 0x03, 0x08);
1841 startblob_2224_4800 (CANON_Handle * chndl, unsigned char *buf)
1930 big_write (fd, 0xa1a4, buf);
1931 big_write_film (fd, 0xf004, buf);
1957 memcpy (buf, "\x02\x04\x04\x06\x06\x08\x08\x0a\x0a", 9);
1958 register_table (fd, 0, buf);
1962 make_slope_table (count, top_value, 0x06, 0.0, buf);
1964 write_buf (fd, count, buf, 0x03, 0x00);
1965 write_buf (fd, count, buf, 0x03, 0x02);
1966 write_buf (fd, count, buf, 0x03, 0x06);
1969 make_slope_table (count, top_value, 0x06, 0.0, buf);
1971 write_buf (fd, count, buf, 0x03, 0x04);
1972 write_buf (fd, count, buf, 0x03, 0x08);
1979 startblob_2224_4799 (CANON_Handle * chndl, unsigned char *buf)
2069 big_write (fd, 0xa1a4, buf);
2070 big_write_film (fd, 0xf004, buf);
2096 register_table_4800 (fd, 0x05, buf);
2100 make_slope_table (count, top_value, 0x06, 0.0, buf);
2102 write_buf (fd, count, buf, 0x03, 0x00);
2103 write_buf (fd, count, buf, 0x03, 0x02);
2104 write_buf (fd, count, buf, 0x03, 0x06);
2107 make_slope_table (count, top_value, 0x06, 0.0, buf);
2109 write_buf (fd, count, buf, 0x03, 0x04);
2110 write_buf (fd, count, buf, 0x03, 0x08);
2119 unsigned char buf[0xfff0];
2186 startblob_2225_0075 (chndl, buf);
2190 startblob_2224_0075 (chndl, buf);
2196 startblob_2225_0150 (chndl, buf);
2200 startblob_2224_0150 (chndl, buf);
2206 startblob_2225_0300 (chndl, buf);
2211 startblob_2224_0300 (chndl, buf);
2218 startblob_2225_0600 (chndl, buf);
2220 startblob_2225_0600_extra (chndl, buf);
2225 startblob_2224_0600 (chndl, buf);
2231 startblob_2225_1200 (chndl, buf);
2235 startblob_2224_1200 (chndl, buf);
2241 startblob_2225_1200 (chndl, buf);
2245 startblob_2224_2400 (chndl, buf);
2251 startblob_2225_1200 (chndl, buf);
2255 startblob_2224_4800 (chndl, buf);
2471 back2225 (int fd, unsigned char *buf)
2557 memcpy (buf, "\x28\x27\x25\x21\x1c\x16\x0f\x08\x00", 9);
2558 register_table (fd, 0, buf);
2562 make_slope_table (count, top_value, 0x6a, 0.021739, buf);
2564 write_buf (fd, count, buf, 0x03, 0x00);
2565 write_buf (fd, count, buf, 0x03, 0x02);
2566 write_buf (fd, count, buf, 0x03, 0x06);
2569 make_slope_table (count, top_value, 0x06, 0.15217, buf);
2571 write_buf (fd, count, buf, 0x03, 0x04);
2572 write_buf (fd, count, buf, 0x03, 0x08);
2583 back2224 (int fd, unsigned char *buf)
2673 register_table (fd, 0x0d, buf);
2677 make_slope_table (count, top_value, 0x06, 0.0067225, buf);
2679 write_buf (fd, count, buf, 0x03, 0x00);
2680 write_buf (fd, count, buf, 0x03, 0x02);
2681 write_buf (fd, count, buf, 0x03, 0x06);
2684 make_slope_table (count, top_value, 0x06, 0.15217, buf);
2686 write_buf (fd, count, buf, 0x03, 0x04);
2687 write_buf (fd, count, buf, 0x03, 0x08);
2700 unsigned char buf[0x400];
2712 back2225 (fd, buf);
2716 back2224 (fd, buf);