X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FgdcmPixelWriteConvert.cxx;h=e5f8ae9d0192f831e44d7ec81f266f16755b631b;hb=cb4f20df180632c04cfd29497b0038874b24678c;hp=5f97e055c7547f8b4430d97fe3d601892b2482e8;hpb=3869544e5153cebbd44ad8778cbaf35883bfb993;p=gdcm.git diff --git a/src/gdcmPixelWriteConvert.cxx b/src/gdcmPixelWriteConvert.cxx index 5f97e055..e5f8ae9d 100644 --- a/src/gdcmPixelWriteConvert.cxx +++ b/src/gdcmPixelWriteConvert.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: gdcmPixelWriteConvert.cxx,v $ Language: C++ - Date: $Date: 2005/01/07 22:19:48 $ - Version: $Revision: 1.4 $ + Date: $Date: 2005/06/24 10:55:59 $ + Version: $Revision: 1.9 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -16,12 +16,6 @@ =========================================================================*/ -////////////////// TEMPORARY NOTE -// look for "fixMem" and convert that to a member of this class -// Removing the prefix fixMem and dealing with allocations should do the trick -// -// grep PixelWriteConvert everywhere and clean up ! - #include "gdcmDebug.h" #include "gdcmPixelWriteConvert.h" @@ -29,36 +23,59 @@ namespace gdcm { //----------------------------------------------------------------------------- // Constructor / Destructor +/** + * \brief Constructor + */ PixelWriteConvert::PixelWriteConvert() { - ReadData = 0; + ReadData = 0; ReadDataSize = 0; - UserData = 0; + UserData = 0; UserDataSize = 0; } +/** + * \brief Destructor + */ PixelWriteConvert::~PixelWriteConvert() { } //----------------------------------------------------------------------------- // Public -void PixelWriteConvert::SetReadData(uint8_t *data,size_t size) +/** + * \brief SetReadData + * @param data data (uint8_t is for prototyping. if your data is not uint8_t + * just cast the pointer for calling the method) + * @param size size in bytes + */ +void PixelWriteConvert::SetReadData(uint8_t *data, size_t size) { ReadData = data; ReadDataSize = size; } -void PixelWriteConvert::SetUserData(uint8_t *data,size_t size) +/** + * \brief Sets User Data + * @param data data (uint8_t is for prototyping. if your data is not uint8_t + * just cast the pointer for calling the method) + * @param size size in bytes + */ +void PixelWriteConvert::SetUserData(uint8_t *data, size_t size) { UserData = data; UserDataSize = size; } +/** + * \brief Get Data (UserData or ReadData) + * @return data data data (uint8_t is for prototyping. if your data is not uint8_t + * just cast the returned pointer) + */ uint8_t *PixelWriteConvert::GetData() { - if(UserData) + if ( UserData ) { return UserData; } @@ -68,9 +85,13 @@ uint8_t *PixelWriteConvert::GetData() } } +/** + * \brief Get Data Size (UserData or ReadData) + * @return size size in bytes + */ size_t PixelWriteConvert::GetDataSize() { - if(UserData) + if ( UserData ) { return UserDataSize; } @@ -80,5 +101,14 @@ size_t PixelWriteConvert::GetDataSize() } } +//----------------------------------------------------------------------------- +// Protected + +//----------------------------------------------------------------------------- +// Private + +//----------------------------------------------------------------------------- +// Print + //----------------------------------------------------------------------------- } // end namespace gdcm