1 /*=========================================================================
4 Module: $RCSfile: gdcmPixelWriteConvert.cxx,v $
6 Date: $Date: 2005/10/23 15:09:19 $
7 Version: $Revision: 1.11 $
9 Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
10 l'Image). All rights reserved. See Doc/License.txt or
11 http://www.creatis.insa-lyon.fr/Public/Gdcm/License.html for details.
13 This software is distributed WITHOUT ANY WARRANTY; without even
14 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 PURPOSE. See the above copyright notices for more information.
17 =========================================================================*/
19 #include "gdcmDebug.h"
20 #include "gdcmPixelWriteConvert.h"
24 //-----------------------------------------------------------------------------
25 // Constructor / Destructor
29 PixelWriteConvert::PixelWriteConvert()
41 PixelWriteConvert::~PixelWriteConvert()
45 //-----------------------------------------------------------------------------
48 * \brief sets Read Data (and size)
49 * @param data data (uint8_t is for prototyping. if your data is not uint8_t
50 * just cast the pointer for calling the method)
51 * @param size data size, in bytes
53 void PixelWriteConvert::SetReadData(uint8_t *data, size_t size)
60 * \brief Sets the internal pointer to the caller's inData
61 * image representation, BUT WITHOUT COPYING THE DATA.
62 * - 'image' Pixels are presented as C-like 2D arrays : line per line.
63 * - 'volume'Pixels are presented as C-like 3D arrays : plane per plane
64 * \warning Since the pixels are not copied, it is the caller's responsability
65 * not to deallocate its data before gdcm uses them (e.g. with
66 * the Write() method )
67 * @param data data (uint8_t is for prototyping. if your data is not uint8_t
68 * just cast the pointer for calling the method)
69 * @param size size, in bytes.
71 void PixelWriteConvert::SetUserData(uint8_t *data, size_t size)
78 * \brief Get Data (UserData or ReadData)
79 * @return data (uint8_t is for prototyping. if your data is
80 * *not* uint8_t, just cast the returned pointer)
82 uint8_t *PixelWriteConvert::GetData()
95 * \brief Get Data Size (UserData or ReadData)
96 * @return size, in bytes.
98 size_t PixelWriteConvert::GetDataSize()
110 //-----------------------------------------------------------------------------
113 //-----------------------------------------------------------------------------
116 //-----------------------------------------------------------------------------
119 //-----------------------------------------------------------------------------
120 } // end namespace gdcm