15 #ifndef __WXIMAGEPRIM_H__
16 #define __WXIMAGEPRIM_H__
48 a2dImage(
const wxImage& image,
double xc,
double yc,
double w,
double h );
59 a2dImage(
const wxString& imagefile, wxBitmapType type,
double xc,
double yc,
double w,
double h );
76 a2dImage(
a2dCanvasObject* torender,
double xc,
double yc,
double w,
double h,
int imagew = 100,
int imageh = 100 );
86 void SetOpacityFactor( wxUint8 OpacityFactor );
95 a2dCanvasObjectList* GetAsRectangles(
const wxColour& col1,
const wxColour& col2,
bool transform );
108 void RenderObject(
a2dCanvasObject* torender,
int imagew = 100 ,
int imageh = 100 );
139 void SetFilename(
const wxString filename, wxBitmapType type,
bool doread =
true );
156 void SetDrawPatternOnTop(
bool drawPatternOnTop );
173 virtual
bool DoStartEdit( wxUint16 editmode,
wxEditStyle editstyle );
175 #if wxART2D_USE_CVGIO
179 #endif //wxART2D_USE_CVGIO
194 bool m_drawPatternOnTop;
196 wxUint8 m_OpacityFactor;
223 DECLARE_EVENT_TABLE()
236 a2dRgbaImage(
double x,
double y, wxImage& image, wxUint8 OpacityFactor );
246 void SetOpacityFactor( wxUint8 OpacityFactor );
265 #if wxART2D_USE_CVGIO
269 #endif //wxART2D_USE_CVGIO
282 bool m_drawPatternOnTop;
284 wxUint8 m_OpacityFactor;
312 a2dImageMM(
const wxImage& image,
double xc,
double yc,
double w,
double h );
323 a2dImageMM(
const wxString& imagefile, wxBitmapType type,
double xc,
double yc,
double w,
double h );
332 a2dImageMM(
double x,
double y, wxImage& image,
unsigned char alpha );
359 a2dCanvasObjectList* GetAsRectangles(
const wxColour& col1,
const wxColour& col2,
bool transform );
372 void RenderObject(
a2dCanvasObject* torender,
int imagew = 100 ,
int imageh = 100 );
389 void SetFilename(
const wxString filename, wxBitmapType type,
bool doread =
true );
406 void SetDrawPatternOnTop(
bool drawPatternOnTop );
422 virtual
bool DoStartEdit( wxUint16 editmode,
wxEditStyle editstyle );
424 #if wxART2D_USE_CVGIO
428 #endif //wxART2D_USE_CVGIO
439 bool m_drawPatternOnTop;
double GetWidth() const
get width of image
virtual bool DoIsHitWorld(a2dIterC &ic, a2dHitEvent &hitEvent)
Does hit test on the object (exclusif child objects)
wxImage & GetImage()
get internal wxImage object
class to map references to objects stored in XML, in order to make the connection later on...
wxUint8 GetOpacityFactor()
see SetOpacityFactor()
void SetImage(const wxImage &image)
set image
Input and output handler for the XmlSer format.
virtual void SetPending(bool pending)
set this object pending for update
OVERLAP
Result of a a2dBoundingBox intersection or hittest.
The base class for all drawable objects in a a2dCanvasDocument.
#define DECLARE_PROPERTIES()
check if class has the given id as a valid id for this object
virtual void DoLoad(wxObject *parent, a2dIOHandlerXmlSerIn &parser, a2dXmlSer_flag xmlparts)
load object specific CVG data
a2dCanvasObject is the base class for Canvas Objects.
wxImage & GetImage()
get internal wxImage object
virtual void DoRender(a2dIterC &ic, OVERLAP clipparent)
render derived object
void SetImageType(wxBitmapType type)
set type of image for saving
bool GetDrawPatternOnTop()
Returns if the pattern will be drawn on top of the image.
a2dImageMM (will scale/rotate image when needed)
wxBitmapType GetImageType()
return type of image as was read from the file, or just set.
rectangular shapes derived from a2dCanvasObject
a2dImage (will scale/rotate image when needed)
virtual void DoSave(wxObject *parent, a2dIOHandlerXmlSerOut &out, a2dXmlSer_flag xmlparts, a2dObjectList *towrite)
write object specific CVGL data
void SetWidth(double w)
set width of rectangle
Input and output handler for the XmlSer format.
wxBitmapType GetImageType()
return type of image as was read from the file, or just set.
void SetWidth(double width)
set width
wxString & GetFilename()
get filename
while iterating a a2dCanvasDocument, this holds the context.
void SetImage(const wxImage &image)
set image
double GetHeight() const
get height of image
void SetHeight(double height)
set height
wxUint8 GetOpacityFactor()
see SetOpacityFactor()
The a2dBoundingBox class stores one a2dBoundingBox of a a2dCanvasObject.
void SetHeight(double h)
set height of rectangle
virtual a2dBoundingBox DoGetUnTransformedBbox(a2dBboxFlags flags=a2dCANOBJ_BBOX_NON) const
In derived object this should be overriden to calculate the boundingbox of the object without its chi...
This template class is for property ids with a known data type.
bool GetDrawPatternOnTop()
Returns if the pattern will be drawn on top of the image.
wxString & GetFilename()
get filename
void SetImageType(wxBitmapType type)
set type of image for saving
CloneOptions
options for cloning
structure to give as parameter to member functions of a2dCanvasObject