00001 #ifndef __DW_IMGBUF_HH__
00002 #define __DW_IMGBUF_HH__
00003
00004 #ifndef __INCLUDED_FROM_DW_CORE_HH__
00005 # error Do not include this file directly, use "core.hh" instead.
00006 #endif
00007
00008 namespace dw {
00009 namespace core {
00010
00159 class Imgbuf: public lout::object::Object, public lout::signal::ObservedObject
00160 {
00161 public:
00162 enum Type { RGB, RGBA, GRAY, INDEXED, INDEXED_ALPHA };
00163
00164
00165
00166
00167
00168 virtual void setCMap (int *colors, int num_colors) = 0;
00169 virtual void copyRow (int row, const byte *data) = 0;
00170 virtual void newScan () = 0;
00171
00172
00173
00174
00175
00176 virtual Imgbuf* getScaledBuf (int width, int height) = 0;
00177 virtual void getRowArea (int row, dw::core::Rectangle *area) = 0;
00178 virtual int getRootWidth () = 0;
00179 virtual int getRootHeight () = 0;
00180
00181
00182
00183
00184
00185 virtual void ref () = 0;
00186 virtual void unref () = 0;
00187
00191 virtual bool lastReference () = 0;
00192
00193
00197 virtual void setDeleteOnUnref (bool deleteOnUnref) = 0;
00198
00202 virtual bool isReferred () = 0;
00203 };
00204
00205 }
00206 }
00207
00208 #endif // __DW_IMGBUF_HH__