Krita

FilterLayer.h
1 /*
2  * SPDX-FileCopyrightText: 2017 Wolthera van Hövell tot Westerflier <[email protected]>
3  *
4  * SPDX-License-Identifier: LGPL-2.0-or-later
5  */
6 #ifndef LIBKIS_FILTERLAYER_H
7 #define LIBKIS_FILTERLAYER_H
8 
9 #include <QObject>
10 #include "Node.h"
11 #include <Filter.h>
12 #include <Selection.h>
13 
14 #include <kis_types.h>
15 
16 #include "kritalibkis_export.h"
17 #include "libkis.h"
18 /**
19  * @brief The FilterLayer class
20  * A filter layer will, when compositing, take the composited
21  * image up to the point of the loction of the filter layer
22  * in the stack, create a copy and apply a filter.
23  *
24  * This means you can use blending modes on the filter layers,
25  * which will be used to blend the filtered image with the original.
26  *
27  * Similarly, you can activate things like alpha inheritance, or
28  * you can set grayscale pixeldata on the filter layer to act as
29  * a mask.
30  *
31  * Filter layers can be animated.
32  */
33 class KRITALIBKIS_EXPORT FilterLayer : public Node
34 {
35  Q_OBJECT
37 
38 public:
39  explicit FilterLayer(KisImageSP image, QString name, Filter &filter, Selection &selection, QObject *parent = 0);
40  explicit FilterLayer(KisAdjustmentLayerSP layer, QObject *parent = 0);
41  ~FilterLayer() override;
42 public Q_SLOTS:
43 
44  /**
45  * @brief type Krita has several types of nodes, split in layers and masks. Group
46  * layers can contain other layers, any layer can contain masks.
47  *
48  * @return "filterlayer"
49  */
50  QString type() const override;
51 
52  void setFilter(Filter &filter);
53 
54  Filter * filter();
55 };
56 
57 #endif // LIBKIS_FILTERLAYER_H
58 
virtual QString type() const
type Krita has several types of nodes, split in layers and masks.
Definition: Node.cpp:456
Q_SLOTSQ_SLOTS
Selection represents a selection on Krita.
Definition: Selection.h:30
Filter: represents a filter and its configuration.
Definition: Filter.h:30
Node represents a layer or mask in a Krita image's Node hierarchy.
Definition: Node.h:21
Q_DISABLE_COPY(Class)
The FilterLayer class A filter layer will, when compositing, take the composited image up to the poin...
Definition: FilterLayer.h:33
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Thu Oct 6 2022 04:17:36 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.