X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FgdcmFile.h;h=8491fb5297529cbed7b169a95621856092e1790e;hb=f6204e4795251ff95c653e32e8cdca61d2c19880;hp=eb430a8cd442c87c5ea5d93c257314be4d669995;hpb=4672e071f29ed17f7258b27e40d47642abfbb53f;p=gdcm.git diff --git a/src/gdcmFile.h b/src/gdcmFile.h index eb430a8c..8491fb52 100644 --- a/src/gdcmFile.h +++ b/src/gdcmFile.h @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: gdcmFile.h,v $ Language: C++ - Date: $Date: 2004/10/13 14:15:30 $ - Version: $Revision: 1.62 $ + Date: $Date: 2004/10/28 03:10:58 $ + Version: $Revision: 1.68 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -25,7 +25,6 @@ namespace gdcm { - //----------------------------------------------------------------------------- /* * In addition to Dicom header exploration, this class is designed @@ -43,25 +42,22 @@ public: /// Accessor to \ref Header Header* GetHeader() { return HeaderInternal; } - int ComputeDecompressedPixelDataSizeFromHeader(); - /// Accessor to \ref ImageDataSize - size_t GetImageDataSize(){ return ImageDataSize; }; + size_t GetImageDataSize() { return ImageDataSize; }; /// Accessor to \ref ImageDataSizeRaw - size_t GetImageDataSizeRaw(){ return ImageDataSizeRaw; }; + size_t GetImageDataSizeRaw() { return ImageDataSizeRaw; }; + + /// Accessor to \ref PixelConverter + PixelConvert* GetPixelConverter() { return PixelConverter; }; uint8_t* GetImageData(); size_t GetImageDataIntoVector(void* destination, size_t maxSize); uint8_t* GetImageDataRaw(); - void GetImageDataIntoVectorRaw(void* destination, size_t maxSize); // see also Header::SetImageDataSize ?!? bool SetImageData (uint8_t* data, size_t expectedSize); - /// \todo When the caller is aware we simply point to the data: - /// int SetImageDataNoCopy (void* Data, size_t ExpectedSize); - // Write pixels of ONE image on hard drive // No test is made on processor "endianity" // The user must call his reader correctly @@ -70,16 +66,13 @@ public: bool WriteDcmExplVR(std::string const& fileName); bool WriteAcr (std::string const& fileName); - // Don't look any longer for the code : - // It's in file gdcmParsePixels.cxx - bool ParsePixelData(); - virtual bool SetEntryByNumber(std::string const& content, uint16_t group, uint16_t element) { HeaderInternal->SetEntryByNumber(content,group,element); return true; } + uint8_t* GetLutRGBA(); protected: bool WriteBase(std::string const& fileName, FileType type); @@ -87,20 +80,13 @@ protected: private: void Initialise(); - // For JPEG 8 Bits, body in file gdcmJpeg.cxx - bool gdcm_write_JPEG_file (FILE* fp, void* image_buffer, - int image_width, int image_heigh, - int quality); - - // For JPEG 12 Bits, body in file gdcmJpeg12.cxx - bool gdcm_write_JPEG_file12 (FILE* fp, void* image_buffer, - int image_width, int image_height, - int quality); - void SaveInitialValues(); // will belong to the future PixelData class void RestoreInitialValues(); // will belong to the future PixelData class void DeleteInitialValues(); // will belong to the future PixelData class + uint8_t* GetDecompressed(); + int ComputeDecompressedPixelDataSizeFromHeader(); +private: // members variables: /// Header to use to load the file @@ -111,12 +97,13 @@ private: /// the destructor is in charge of deletion. bool SelfHeader; - /// wether already parsed + /// Wether already parsed or not bool Parsed; - /// FIXME - PixelConvert PixelConverter; -// + /// Utility pixel converter + PixelConvert* PixelConverter; + +/// FIXME // --------------- Will be moved to a PixelData class //