OEImageFrame¶
class OEImageFrame : public OEImageBase
OEImageFrame class provides a convenient way to create a frame with a specific dimension and offset relative to an OEImageBase object. See Figure: Schematic representation of OEImageFrame objects.
See also
The following methods are publicly inherited from OEImageBase:
Constructors¶
OEImageFrame(OEImageBase &parent, double width, double height,
const OE2DPoint &offset)
Creates an OEImageFrame object with the given dimension.
- parent
The parent OEImageBase object in which the OEImageFrame object is placed.
- width
The width of the OEImageFrame object.
- height
The height of the OEImageFrame object.
- offset
The offset of the OEImageFrame object relative to top/left corner of its OEImageBase parent.
OEImageFrame(OEImageBase& parent, double padding)
Creates an OEImageFrame object equal paddings around the given image positioning the image frame to the center of the image.
- parent
The parent OEImageBase object in which the OEImageFrame object is placed.
- padding
The padding that applied in all four sides around the parent image. The padding is capped by the \(\frac{1}{3}\) of width and height of the parent image.
Clear¶
void Clear(const OESystem::OEColor &color)
Clears the image with the given color.
See also
OEImageBase::Clear
methodOEColor class
DrawArc¶
void DrawArc(const OE2DPoint ¢er, double bgnAngle, double endAngle,
double radius, const OEPen &pen)
Draws the outline of an arc. See example in Figure: Example of drawing an arc.
See also
OEImageBase::DrawArc
methodOE2DPoint class
OEPen class
DrawCircle¶
void DrawCircle(const OE2DPoint ¢er, double radius, const OEPen &pen)
Draws a circle. See example in Figure: Example of drawing a circle.
See also
OEImageBase::DrawCircle
methodOE2DPoint class
OEPen class
DrawCubicBezier¶
void DrawCubicBezier(const OE2DPoint &bgn, const OE2DPoint &c1,
const OE2DPoint &c2, const OE2DPoint &end, const OEPen &pen)
Draws a cubic Bézier curve. See example in Figure: Example of drawing a cubic Bezier curve.
See also
OEImageBase::DrawCubicBezier
methodOE2DPoint class
OEPen classes
DrawLine¶
void DrawLine(const OE2DPoint &bgn, const OE2DPoint &end, const OEPen &pen)
Draws a line. See example in Figure: Example of drawing a line.
See also
OEImageBase::DrawLine
methodOE2DPoint class
OEPen classes
DrawPath¶
void DrawPath(const OE2DPath& path, const OEPen& pen);Draws a path. See example in Figure: Example of drawing a path.
See also
OEImageBase::DrawPath
methodsOE2DPath class
OEPen classes
DrawPie¶
void DrawPie(const OE2DPoint ¢er, double bgnAngle, double endAngle,
double radius, const OEPen &pen)
Draws a pie. See example in Figure: Example of drawing a pie.
See also
OEImageBase::DrawPie
methodsOE2DPoint class
OEPen classes
DrawPoint¶
void DrawPoint(const OE2DPoint &p, const OESystem::OEColor &color)
Draws a point. See example in Figure: Example of drawing a point.
See also
OEImageBase::DrawPoint
methodOE2DPoint class
OEColor class
DrawPolygon¶
void DrawPolygon(const std::vector<OE2DPoint> &points, const OEPen &pen)
Draws a closed polygon. See example in Figure: Example of drawing a polygon.
See also
OEImageBase::DrawPolygon
methodOE2DPoint class
OEPen class
DrawQuadraticBezier¶
void DrawQuadraticBezier(const OE2DPoint &bgn, const OE2DPoint &c,
const OE2DPoint &end, const OEPen &pen)
Draws a quadratic Bézier curve. See example in Figure: Example of drawing a quadratic Bezier curve.
See also
OEImageBase::DrawQuadraticBezier
methodsOE2DPoint class
OEPen classes
DrawRectangle¶
void DrawRectangle(const OE2DPoint &tl, const OE2DPoint &br, const OEPen &pen)
Draws a rectangle. See example in Figure: Example of drawing a rectangle.
See also
OEImageBase::DrawRectangle
methodOE2DPoint class
OEPen class
DrawText¶
void DrawText(const OE2DPoint &c, const std::string &text, const OEFont &font,
double maxwidth=0.0)
Draws a text. See example in Figure: Example of drawing a text.
See also
OEImageBase::DrawText
methodOE2DPoint class
OEFont class
DrawTriangle¶
void DrawTriangle(const OE2DPoint &a, const OE2DPoint &b, const OE2DPoint &c,
const OEPen &pen)
Draws a triangle. See example in Figure: Example of drawing a triangle.
See also
OEImageBase::DrawTriangle
methodOE2DPoint class
OEPen classes
GetOffset¶
const OE2DPoint &GetOffset() const
Returns the offset of the OEImageFrame object relative to its OEImageBase parent.