Flatten carver if needed in nrg_preview_get_nrg
[liblqr.git] / man / lqr_carver_scan_line.3
blob60d1307651dd20ab16d8df0303f302460cd252f5
1 .\"     Title: \fBlqr_carver_scan_line\fR
2 .\"    Author: Carlo Baldassi
3 .\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
4 .\"      Date: 16 Apr 2009
5 .\"    Manual: LqR library API reference
6 .\"    Source: LqR library 0.4.0 API (3:0:3)
7 .\"
8 .TH "\FBLQR_CARVER_SCAN_LINE\FR" "3" "16 Apr 2009" "LqR library 0.4.0 API (3:0:3)" "LqR library API reference"
9 .\" disable hyphenation
10 .nh
11 .\" disable justification (adjust text to left margin only)
12 .ad l
13 .SH "NAME"
14 lqr_carver_scan_line, lqr_carver_scan_line_ext \- read out a multi-size image one line at a time
15 .SH "SYNOPSIS"
16 .sp
17 .ft B
18 .nf
19 #include <lqr\&.h>
20 .fi
21 .ft
22 .HP 30
23 .BI "gboolean lqr_carver_scan_line(LqrCarver*\ " "carver" ", gint*\ " "n" ", guchar**\ " "rgb" ");"
24 .HP 34
25 .BI "gboolean lqr_carver_scan_line_ext(LqrCarver*\ " "carver" ", gint*\ " "n" ", void**\ " "rgb" ");"
26 .SH "DESCRIPTION"
27 .PP
28 The functions
29 \fBlqr_carver_scan_line\fR
30 and
31 \fBlqr_carver_scan_line_ext\fR
32 are used to read out the multi\-size image contained in the
33 LqrCarver
34 object pointed to by
35 \fIcarver\fR
36 one line at a time\&. They store the line number (row or column) in the variable pointed to by
37 \fIn\fR
38 and the colour values in the array pointed to by
39 \fIrgb\fR; then they move the readout pointer to the next line, or they reset it if the end of the image is reached\&.
40 .PP
41 The first one must only be used on the
42 LqrCarver
43 objects created with
44 \fIlqr_carver_new\fR, i\&.e\&. with 8\-bit images, while the second one is general, but the
45 \fIrgb\fR
46 pointer must be cast to the appropriate type to be used (i\&.e pass the address of a pointer to
47 void
48 to the function
49 \fBlqr_carver_scan_line_ext\fR, then cast it to a pointer of the appropriate type and use this last one for reading the output)\&.
50 .PP
51 Use the function
52 \fBlqr_carver_scan_by_row\fR(3)
53 before calling these to know whether your image will be scanned by row or by column\&.
54 .SH "RETURN VALUE"
55 .PP
56 These functions return
57 TRUE
58 in case the readout is successful and the end of the image was not reached,
59 FALSE
60 otherwise\&. If
61 \fBlqr_carver_scan_line\fR
62 is called over a non\-8\-bit
63 LqrCarver
64 object, it will return
65 FALSE\&.
66 .SH "SEE ALSO"
67 .PP
69 \fBLqrColDepth\fR(3), \fBlqr_carver_scan_reset\fR(3), \fBlqr_carver_scan\fR(3), \fBlqr_carver_scan_by_row\fR(3)
70 .SH "COPYRIGHT"
71 Copyright \(co 2007-2009 Carlo Baldassi
72 .br