2cdeee2e8af373581853a47462c21365f1c10edd
1 #ifndef SP_FECONVOLVEMATRIX_H_SEEN
2 #define SP_FECONVOLVEMATRIX_H_SEEN
4 /** \file
5 * SVG <feConvolveMatrix> implementation, see sp-feConvolveMatrix.cpp.
6 */
7 /*
8 * Authors:
9 * Felipe CorrĂȘa da Silva Sanches <felipe.sanches@gmail.com>
10 * Hugo Rodrigues <haa.rodrigues@gmail.com>
11 *
12 * Copyright (C) 2006 Hugo Rodrigues
13 *
14 * Released under GNU GPL, read the file 'COPYING' for more information
15 */
17 #include "sp-filter.h"
18 #include "sp-feconvolvematrix-fns.h"
19 #include "number-opt-number.h"
20 #include "display/nr-filter-convolve-matrix.h"
21 #include <vector>
23 /* FeConvolveMatrix base class */
24 class SPFeConvolveMatrixClass;
26 struct SPFeConvolveMatrix : public SPFilterPrimitive {
27 /* CONVOLVEMATRIX ATTRIBUTES */
28 NumberOptNumber order;
29 std::vector<gdouble> kernelMatrix;
30 double divisor, bias;
31 int targetX, targetY;
32 NR::FilterConvolveMatrixEdgeMode edgeMode;
33 NumberOptNumber kernelUnitLength;
34 bool preserveAlpha;
35 //some helper variables:
36 bool targetXIsSet;
37 bool targetYIsSet;
38 bool divisorIsSet;
39 bool kernelMatrixIsSet;
40 };
42 struct SPFeConvolveMatrixClass {
43 SPFilterPrimitiveClass parent_class;
44 };
46 GType sp_feConvolveMatrix_get_type();
49 #endif /* !SP_FECONVOLVEMATRIX_H_SEEN */
51 /*
52 Local Variables:
53 mode:c++
54 c-file-style:"stroustrup"
55 c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
56 indent-tabs-mode:nil
57 fill-column:99
58 End:
59 */
60 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :