~valavanisalex/ubuntu/oneiric/inkscape/inkscape_0.48.1-2ubuntu4

« back to all changes in this revision

Viewing changes to src/trace/imagemap.h

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2006-07-06 22:03:02 UTC
  • mto: (2.4.1 sid) (1.4.1 upstream) (45.1.3 maverick)
  • mto: This revision was merged to the branch mainline in revision 9.
  • Revision ID: james.westby@ubuntu.com-20060706220302-itgso3qgxdaxjmcy
Tags: upstream-0.44
ImportĀ upstreamĀ versionĀ 0.44

Show diffs side-by-side

added added

removed removed

Lines of Context:
94
94
 
95
95
 
96
96
/*#########################################################################
 
97
### P A C K E D    P I X E L     M A P
 
98
#########################################################################*/
 
99
 
 
100
 
 
101
typedef struct PackedPixelMap_def PackedPixelMap;
 
102
 
 
103
/**
 
104
 *
 
105
 */
 
106
struct PackedPixelMap_def
 
107
{
 
108
 
 
109
    /*#################
 
110
    ### METHODS
 
111
    #################*/
 
112
 
 
113
    /**
 
114
     *
 
115
     */
 
116
    void (*setPixel)(PackedPixelMap *me, int x, int y, int r, int g, int b);
 
117
 
 
118
 
 
119
    /**
 
120
     *
 
121
     */
 
122
    void (*setPixelLong)(PackedPixelMap *me, int x, int y, unsigned long rgb);
 
123
 
 
124
 
 
125
    /**
 
126
     *
 
127
     */
 
128
    unsigned long (*getPixel)(PackedPixelMap *me, int x, int y);
 
129
 
 
130
 
 
131
    /**
 
132
     *
 
133
     */
 
134
    int (*writePPM)(PackedPixelMap *me, char *fileName);
 
135
 
 
136
 
 
137
 
 
138
    /**
 
139
     *
 
140
     */
 
141
    void (*destroy)(PackedPixelMap *me);
 
142
 
 
143
 
 
144
 
 
145
    /*#################
 
146
    ### FIELDS
 
147
    #################*/
 
148
 
 
149
    /**
 
150
     *
 
151
     */
 
152
    int width;
 
153
 
 
154
    /**
 
155
     *
 
156
     */
 
157
    int height;
 
158
 
 
159
    /**
 
160
     * The allocated array of pixels
 
161
     */
 
162
    unsigned long *pixels;
 
163
 
 
164
    /**
 
165
     * Pointers to the beginning of each row of pixels
 
166
     */
 
167
    unsigned long **rows;
 
168
 
 
169
 
 
170
};
 
171
 
 
172
 
 
173
 
 
174
#ifdef __cplusplus
 
175
extern "C" {
 
176
#endif
 
177
 
 
178
PackedPixelMap *PackedPixelMapCreate(int width, int height);
 
179
 
 
180
#ifdef __cplusplus
 
181
}
 
182
#endif
 
183
 
 
184
 
 
185
 
 
186
/*#########################################################################
97
187
### R G B   M A P
98
188
#########################################################################*/
99
189
 
264
354
     *
265
355
     */
266
356
    int nrColors;
267
 
    
 
357
 
268
358
    /**
269
359
     * Color look up table
270
360
     */
285
375
#endif
286
376
 
287
377
 
 
378
 
 
379
 
288
380
#endif /* __IMAGEMAP_H__ */
289
381
 
290
382
/*#########################################################################