MITK-IGT
IGT Extension of MITK
Loading...
Searching...
No Matches
mitkToFNrrdImageWriter.h
Go to the documentation of this file.
1/*============================================================================
2
3The Medical Imaging Interaction Toolkit (MITK)
4
5Copyright (c) German Cancer Research Center (DKFZ)
6All rights reserved.
7
8Use of this source code is governed by a 3-clause BSD license that can be
9found in the LICENSE file.
10
11============================================================================*/
12#ifndef mitkToFNrrdImageWriter_h
13#define mitkToFNrrdImageWriter_h
14
15#include <MitkToFHardwareExports.h>
16#include "mitkToFImageWriter.h"
17
18#include <fstream>
19
20namespace mitk
21{
31 class MITKTOFHARDWARE_EXPORT ToFNrrdImageWriter : public ToFImageWriter
32 {
33 public:
37
41 void Open() override;
45 void Close() override;
49 void Add(float* distanceFloatData, float* amplitudeFloatData, float* intensityFloatData, unsigned char* rgbData=nullptr) override;
50
51 protected:
52
53 std::ofstream m_DistanceOutfile;
54 std::ofstream m_AmplitudeOutfile;
55 std::ofstream m_IntensityOutfile;
56 std::ofstream m_RGBOutfile;
57
58 private:
59
61 ~ToFNrrdImageWriter() override;
62
66 void OpenStreamFile(std::ofstream &outfile, std::string outfileName);
70 void CloseStreamFile(std::ofstream &outfile, std::string fileName);
74 void ConvertStreamToNrrdFormat( std::string fileName );
75 };
76} //END mitk namespace
77#endif
Writer class for ToF images.
Writer class for ToF nrrd images.
std::ofstream m_RGBOutfile
file for intensity image
std::ofstream m_DistanceOutfile
file for distance image
std::ofstream m_AmplitudeOutfile
file for amplitude image
mitkClassMacro(ToFNrrdImageWriter, ToFImageWriter)
std::ofstream m_IntensityOutfile
file for intensity image
IGT Exceptions.