STIR  6.2.0
ECAT7DynamicDiscretisedDensityInputFileFormat.h
Go to the documentation of this file.
1 //
2 //
3 #ifndef __stir_IO_ECAT7DynamicDiscretisedDensityInputFileFormat_h__
4 #define __stir_IO_ECAT7DynamicDiscretisedDensityInputFileFormat_h__
5 /*
6  Copyright (C) 2006 - 2007-10-08, Hammersmith Imanet Ltd
7  Copyright (C) 2011-07-01 - 2011, Kris Thielemans
8  This file is part of STIR.
9  SPDX-License-Identifier: Apache-2.0
10 
11  See STIR/LICENSE.txt for details
12 */
25 #include <fstream>
26 #include <string>
27 
28 #ifndef HAVE_LLN_MATRIX
29 # error HAVE_LLN_MATRIX not defined: you need the lln ecat library.
30 #endif
31 
32 #include "stir/IO/stir_ecat7.h"
33 START_NAMESPACE_STIR
34 START_NAMESPACE_ECAT
35 START_NAMESPACE_ECAT7
36 
38 
42 class ECAT7DynamicDiscretisedDensityInputFileFormat : public InputFileFormat<DynamicDiscretisedDensity>
43 {
44 public:
45  virtual const std::string get_name() const { return "ECAT7"; }
46 
47 protected:
48  virtual bool actual_can_read(const FileSignature& signature, std::istream& input) const;
49 
51  virtual unique_ptr<data_type> read_from_file(std::istream& input) const;
52 
54  virtual unique_ptr<data_type> read_from_file(const std::string& filename) const;
55 };
56 
57 END_NAMESPACE_ECAT
58 END_NAMESPACE_ECAT7
59 END_NAMESPACE_STIR
60 
61 #endif
A class to read/store the file signature.
Definition: FileSignature.h:34
Declaration of class stir::InputFileFormat.
Declaration of routines which convert CTI things into our building blocks and vice versa...
Declaration of class stir::DynamicDiscretisedDensity.
unique_ptr< DataT > read_from_file(const FileSignature &signature, FileT file)
Function that reads data from file using the default InputFileFormatRegistry, using the provided File...
Definition: read_from_file.h:46
Class for reading images in ECAT7 file-format.
Definition: ECAT7DynamicDiscretisedDensityInputFileFormat.h:42
Base-class for file-formats for reading.
Definition: InputFileFormat.h:39