Program: gdcm
Module: $RCSfile: gdcmFile.cxx,v $
Language: C++
- Date: $Date: 2005/03/09 19:31:54 $
- Version: $Revision: 1.229 $
+ Date: $Date: 2005/03/11 11:12:13 $
+ Version: $Revision: 1.230 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
{
RLEInfo = new RLEFramesInfo;
JPEGInfo = new JPEGFragmentsInfo;
- InitializeDefaultFile();
+ GrPixel = 0x7fe0;
+ NumPixel = 0x0010;
}
/**
//-----------------------------------------------------------------------------
// Protected
-/**
- * \brief Initialize a default DICOM File that should contain all the
- * fields required by other readers. DICOM standard does not
- * explicitely defines those fields, heuristic has been choosen.
- * \todo final removal of this method
- * with FileHelper::CheckMandatoryElements()
- */
-void File::InitializeDefaultFile()
-{
- // fixme
- // Just to avoid further trouble if user asks
- //to write the file ACR-NEMA mode
- InsertValEntry("", 0x0008, 0x0010); // Recognition Code (RET)
-
- // fixme
- GrPixel = 0x7fe0;
- NumPixel = 0x0010;
-
-}
//-----------------------------------------------------------------------------
// Private
Program: gdcm
Module: $RCSfile: gdcmFile.h,v $
Language: C++
- Date: $Date: 2005/02/15 18:12:35 $
- Version: $Revision: 1.104 $
+ Date: $Date: 2005/03/11 11:12:13 $
+ Version: $Revision: 1.105 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
bool Write(std::string fileName, FileType filetype);
protected:
- /// Initialize DICOM File when none
- void InitializeDefaultFile();
/// Store the RLE frames info obtained during parsing of pixels.
RLEFramesInfo *RLEInfo;
Module: $RCSfile: gdcmFileHelper.cxx,v $
Language: C++
- Date: $Date: 2005/03/09 09:45:33 $
- Version: $Revision: 1.29 $
+ Date: $Date: 2005/03/11 11:12:13 $
+ Version: $Revision: 1.30 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
break;
case ACR:
case ACR_LIBIDO:
+ // Just to avoid further trouble if user create a file ex-nihilo,
+ // wants to write it as an ACR-NEMA file,
+ // and forget to create any Entry belonging to group 0008
+ // (shame on him !)
+ // We add Recognition Code (RET)
+ if ( ! FileInternal->GetValEntry(0x0008, 0x0010) )
+ FileInternal->InsertValEntry("", 0x0008, 0x0010);
SetWriteFileTypeToACR();
break;
default: