Inkscape
Vector Graphics Editor
|
#include <nr-filter-composite.h>
Public Member Functions | |
FilterComposite () | |
~FilterComposite () override | |
void | render_cairo (FilterSlot &) const override |
bool | can_handle_affine (Geom::Affine const &) const override |
Indicate whether the filter primitive can handle the given affine. | |
double | complexity (Geom::Affine const &ctm) const override |
void | set_input (int input) override |
Sets the input slot number 'slot' to be used as input in rendering filter primitive 'primitive' For filter primitive types accepting more than one input, this sets the first input. | |
void | set_input (int input, int slot) override |
Sets the input slot number 'slot' to be user as input number 'input' in rendering filter primitive 'primitive' First input for a filter primitive is number 0. | |
void | set_operator (FeCompositeOperator op) |
void | set_arithmetic (double k1, double k2, double k3, double k4) |
Glib::ustring | name () const override |
![]() | |
FilterPrimitive () | |
virtual | ~FilterPrimitive () |
virtual void | update () |
virtual void | area_enlarge (Geom::IntRect &area, Geom::Affine const &m) const |
virtual void | set_output (int slot) |
Sets the slot number 'slot' to be used as output from filter primitive 'primitive' If output slot for a filter element is not set, one of the unused image slots is used. | |
virtual bool | uses_background () const |
void | set_x (SVGLength const &length) |
Sets the filter primitive subregion. | |
void | set_y (SVGLength const &length) |
void | set_width (SVGLength const &length) |
void | set_height (SVGLength const &length) |
void | set_subregion (SVGLength const &x, SVGLength const &y, SVGLength const &width, SVGLength const &height) |
Geom::Rect | filter_primitive_area (FilterUnits const &units) const |
Returns the filter primitive area in user coordinate system. | |
void | setStyle (SPStyle const *style) |
Sets style for access to properties used by filter primitives. | |
Private Attributes | |
FeCompositeOperator | op |
double | k1 |
double | k2 |
double | k3 |
double | k4 |
int | _input2 |
Additional Inherited Members | |
![]() | |
int | _input |
int | _output |
SVGLength | _subregion_x |
SVGLength | _subregion_y |
SVGLength | _subregion_width |
SVGLength | _subregion_height |
SPColorInterpolation | color_interpolation |
Definition at line 24 of file nr-filter-composite.h.
Inkscape::Filters::FilterComposite::FilterComposite | ( | ) |
Definition at line 24 of file nr-filter-composite.cpp.
|
overridedefault |
|
overridevirtual |
Indicate whether the filter primitive can handle the given affine.
Results of some filter primitives depend on the coordinate system used when rendering. A gaussian blur with equal x and y deviation will remain unchanged by rotations. Per-pixel filters like color matrix and blend will not change regardless of the transformation.
When any filter returns false, filter rendering is performed on an intermediate surface with edges parallel to the axes of the user coordinate system. This means the matrices from FilterUnits will contain at most a (possibly non-uniform) scale and a translation. When all primitives of the filter return true, the rendering is performed in display coordinate space and no intermediate surface is used.
Reimplemented from Inkscape::Filters::FilterPrimitive.
Definition at line 119 of file nr-filter-composite.cpp.
|
overridevirtual |
Reimplemented from Inkscape::Filters::FilterPrimitive.
Definition at line 156 of file nr-filter-composite.cpp.
|
inlineoverridevirtual |
Reimplemented from Inkscape::Filters::FilterPrimitive.
Definition at line 40 of file nr-filter-composite.h.
|
overridevirtual |
Reimplemented from Inkscape::Filters::FilterPrimitive.
Definition at line 66 of file nr-filter-composite.cpp.
References Inkscape::Filters::FilterPrimitive::_input, _input2, Inkscape::Filters::FilterPrimitive::_output, Inkscape::Filters::FilterPrimitive::color_interpolation, COMPOSITE_ARITHMETIC, COMPOSITE_ATOP, COMPOSITE_DEFAULT, COMPOSITE_IN, COMPOSITE_LIGHTER, COMPOSITE_OUT, COMPOSITE_OVER, COMPOSITE_XOR, Inkscape::Filters::FilterPrimitive::filter_primitive_area(), Inkscape::Filters::FilterSlot::get_units(), Inkscape::Filters::FilterSlot::getcairo(), ink_cairo_surface_blend(), ink_cairo_surface_blit(), ink_cairo_surface_create_output(), k1, k2, k3, k4, op, Inkscape::Filters::FilterSlot::set(), set_cairo_surface_ci(), and Inkscape::Filters::FilterSlot::set_primitive_area().
void Inkscape::Filters::FilterComposite::set_arithmetic | ( | double | k1, |
double | k2, | ||
double | k3, | ||
double | k4 | ||
) |
|
overridevirtual |
Sets the input slot number 'slot' to be used as input in rendering filter primitive 'primitive' For filter primitive types accepting more than one input, this sets the first input.
If any of the required input slots is not set, the output of previous filter primitive is used, or SourceGraphic if this is the first primitive for this filter.
Reimplemented from Inkscape::Filters::FilterPrimitive.
Definition at line 124 of file nr-filter-composite.cpp.
References Inkscape::Filters::FilterPrimitive::_input.
|
overridevirtual |
Sets the input slot number 'slot' to be user as input number 'input' in rendering filter primitive 'primitive' First input for a filter primitive is number 0.
For primitives with attributes 'in' and 'in2', these are numbered 0 and 1, respectively. If any of required input slots for a filter is not set, the output of previous filter primitive is used, or SourceGraphic if this is the first filter primitive for this filter.
Reimplemented from Inkscape::Filters::FilterPrimitive.
Definition at line 129 of file nr-filter-composite.cpp.
References Inkscape::Filters::FilterPrimitive::_input, and _input2.
void Inkscape::Filters::FilterComposite::set_operator | ( | FeCompositeOperator | op | ) |
Definition at line 135 of file nr-filter-composite.cpp.
References COMPOSITE_DEFAULT, COMPOSITE_ENDOPERATOR, COMPOSITE_OVER, and op.
|
private |
Definition at line 45 of file nr-filter-composite.h.
Referenced by render_cairo(), and set_input().
|
private |
Definition at line 44 of file nr-filter-composite.h.
Referenced by render_cairo(), and set_arithmetic().
|
private |
Definition at line 44 of file nr-filter-composite.h.
Referenced by render_cairo(), and set_arithmetic().
|
private |
Definition at line 44 of file nr-filter-composite.h.
Referenced by render_cairo(), and set_arithmetic().
|
private |
Definition at line 44 of file nr-filter-composite.h.
Referenced by render_cairo(), and set_arithmetic().
|
private |
Definition at line 43 of file nr-filter-composite.h.
Referenced by render_cairo(), and set_operator().