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 int getSceneIndex() const override;
24 const std::string& getDriverId() const override;
25 std::string getName() const override;
26 cv::Rect getRect() const override;
27 int getNumChannels() const override;
28 DataType getChannelDataType(int channel) const override;
29 Resolution getResolution() const override;
30 double getMagnification() const override;
31 Compression getCompression() const override;
32 int getNumZSlices() const override;
33 int getNumTFrames() const override;
34 std::string getChannelName(int channel) const override;
35 double getZSliceResolution() const override;
36 double getTFrameResolution() const override;
37 std::string getRawMetadata() const override;
38 void readResampledBlockChannelsEx(const cv::Rect& blockRect, const cv::Size& blockSize,
39 const std::vector<int>& componentIndices, int zSliceIndex, int tFrameIndex,
40 cv::OutputArray output) override;
41 std::shared_ptr<CVScene> getOriginScene() const {
42 return m_originScene;
43 }
44 private:
45 void initChannels();
46 void computeInflationValue();
47 private:
48 std::shared_ptr<CVScene> m_originScene;
49 std::list<std::shared_ptr<Transformation>> m_transformations;
50 std::vector<DataType> m_channelDataTypes;
51 int m_inflationValue;
52 };
53}
54
55#if defined(_MSC_VER)
56#pragma warning( pop )
57#endif
Definition: exceptions.hpp:15
Compression
raster data compression enum
Definition: slideio_enums.hpp:12