2#ifndef _aspose_drawing_drawing2d_path_gradient_brush_h_
3#define _aspose_drawing_drawing2d_path_gradient_brush_h_
6#include "drawing/color.h"
7#include "drawing/brush.h"
8#include "drawing/rectangle_f.h"
9#include "drawing/drawing2d/wrap_mode.h"
10#include "drawing/drawing2d/matrix_order.h"
11#include "drawing/point_f.h"
12#include "system/array.h"
14#ifdef ASPOSECPPLIB_BEING_BUILT
15#include <core/SkColor.h>
16#include <core/SkPoint.h>
19ASPOSECPP_3RD_PARTY_TYPEDEF(SkColor, std::uint32_t);
21ASPOSECPP_3RD_PARTY_CLASS(SkPaint);
23ASPOSECPP_3RD_PARTY_STRUCT(SkPoint);
25ASPOSECPP_3RD_PARTY_TYPEDEF(SkScalar,
float);
28namespace System {
namespace Drawing {
namespace Drawing2D {
155 void CalculateGradientColors()
const;
165 SkColor m_center_color;
170 mutable std::vector<SkColor> m_colors;
171 std::vector<float> m_factors;
173 std::vector<SkScalar> m_positions;
174 bool m_interpolation_colors =
false;
179 std::vector<SkPoint> m_path_points;
A base class for classes that represent fillers used to fill the interiors of graphical shapes....
Definition: brush.h:18
Represents a color. This type should be allocated on stack and passed to functions by value or by ref...
Definition: color.h:24
Represents a brush that fills the interior of a GraphicsPath object with a gradient....
Definition: path_gradient_brush.h:39
void set_Transform(const SharedPtr< Matrix > &value)
Sets a Matrix object that specifies the geometrical transformations for the brush represented by the ...
WrapMode get_WrapMode() const
Returns the wrap mode.
void set_WrapMode(WrapMode value)
Sets the wrap mode.
RectangleF get_Rectangle()
NOT IMPLEMENTED.
SharedPtr< Blend > get_Blend() const
NOT IMPLEMENTED.
SharedPtr< Matrix > get_Transform() const
Returns a copy of a Matrix object that specifies the geometrical transformations for the brush repres...
ArrayPtr< Color > get_SurroundColors() const
Returns colors that correspond to the points in the path this PathGradientBrush fills.
PointF get_FocusScales() const
Gets the focus point for the gradient falloff.
virtual void Apply(SkPaint &paint, const SharedPtr< Drawing2D::Matrix > &matrix, bool apply_shift) override
Sets the properties of the current brush on the specified SkPaint object.
PathGradientBrush(const ArrayPtr< Point > &points, WrapMode wrapMode=WrapMode::Clamp)
Constructs a new instance of PathGradientBrush class.
void set_CenterColor(Color value)
Sets a color that is at the center of the path filled by the current object.
void ScaleTransform(float sx, float sy, Drawing2D::MatrixOrder order=Drawing2D::MatrixOrder::Prepend)
Scales the local geometric transformation by the specified factors in the specified order.
void SetSigmaBellShape(float focus, float scale=1.0f)
NOT IMPLEMENTED.
void set_FocusScales(const PointF &value)
Sets the focus point for the gradient falloff.
void set_Blend(const SharedPtr< Blend > &value)
Sets a blend that specifies factors and positions of base colors for this brush.
void set_InterpolationColors(const SharedPtr< ColorBlend > &value)
Sets a value the defines a multicolor linear gradient.
void TranslateTransform(float dx, float dy, Drawing2D::MatrixOrder order=Drawing2D::MatrixOrder::Prepend)
Translates the local geometric transformation by the specified dimensions in the specified order.
PointF get_CenterPoint() const
Gets the center point of the gradient.
void set_SurroundColors(const ArrayPtr< Color > &value)
Sets colors that correspond to the points in the path this PathGradientBrush fills.
void set_CenterPoint(const PointF &value)
Sets the center point of the gradient.
void ResetTransform()
Resets the current object's transform matrix so that it becomes an identity matrix.
PathGradientBrush(const ArrayPtr< PointF > &points, WrapMode wrapMode=WrapMode::Clamp)
Constructs a new instance of PathGradientBrush class.
virtual SharedPtr< Brush > Clone() override
Creates a copy of the current object.
void SetBlendTriangularShape(float focus, float scale=1.0f)
NOT IMPLEMENTED.
void RotateTransform(float angle, Drawing2D::MatrixOrder order=Drawing2D::MatrixOrder::Prepend)
Rotates the local geometric transformation by the specified angle in the specified order.
SharedPtr< ColorBlend > get_InterpolationColors() const
Returns a value the defines a multicolor linear gradient.
PathGradientBrush(const SharedPtr< GraphicsPath > &path)
Constructs a new instance of PathGradientBrush class.
Color get_CenterColor() const
Returns a color that is at the center of the path filled by the current object.
void MultiplyTransform(const SharedPtr< Matrix > &matrix, MatrixOrder order=MatrixOrder::Prepend)
Multiplies current object's transform matrix by the specified matrix.
Represents a pair of single-precision floating point X and Y coordinates of a point on a 2-dimensiona...
Definition: point_f.h:14
Represents a rectangular area of an image defined as single-precision floating point X and Y coordina...
Definition: rectangle_f.h:15
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: smart_ptr.h:180
MatrixOrder
Specifies the order of matrix transform operations.
Definition: matrix_order.h:7
@ Prepend
The new operation is applied before the old operation.
WrapMode
Specifies how a texture or a gradient is tiled when it is smaller than the area being filled.
Definition: wrap_mode.h:9
@ Clamp
Clamps the texture or gradient to the object boundary.
Definition: db_command.h:9