SlideIO 2.0.0
Open-source library for reading of medical images
Loading...
Searching...
No Matches
gaussianblurfilter.hpp
1// This file is part of slideio project.
2// It is subject to the license terms in the LICENSE file found in the top-level directory
3// of this distribution and at http://slideio.com/license.html.
4#pragma once
5#include "transformation.hpp"
6#include "slideio/base/slideio_enums.hpp"
7
8namespace slideio
9{
10 class SLIDEIO_TRANSFORMER_EXPORTS GaussianBlurFilter : public Transformation
11 {
12 public:
13 GaussianBlurFilter()
14 {
15 m_type = TransformationType::GaussianBlurFilter;
16 }
17 int getKernelSizeX() const
18 {
19 return m_kernelSizeX;
20 }
21
22 void setKernelSizeX(int kernelSizeX)
23 {
24 m_kernelSizeX = kernelSizeX;
25 }
26
27 int getKernelSizeY() const
28 {
29 return m_kernelSizeY;
30 }
31
32 void setKernelSizeY(int kernelSizeY)
33 {
34 m_kernelSizeY = kernelSizeY;
35 }
36
37 double getSigmaX() const
38 {
39 return m_sigmaX;
40 }
41
42 void setSigmaX(double sigmaX)
43 {
44 m_sigmaX = sigmaX;
45 }
46
47 double getSigmaY() const
48 {
49 return m_sigmaY;
50 }
51
52 void setSigmaY(double sigmaY)
53 {
54 m_sigmaY = sigmaY;
55 }
56
57 void applyTransformation(const cv::Mat& block, cv::OutputArray transformedBlock) const override;
58 int getInflationValue() const override;
59 private:
60 int m_kernelSizeX = 5;
61 int m_kernelSizeY = 5;
62 double m_sigmaX = 0;
63 double m_sigmaY = 0;
64
65 };
66}
Definition: exceptions.hpp:12