Go to the documentation of this file.00001
00002 #ifndef vil_dicom_file_format_h_
00003 #define vil_dicom_file_format_h_
00004 #ifdef VCL_NEEDS_PRAGMA_INTERFACE
00005 #pragma interface
00006 #endif
00007
00008
00009
00010
00011
00012
00013
00014 #include <vil/vil_image_resource.h>
00015 #include <vil/vil_file_format.h>
00016 #include <vil/file_formats/vil_dicom_header.h>
00017
00018 class DicomImage;
00019 class vil_dicom_stream_input;
00020 class DcmFileFormat;
00021
00022 class vil_image_view_base;
00023
00024
00025
00026 class vil_dicom_file_format : public vil_file_format
00027 {
00028 public:
00029 virtual char const* tag() const;
00030 virtual vil_image_resource_sptr make_input_image(vil_stream* vs);
00031 virtual vil_image_resource_sptr make_output_image(vil_stream* vs,
00032 unsigned ni,
00033 unsigned nj,
00034 unsigned nplanes,
00035 vil_pixel_format format);
00036 };
00037
00038
00039
00040 class vil_dicom_image : public vil_image_resource
00041 {
00042 vil_dicom_header_info header_;
00043 vil_image_resource_sptr pixels_;
00044
00045 public:
00046 vil_dicom_image(vil_stream* is, unsigned ni,
00047 unsigned nj, unsigned nplanes,
00048 vil_pixel_format format);
00049 vil_dicom_image(vil_stream* is);
00050 ~vil_dicom_image();
00051
00052 virtual unsigned nplanes() const;
00053 virtual unsigned ni() const;
00054 virtual unsigned nj() const;
00055
00056 virtual enum vil_pixel_format pixel_format() const;
00057
00058 virtual vil_image_view_base_sptr get_copy_view(unsigned i0, unsigned ni,
00059 unsigned j0, unsigned nj) const;
00060
00061 virtual vil_image_view_base_sptr get_view(unsigned i0, unsigned ni,
00062 unsigned j0, unsigned nj) const;
00063
00064 virtual bool put_view(const vil_image_view_base& im, unsigned i0, unsigned j0);
00065
00066 char const* file_format() const;
00067 bool get_property(char const *tag, void *prop = 0) const;
00068
00069
00070 vil_dicom_header_info const& header() const { return header_; }
00071
00072
00073
00074
00075 virtual void correct_manufacturer_discrepancies();
00076
00077
00078 virtual bool interpret_hologic_header(float& xpixSize, float& ypixSize);
00079 };
00080
00081 #endif // vil_dicom_file_format_h_