source: branches/kmk/Lucide/plugins/ludoc/lupixbuf.idl @ 337

Last change on this file since 337 was 95, checked in by Eugene Romanenko, 15 years ago

more comments, new method isFixedImage(), fixed keyboard selection of printer in printer dialog

File size: 1.9 KB
Line 
1#ifndef lupixbuf_idl
2#define lupixbuf_idl
3
4/*
5 *
6 *  LuPixbuf - pixel buffer class, contains pixel data
7 *             in format suitable for use with GpiDrawBits()
8 *
9 */
10
11#include <somobj.idl>
12
13
14interface LuPixbuf : SOMObject
15{
16
17    /**
18     * LuPixbufInit: init routine (constructor)
19     * w: width of newly created pixbuf
20     * h: height of newly created pixbuf
21     * bpp: bytes per pixel, 3 or 4
22     **/
23    void LuPixbufInit( inout somInitCtrl ctrl, in long w, in long h, in short bpp );
24   
25    /**
26     * getWidth
27     *
28     * Returns pixbuf width
29     **/
30    long getWidth();
31   
32    /**
33     * getHeight
34     *
35     * Returns pixbuf height
36     **/
37    long getHeight();
38   
39    /**
40     * getBpp
41     *
42     * Returns number of bytes per pixel (3 or 4)
43     **/
44    short getBpp();
45   
46    /**
47     * getRowSize
48     *
49     * Returns size of one row, in bytes
50     *
51     * Note: (getWidth()*getBpp()) MAY NOT EQUAL getRowSize() as
52     *       row size may be padded to be four-bytes aligned
53     **/
54    long getRowSize();
55   
56    /**
57     * getDataLen
58     *
59     * Returns length of pixbuf data in bytes (getRowSize()*getHeight())
60     **/
61    long getDataLen();
62   
63    /**
64     * getDataPtr
65     *
66     * Returns pointer to pixbuf data
67     **/
68    void *getDataPtr();
69   
70    /**
71     * putAt
72     *
73     * Puts a data of another pixbuf (p) to specified position (x, y)
74     **/
75    void putAt( in LuPixbuf p, in long x, in long y );
76
77
78#ifdef __SOMIDL__
79
80    implementation
81    {
82        releaseorder: LuPixbufInit, getWidth, getHeight, getBpp, getRowSize,
83                                      getDataLen, getDataPtr, putAt;
84   
85        long width;
86        long height;
87        short bpp;
88        long dlen;
89        long rowsize;
90        void *data;
91       
92        LuPixbufInit: init;
93        somDestruct: override;
94    };
95   
96#endif // __SOMIDL__
97
98};
99
100#endif // lupixbuf_idl
Note: See TracBrowser for help on using the repository browser.