#include <boost/shared_ptr.hpp>
#include <boost/shared_array.hpp>
+#include "canvas/visibility.h"
#include "canvas/item.h"
typedef void (*ImageReleaseCallback)(uint8_t *d, void *arg);
namespace ArdourCanvas {
-class Image : public Item
+class LIBCANVAS_API Image : public Item
{
public:
- Image (Group *, Cairo::Format, int width, int height);
-
+ Image (Canvas *, Cairo::Format, int width, int height);
+ Image (Item*, Cairo::Format, int width, int height);
+
struct Data {
Data (uint8_t *d, int w, int h, int s, Cairo::Format fmt)
: data (d)
void* destroy_arg;
};
- /**
- * Returns a shared_ptr to a Data object that can be used to
+ /**
+ * Returns a shared_ptr to a Data object that can be used to
* write image data to. The Data object will contain a pointer
* to the buffer, along with image properties that may be
* useful during the data writing.
- *
+ *
* Can be called from any thread BUT ..
*
* ... to avoid collisions with Image deletion, some synchronization method
Cairo::Format _format;
int _width;
int _height;
- int _data;
mutable boost::shared_ptr<Data> _current;
boost::shared_ptr<Data> _pending;
mutable bool _need_render;