SlideIO 2.0.0
Open-source library for reading of medical images
Loading...
Searching...
No Matches
transformerscene.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 "slideio/core/cvscene.hpp"
6#include "transformer_def.hpp"
7
8#if defined(_MSC_VER)
9#pragma warning( push )
10#pragma warning(disable: 4251)
11#endif
12
13namespace slideio
14{
15 class Transformation;
16
17 class SLIDEIO_TRANSFORMER_EXPORTS TransformerScene : public CVScene
18 {
19 public:
20 TransformerScene(std::shared_ptr<CVScene> originScene, const std::list<std::shared_ptr<Transformation>>& list);
21 public:
22 std::string getFilePath() const override;
23 std::string getName() const override;
24 cv::Rect getRect() const override;
25 int getNumChannels() const override;
26 DataType getChannelDataType(int channel) const override;
27 Resolution getResolution() const override;
28 double getMagnification() const override;
29 Compression getCompression() const override;
30 int getNumZSlices() const override;
31 int getNumTFrames() const override;
32 std::string getChannelName(int channel) const override;
33 double getZSliceResolution() const override;
34 double getTFrameResolution() const override;
35 std::string getRawMetadata() const override;
36 void readResampledBlockChannelsEx(const cv::Rect& blockRect, const cv::Size& blockSize,
37 const std::vector<int>& componentIndices, int zSliceIndex, int tFrameIndex,
38 cv::OutputArray output) override;
39 std::shared_ptr<CVScene> getOriginScene() const {
40 return m_originScene;
41 }
42 private:
43 void initChannels();
44 void computeInflationValue();
45 private:
46 std::shared_ptr<CVScene> m_originScene;
47 std::list<std::shared_ptr<Transformation>> m_transformations;
48 std::vector<DataType> m_channelDataTypes;
49 int m_inflationValue;
50 };
51}
52
53#if defined(_MSC_VER)
54#pragma warning( pop )
55#endif
Definition: exceptions.hpp:12
Compression
raster data compression enum
Definition: slideio_enums.hpp:12