Lines Matching refs:line
251 - if scanner stops, clone the last line until the end of buffer
310 - don't print 0 length line in hexdump
334 - rename all DUPLEX_INTERLACE_* to indicate start and end of line
556 char line[PATH_MAX];
583 while (sanei_config_read (line, PATH_MAX, fp)) {
585 lp = line;
827 /* re-default these after reading the usb line */
834 /* re-default these after reading the scsi line */
838 DBG (5, "sane_get_devices: config line \"%s\" unrecognized - "
5008 /* figure out how many valid bytes per line (2510 is padded) */
6075 /* all requests must end on line boundary */
6248 /* all requests must end on WIDE line boundary */
6364 unsigned char * line = NULL;
6377 DBG (15, "copy_simplex: per-line copy\n");
6379 line = malloc(bwidth);
6380 if(!line) return SANE_STATUS_NO_MEM;
6382 /* ingest each line */
6403 /* one line has the following format: ggg...GGG
6404 * where the 'capital' letters are the beginning of the line */
6408 line[line_next++] = buf[i+j];
6417 line[line_next++] = buf[i+j];
6421 line[line_next++] = buf[i+j];
6425 line[line_next++] = buf[i+j];
6429 line[line_next++] = 0;
6438 line[line_next++] = buf[i+j];
6442 line[line_next++] = buf[i+j];
6446 line[line_next++] = buf[i+j];
6460 line[line_next++] = buf[i+j*3+2];
6461 line[line_next++] = buf[i+j*3+1];
6462 line[line_next++] = buf[i+j*3];
6470 line[line_next++] = buf[i+j*3+2];
6471 line[line_next++] = buf[i+j*3];
6472 line[line_next++] = buf[i+j*3+1];
6480 line[line_next++] = buf[i+j*3+1];
6481 line[line_next++] = buf[i+j*3+2];
6482 line[line_next++] = buf[i+j*3];
6486 /* one line has the following format: RRR...rrrGGG...gggBBB...bbb */
6490 line[line_next++] = buf[i+j];
6491 line[line_next++] = buf[i+pwidth+j];
6492 line[line_next++] = buf[i+2*pwidth+j];
6496 /* one line has the following format: rrr...RRRggg...GGGbbb...BBB
6497 * where the 'capital' letters are the beginning of the line */
6501 line[line_next++] = buf[i+j];
6502 line[line_next++] = buf[i+pwidth+j];
6503 line[line_next++] = buf[i+2*pwidth+j];
6512 line[line_next++] = buf[i+j];
6513 line[line_next++] = buf[i+t+j];
6514 line[line_next++] = buf[i+2*t+j];
6518 line[line_next++] = buf[i+j];
6519 line[line_next++] = buf[i+t+j];
6520 line[line_next++] = buf[i+2*t+j];
6524 line[line_next++] = buf[i+j];
6525 line[line_next++] = buf[i+t+j];
6526 line[line_next++] = buf[i+2*t+j];
6530 line[line_next++] = 0;
6539 line[line_next++] = buf[i+j];
6540 line[line_next++] = buf[i+t+j];
6541 line[line_next++] = buf[i+2*t+j];
6545 line[line_next++] = buf[i+j];
6546 line[line_next++] = buf[i+t+j];
6547 line[line_next++] = buf[i+2*t+j];
6551 line[line_next++] = buf[i+j];
6552 line[line_next++] = buf[i+t+j];
6553 line[line_next++] = buf[i+2*t+j];
6559 /* nothing sent above? just copy one line of the block */
6563 memcpy(line+line_next,buf+i,bwidth);
6570 line[j] ^= 0xff;
6578 int curr = line[j] - s->f_offset[side][j];
6580 line[j] = curr;
6587 int curr = line[j] * 240/s->f_gain[side][j];
6589 line[j] = curr;
6597 line[j] = s->lut[line[j]];
6601 /*copy the line into the buffer*/
6602 ret = copy_line(s,line,side);
6608 free(line);
6616 * assumes that the buffer aligns to a double-wide line boundary */
6674 /* line is in 6 sections, front red, back red, front green, etc. */
6689 /* full line of front, then full line of back */
6723 * Reverse memcpy designed to mirror a line of data.
6738 /* downsample a single line from scanner's size to user's size */
6747 unsigned char * line;
6768 /*setup 24 bit color single line buffer*/
6769 line = malloc(spwidth*3);
6770 if(!line) return SANE_STATUS_NO_MEM;
6772 /*load single line color buffer*/
6780 line[i*3] = line[i*3+1] = line[i*3+2] = buff[i*3];
6784 line[i*3] = line[i*3+1] = line[i*3+2] = buff[i*3+1];
6788 line[i*3] = line[i*3+1] = line[i*3+2] = buff[i*3+2];
6792 line[i*3] = (buff[i*3+1] + buff[i*3+2])/2;
6793 line[i*3+1] = buff[i*3+1];
6794 line[i*3+2] = buff[i*3+2];
6799 line[i*3] = buff[i*3];
6800 line[i*3+1] = (buff[i*3] + buff[i*3+2])/2;
6801 line[i*3+2] = buff[i*3+2];
6806 line[i*3] = buff[i*3];
6807 line[i*3+1] = buff[i*3+1];
6808 line[i*3+2] = (buff[i*3] + buff[i*3+1])/2;
6814 memcpy(line, buff, sbwidth);
6820 line[i*3] = line[i*3+1] = line[i*3+2] = buff[i];
6828 line[i*24+0] = line[i*24+1] = line[i*24+2] = ((curr >> 7) & 1) ?0:255;
6829 line[i*24+3] = line[i*24+4] = line[i*24+5] = ((curr >> 6) & 1) ?0:255;
6830 line[i*24+6] = line[i*24+7] = line[i*24+8] = ((curr >> 5) & 1) ?0:255;
6831 line[i*24+9] = line[i*24+10] = line[i*24+11] = ((curr >> 4) & 1) ?0:255;
6832 line[i*24+12] = line[i*24+13] = line[i*24+14] =((curr >> 3) & 1) ?0:255;
6833 line[i*24+15] = line[i*24+16] = line[i*24+17] =((curr >> 2) & 1) ?0:255;
6834 line[i*24+18] = line[i*24+19] = line[i*24+20] =((curr >> 1) & 1) ?0:255;
6835 line[i*24+21] = line[i*24+22] = line[i*24+23] =((curr >> 0) & 1) ?0:255;
6849 line[i*3] = line[source];
6850 line[i*3+1] = line[source+1];
6851 line[i*3+2] = line[source+2];
6860 /* change mode, store line in buffer */
6864 memcpy(s->buffers[side]+s->i.bytes_sent[side], line+(offset*3), ibwidth);
6872 = ((int)line[source] + line[source+1] + line[source+2])/3;
6886 if( (line[source] + line[source+1] + line[source+2]) < thresh ){
6896 free(line);
7319 /* pretend we are doing a 1 line scan in duplex */
8948 char line[70]; /* 'xxx: xx xx ... xx xx abc */
8949 char *hex = line+4;
8950 char *bin = line+53;
8955 line[0] = 0;
8961 /* at start of line */
8964 /* not at start of first line, print current, reset */
8966 DBG (level, "%s\n", line);
8969 memset(line,0x20,69);
8970 line[69] = 0;
8971 hex = line + 4;
8972 bin = line + 53;
8974 sprintf (line, "%3.3x:", i);
8992 /* print last (partial) line */
8994 DBG (level, "%s\n", line);
9212 slope rotates line around central input/output val,
9213 0 makes horizontal line
9223 offset moves line vertically, and clamps to output range
9224 0 keeps the line crossing the center of the table
9261 /* line must stay vertically centered, so figure