Program: gdcm
Module: $RCSfile: TestFromScratch.cxx,v $
Language: C++
- Date: $Date: 2005/01/05 15:38:28 $
- Version: $Revision: 1.4 $
+ Date: $Date: 2005/01/07 16:26:11 $
+ Version: $Revision: 1.5 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
}
// Doesn't seems to do anything:
- dbg.SetDebug(-1);
+ gdcm::Debug::SetDebugLevel(-1);
// Doesn't link properly:
//gdcm::Debug::GetReference().SetDebug(1);
Program: gdcm
Module: $RCSfile: gdcmDebug.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:26 $
- Version: $Revision: 1.13 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.14 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
namespace gdcm
{
+/// warning message level to be displayed
+static int DebugLevel = -1;
//-----------------------------------------------------------------------------
-/**
- * \brief constructor
- * @param level debug level
- */
-Debug::Debug(int level)
-{
- DebugLevel = level;
-}
-
/**
* \brief Accessor
* @param level Set the debug level
*/
-void Debug::SetDebug(int level)
+void Debug::SetDebugLevel (int level)
{
DebugLevel = level;
}
{
return ;
}
- std::cerr << "gdcm::" << msg1 << ' ' << msg2 << std::endl << std::flush;
+ std::cerr << "gdcm::" << msg1 << ' ' << msg2 << std::endl;
}
/**
{
return;
}
- std::cerr << "gdcm::" << msg1 << ' ' << msg2 << std::endl << std::flush;
+ std::cerr << "gdcm::" << msg1 << ' ' << msg2 << std::endl;
Exit(1);
}
const char *msg3)
{
std::cerr << "gdcm::" << msg1 << ' ' << msg2 << ' ' << msg3
- << std::endl << std::flush;
+ << std::endl;
Exit(1);
}
if (!test)
{
std::cerr << "gdcm::" << msg1 << ' ' << msg2
- << std::endl << std::flush;
+ << std::endl;
}
}
*/
void Debug::Exit(int a)
{
-#ifdef __GNUC__
- std::exit(a);
-#endif
-#if defined(_MSC_VER) || defined(__BORLANDC__)
exit(a); // Found in #include <stdlib.h>
-#endif
}
} // end namespace gdcm
Program: gdcm
Module: $RCSfile: gdcmDebug.h,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:26 $
- Version: $Revision: 1.10 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.11 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
public:
Debug(int level = -1);
- void SetDebug (int level);
- void Verbose(int level, const char *msg1, const char *msg2 = "") ;
- void Error (bool test, const char *msg1, const char *msg2 = "");
- void Error (const char *msg1, const char *msg2 = "", const char *msg3 = "");
+ /// This is a global flag that controls whether any debug, warning
+ /// messages are displayed.
+ static void SetDebugLevel (int level);
+ static int GetDebugLevel ();
- void Assert(int level, bool test, const char *msg1, const char *msg2);
- void Exit(int a);
-
- static Debug &GetReference();
-
-private:
-/// warning message level to be displayed
- int DebugLevel;
+ static void Verbose(int level, const char *msg1, const char *msg2 = "") ;
+ static void Error (bool test, const char *msg1, const char *msg2 = "");
+ static void Error (const char *msg1, const char *msg2 = "", const char *msg3 = "");
+ static void Assert(int level, bool test, const char *msg1, const char *msg2);
+ static void Exit (int a);
};
} // end namespace gdcm
-/// Instance of debugging utility.
-static gdcm::Debug dbg;
#endif
Program: gdcm
Module: $RCSfile: gdcmDicomDir.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:26 $
- Version: $Revision: 1.92 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.93 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
// if user passed a root directory, sure we didn't get anything
if ( TagHT.begin() == TagHT.end() ) // when user passed a Directory to parse
{
- dbg.Verbose(0, "DicomDir::DicomDir : entry HT empty");
+ Debug::Verbose(0, "DicomDir::DicomDir : entry HT empty");
if ( fileName.size() == 1 && fileName[0] == '.' )
{
{
MetaElems = NewMeta();
- dbg.Verbose(0, "DicomDir::DicomDir : Parse directory"
+ Debug::Verbose(0, "DicomDir::DicomDir : Parse directory"
" and create the DicomDir");
ParseDirectory();
}
DocEntry *e = GetDocEntryByNumber(0x0004, 0x1220);
if ( !e )
{
- dbg.Verbose(0, "DicomDir::DicomDir : NO Directory record"
+ Debug::Verbose(0, "DicomDir::DicomDir : NO Directory record"
" sequence (0x0004,0x1220)");
/// \todo FIXME : what do we do when the parsed file IS NOT a
/// DICOMDIR file ?
std::ios::out | std::ios::binary);
if( !fp )
{
- dbg.Verbose(2, "Failed to open(write) File: ", fileName.c_str());
+ Debug::Verbose(2, "Failed to open(write) File: ", fileName.c_str());
return false;
}
header = new Header( it->c_str() );
if( !header )
{
- dbg.Verbose( 1,
+ Debug::Verbose( 1,
"DicomDir::CreateDicomDirChainedList: "
"failure in new Header ",
it->c_str() );
{
// Add the file header to the chained list:
list.push_back(header);
- dbg.Verbose( 1,
+ Debug::Verbose( 1,
"DicomDir::CreateDicomDirChainedList: readable ",
it->c_str() );
}
si = new DicomDirImage();
if( !AddDicomDirImageToEnd(static_cast<DicomDirImage *>(si)) )
{
- dbg.Verbose(0,"DicomDir::SetElement:",
+ Debug::Verbose(0,"DicomDir::SetElement:",
"Add DicomDirImageToEnd failed");
}
break;
si = new DicomDirSerie();
if( !AddDicomDirSerieToEnd(static_cast<DicomDirSerie *>(si)) )
{
- dbg.Verbose(0,"DicomDir::SetElement:",
+ Debug::Verbose(0,"DicomDir::SetElement:",
"Add DicomDirSerieToEnd failed");
}
break;
si = new DicomDirStudy();
if( !AddDicomDirStudyToEnd(static_cast<DicomDirStudy *>(si)) )
{
- dbg.Verbose(0,"DicomDir::SetElement:",
+ Debug::Verbose(0,"DicomDir::SetElement:",
"Add DicomDirStudyToEnd failed");
}
break;
si = new DicomDirPatient();
if( !AddDicomDirPatientToEnd(static_cast<DicomDirPatient *>(si)) )
{
- dbg.Verbose(0,"DicomDir::SetElement:",
+ Debug::Verbose(0,"DicomDir::SetElement:",
"Add DicomDirPatientToEnd failed");
}
break;
si = new DicomDirMeta();
if( MetaElems )
{
- dbg.Verbose(0,"DicomDir::SetElement:",
+ Debug::Verbose(0,"DicomDir::SetElement:",
"MetaElements already exist, they will be destroyed");
delete MetaElems;
}
{
if( header->GetFileName().substr(0, path.length()) != path )
{
- dbg.Verbose(0, "DicomDir::SetElement : the base path"
+ Debug::Verbose(0, "DicomDir::SetElement : the base path"
" of file name is incorrect");
val = header->GetFileName();
}
DocEntry *e = GetDocEntryByNumber(0x0004, 0x1220);
if ( !e )
{
- dbg.Verbose(0, "DicomDir::DicomDir : NO Directory record"
+ Debug::Verbose(0, "DicomDir::DicomDir : NO Directory record"
" sequence (0x0004,0x1220)");
/// \todo FIXME: what to do when the parsed file IS NOT a DICOMDIR file ?
return;
SeqEntry *s = dynamic_cast<SeqEntry *>(e);
if ( !s )
{
- dbg.Verbose(0, "DicomDir::CreateDicomDir: no SeqEntry present");
+ Debug::Verbose(0, "DicomDir::CreateDicomDir: no SeqEntry present");
// useless : (0x0004,0x1220) IS a Sequence !
return;
}
}
else
{
- dbg.Verbose(0, "DicomDir::CreateDicomDir: not a ValEntry.");
+ Debug::Verbose(0, "DicomDir::CreateDicomDir: not a ValEntry.");
continue;
}
Program: gdcm
Module: $RCSfile: gdcmDicomDirElement.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:26 $
- Version: $Revision: 1.23 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.24 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
std::ifstream from(filename.c_str());
if(!from)
{
- dbg.Verbose(2,
+ Debug::Verbose(2,
"DicomDirElement::DicomDirElement: can't open dictionary",
filename.c_str());
FillDefaultDIRDict( this );
Program: gdcm
Module: $RCSfile: gdcmDict.cxx,v $
Language: C++
- Date: $Date: 2005/01/07 15:58:19 $
- Version: $Revision: 1.57 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.58 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
std::ifstream from( filename.c_str() );
if( !from )
{
- dbg.Verbose(2,"Dict::Dict: can't open dictionary", filename.c_str());
+ Debug::Verbose(2,"Dict::Dict: can't open dictionary", filename.c_str());
// Using default embeded one:
FillDefaultDataDict( this );
}
if(KeyHt.count(key) == 1)
{
- dbg.Verbose(1, "Dict::AddNewEntry already present", key.c_str());
+ Debug::Verbose(1, "Dict::AddNewEntry already present", key.c_str());
return false;
}
else
}
else
{
- dbg.Verbose(1, "Dict::RemoveEntry unfound entry", key.c_str());
+ Debug::Verbose(1, "Dict::RemoveEntry unfound entry", key.c_str());
return false;
}
}
Program: gdcm
Module: $RCSfile: gdcmDictEntry.cxx,v $
Language: C++
- Date: $Date: 2005/01/07 16:14:58 $
- Version: $Revision: 1.33 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.34 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
}
else
{
- dbg.Error(true, "DictEntry::SetVR",
+ Debug::Error(true, "DictEntry::SetVR",
"Overwriting VR might compromise a dictionary");
}
}
Program: gdcm
Module: $RCSfile: gdcmDictSet.cxx,v $
Language: C++
- Date: $Date: 2005/01/07 12:29:17 $
- Version: $Revision: 1.46 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.47 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
{
resultPath += '/';
}
- dbg.Verbose(1, "DictSet::BuildDictPath:",
+ Debug::Verbose(1, "DictSet::BuildDictPath:",
"Dictionary path set from environnement");
}
else
Program: gdcm
Module: $RCSfile: gdcmDocEntrySet.cxx,v $
Language: C++
- Date: $Date: 2005/01/07 12:29:17 $
- Version: $Revision: 1.34 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.35 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
ValEntry *newEntry = new ValEntry(dictEntry);
if (!newEntry)
{
- dbg.Verbose(1, "Document::NewValEntryByNumber",
+ Debug::Verbose(1, "Document::NewValEntryByNumber",
"failed to allocate ValEntry");
return 0;
}
BinEntry *newEntry = new BinEntry(dictEntry);
if (!newEntry)
{
- dbg.Verbose(1, "Document::NewBinEntryByNumber",
+ Debug::Verbose(1, "Document::NewBinEntryByNumber",
"failed to allocate BinEntry");
return 0;
}
SeqEntry *newEntry = new SeqEntry( dictEntry );
if (!newEntry)
{
- dbg.Verbose(1, "Document::NewSeqEntryByNumber",
+ Debug::Verbose(1, "Document::NewSeqEntryByNumber",
"failed to allocate SeqEntry");
return 0;
}
Dict *pubDict = Global::GetDicts()->GetDefaultPubDict();
if (!pubDict)
{
- dbg.Verbose(0, "Document::GetDictEntry",
+ Debug::Verbose(0, "Document::GetDictEntry",
"we SHOULD have a default dictionary");
}
else
Program: gdcm
Module: $RCSfile: gdcmDocument.cxx,v $
Language: C++
- Date: $Date: 2005/01/07 08:46:18 $
- Version: $Revision: 1.162 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.163 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
return;
}
- dbg.Verbose(0, "Document::Document: starting parsing of file: ",
+ Debug::Verbose(0, "Document::Document: starting parsing of file: ",
Filename.c_str());
Fp->seekg( 0, std::ios::beg);
{
if( Filetype == Unknown)
{
- dbg.Verbose(0, "Document::IsReadable: wrong filetype");
+ Debug::Verbose(0, "Document::IsReadable: wrong filetype");
return false;
}
if( TagHT.empty() )
{
- dbg.Verbose(0, "Document::IsReadable: no tags in internal"
+ Debug::Verbose(0, "Document::IsReadable: no tags in internal"
" hash table.");
return false;
}
if(Fp)
{
- dbg.Verbose( 0,
+ Debug::Verbose( 0,
"Document::OpenFile is already opened when opening: ",
Filename.c_str());
}
Fp = new std::ifstream(Filename.c_str(), std::ios::in | std::ios::binary);
if( ! *Fp )
{
- dbg.Verbose( 0,
+ Debug::Verbose( 0,
"Document::OpenFile cannot open file: ",
Filename.c_str());
delete Fp;
}
CloseFile();
- dbg.Verbose( 0,
+ Debug::Verbose( 0,
"Document::OpenFile not DICOM/ACR (missing preamble)",
Filename.c_str());
{
if (!RemoveEntry(currentEntry))
{
- dbg.Verbose(0, "Document::ReplaceOrCreateByNumber: removal"
+ Debug::Verbose(0, "Document::ReplaceOrCreateByNumber: removal"
" of previous DocEntry failed.");
return NULL;
if ( !AddEntry(valEntry))
{
- dbg.Verbose(0, "Document::ReplaceOrCreateByNumber: AddEntry"
+ Debug::Verbose(0, "Document::ReplaceOrCreateByNumber: AddEntry"
" failed allthough this is a creation.");
delete valEntry;
{
if (!RemoveEntry(currentEntry))
{
- dbg.Verbose(0, "Document::ReplaceOrCreateByNumber: removal"
+ Debug::Verbose(0, "Document::ReplaceOrCreateByNumber: removal"
" of previous DocEntry failed.");
return NULL;
if ( !AddEntry(binEntry))
{
- dbg.Verbose(0, "Document::ReplaceOrCreateByNumber: AddEntry"
+ Debug::Verbose(0, "Document::ReplaceOrCreateByNumber: AddEntry"
" failed allthough this is a creation.");
delete binEntry;
{
if (!RemoveEntry(currentEntry))
{
- dbg.Verbose(0, "Document::ReplaceOrCreateByNumber: removal"
+ Debug::Verbose(0, "Document::ReplaceOrCreateByNumber: removal"
" of previous DocEntry failed.");
return NULL;
if ( !AddEntry(seqEntry))
{
- dbg.Verbose(0, "Document::ReplaceOrCreateByNumber: AddEntry"
+ Debug::Verbose(0, "Document::ReplaceOrCreateByNumber: AddEntry"
" failed allthough this is a creation.");
delete seqEntry;
ValEntry *entry = GetValEntryByNumber(group, element);
if (!entry )
{
- dbg.Verbose(0, "Document::SetEntryByNumber: no corresponding",
+ Debug::Verbose(0, "Document::SetEntryByNumber: no corresponding",
" ValEntry (try promotion first).");
return false;
}
BinEntry *entry = GetBinEntryByNumber(group, element);
if (!entry )
{
- dbg.Verbose(0, "Document::SetEntryByNumber: no corresponding",
+ Debug::Verbose(0, "Document::SetEntryByNumber: no corresponding",
" ValEntry (try promotion first).");
return false;
}
DocEntry *entry = GetDocEntryByNumber(group, elem);
if (!entry)
{
- dbg.Verbose(1, "Document::GetDocEntryByNumber: no entry");
+ Debug::Verbose(1, "Document::GetDocEntryByNumber: no entry");
return 0;
}
if ( BinEntry *binEntry = dynamic_cast<BinEntry*>(entry) )
uint8_t *a = new uint8_t[l];
if( !a )
{
- dbg.Verbose(0, "Document::LoadEntryBinArea cannot allocate a");
+ Debug::Verbose(0, "Document::LoadEntryBinArea cannot allocate a");
return;
}
{
return entry;
}
- dbg.Verbose(0, "Document::GetValEntryByNumber: unfound ValEntry.");
+ Debug::Verbose(0, "Document::GetValEntryByNumber: unfound ValEntry.");
return 0;
}
{
return entry;
}
- dbg.Verbose(0, "Document::GetBinEntryByNumber: unfound BinEntry.");
+ Debug::Verbose(0, "Document::GetBinEntryByNumber: unfound BinEntry.");
return 0;
}
break;
default :
//std::cout << "swapCode= " << SwapCode << std::endl;
- dbg.Error(" Document::SwapLong : unset swap code");
+ Debug::Error(" Document::SwapLong : unset swap code");
a = 0;
}
return a;
if ( ! Global::GetVR()->IsVROfBinaryRepresentable(vr) )
{
////// Neither ValEntry NOR BinEntry: should mean UNKOWN VR
- dbg.Verbose(0, "Document::ParseDES: neither Valentry, "
+ Debug::Verbose(0, "Document::ParseDES: neither Valentry, "
"nor BinEntry. Probably unknown VR.");
}
if( length % 2 )
{
newValue = Util::DicomString(str, length+1);
- //dbg.Verbose(0, "Warning: bad length: ", length );
- dbg.Verbose(0, "For string :", newValue.c_str());
+ //Debug::Verbose(0, "Warning: bad length: ", length );
+ Debug::Verbose(0, "For string :", newValue.c_str());
// Since we change the length of string update it length
entry->SetReadLength(length+1);
}
{
if ( Fp->fail() || Fp->eof())//Fp->gcount() == 1
{
- dbg.Verbose(1, "Document::LoadDocEntry",
+ Debug::Verbose(1, "Document::LoadDocEntry",
"unread element value");
valEntry->SetValue(GDCM_UNREAD);
return;
}
else
{
- dbg.Error(true, "Document::LoadDocEntry"
+ Debug::Error(true, "Document::LoadDocEntry"
"Should have a ValEntry, here !");
}
}
s << "Warning : Tag with uneven length "
<< foundLength
<< " in x(" << std::hex << gr << "," << el <<")" << std::dec;
- dbg.Verbose(0, s.str().c_str());
+ Debug::Verbose(0, s.str().c_str());
}
//////// Fix for some naughty General Electric images.
<< std::hex << group << " , " << element
<< ") -before- position x(" << filePosition << ")"
<< "lgt : " << length;
- dbg.Verbose(0, "Document::IsDocEntryAnInteger", s.str().c_str() );
+ Debug::Verbose(0, "Document::IsDocEntryAnInteger", s.str().c_str() );
}
}
if ( group != 0xfffe || ( ( elem != 0xe0dd ) && ( elem != 0xe000 ) ) )
{
- dbg.Verbose(1, "Document::FindDocEntryLengthOB: neither an Item "
+ Debug::Verbose(1, "Document::FindDocEntryLengthOB: neither an Item "
"tag nor a Sequence delimiter tag.");
Fp->seekg(positionOnEntry, std::ios::beg);
throw FormatUnexpected("Document::FindDocEntryLengthOB()",
char *entCur = deb + 128;
if( memcmp(entCur, "DICM", (size_t)4) == 0 )
{
- dbg.Verbose(1, "Document::CheckSwap:", "looks like DICOM Version3");
+ Debug::Verbose(1, "Document::CheckSwap:", "looks like DICOM Version3");
// Next, determine the value representation (VR). Let's skip to the
// first element (0002, 0000) and check there if we find "UL"
// instead of just checking for UL, OB and UI !? group 0000
{
Filetype = ExplicitVR;
- dbg.Verbose(1, "Document::CheckSwap:",
+ Debug::Verbose(1, "Document::CheckSwap:",
"explicit Value Representation");
}
else
{
Filetype = ImplicitVR;
- dbg.Verbose(1, "Document::CheckSwap:",
+ Debug::Verbose(1, "Document::CheckSwap:",
"not an explicit Value Representation");
}
if ( net2host )
{
SwapCode = 4321;
- dbg.Verbose(1, "Document::CheckSwap:",
+ Debug::Verbose(1, "Document::CheckSwap:",
"HostByteOrder != NetworkByteOrder");
}
else
{
SwapCode = 0;
- dbg.Verbose(1, "Document::CheckSwap:",
+ Debug::Verbose(1, "Document::CheckSwap:",
"HostByteOrder = NetworkByteOrder");
}
// Alas, this is not a DicomV3 file and whatever happens there is no file
// preamble. We can reset the file position indicator to where the data
// is (i.e. the beginning of the file).
- dbg.Verbose(1, "Document::CheckSwap:", "not a DICOM Version3 file");
+ Debug::Verbose(1, "Document::CheckSwap:", "not a DICOM Version3 file");
Fp->seekg(0, std::ios::beg);
// Our next best chance would be to be considering a 'clean' ACR/NEMA file.
Filetype = ACR;
return true;
default :
- dbg.Verbose(0, "Document::CheckSwap:",
+ Debug::Verbose(0, "Document::CheckSwap:",
"ACR/NEMA unfound swap info (Really hopeless !)");
Filetype = Unknown;
return false;
*/
void Document::SwitchSwapToBigEndian()
{
- dbg.Verbose(1, "Document::SwitchSwapToBigEndian",
+ Debug::Verbose(1, "Document::SwitchSwapToBigEndian",
"Switching to BigEndian mode.");
if ( SwapCode == 0 )
{
std::string msg;
msg = Util::Format("Falsely explicit vr file (%04x,%04x)\n",
newEntry->GetGroup(), newEntry->GetElement());
- dbg.Verbose(1, "Document::FindVR: ", msg.c_str());
+ Debug::Verbose(1, "Document::FindVR: ", msg.c_str());
}
newEntry->SetImplicitVR();
}
s << std::hex << itemTagGroup << "," << itemTagElement << ")"
<< std::endl;
s << " at address: " << (unsigned)currentPosition << std::endl;
- dbg.Verbose(0, "Document::ReadItemTagLength: wrong Item Tag found:");
- dbg.Verbose(0, s.str().c_str());
+ Debug::Verbose(0, "Document::ReadItemTagLength: wrong Item Tag found:");
+ Debug::Verbose(0, s.str().c_str());
Fp->seekg(positionOnEntry, std::ios::beg);
return false;
s << "Basic Item Length is: "
<< itemLength << std::endl;
s << " at address: " << (unsigned)currentPosition << std::endl;
- dbg.Verbose(0, "Document::ReadItemTagLength: ", s.str().c_str());
+ Debug::Verbose(0, "Document::ReadItemTagLength: ", s.str().c_str());
}
return itemLength;
}
std::ostringstream s;
s << " Read one length: ";
s << std::hex << individualLength << std::endl;
- dbg.Verbose(0,
+ Debug::Verbose(0,
"Document::ReadAndSkipEncapsulatedBasicOffsetTable: ",
s.str().c_str());
}
if ( nbRleSegments > 16 )
{
// There should be at most 15 segments (refer to RLEFrame class)
- dbg.Verbose(0, "Document::ComputeRLEInfo: too many segments.");
+ Debug::Verbose(0, "Document::ComputeRLEInfo: too many segments.");
}
uint32_t rleSegmentOffsetTable[16];
// Delimiter Item':
if ( !ReadTag(0xfffe, 0xe0dd) )
{
- dbg.Verbose(0, "Document::ComputeRLEInfo: no sequence delimiter ");
- dbg.Verbose(0, " item at end of RLE item sequence");
+ Debug::Verbose(0, "Document::ComputeRLEInfo: no sequence delimiter ");
+ Debug::Verbose(0, " item at end of RLE item sequence");
}
}
// Delimiter Item':
if ( !ReadTag(0xfffe, 0xe0dd) )
{
- dbg.Verbose(0, "Document::ComputeRLEInfo: no sequence delimiter ");
- dbg.Verbose(0, " item at end of JPEG item sequence");
+ Debug::Verbose(0, "Document::ComputeRLEInfo: no sequence delimiter ");
+ Debug::Verbose(0, " item at end of JPEG item sequence");
}
}
Program: gdcm
Module: $RCSfile: gdcmElementSet.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:27 $
- Version: $Revision: 1.36 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.37 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
if( TagHT.count(key) == 1 )
{
- dbg.Verbose(1, "ElementSet::AddEntry key already present: ",
+ Debug::Verbose(1, "ElementSet::AddEntry key already present: ",
key.c_str());
return false;
}
if( TagHT.count(key) == 1 )
{
TagHT.erase(key);
- dbg.Verbose(0, "ElementSet::RemoveEntry: one element erased.");
+ Debug::Verbose(0, "ElementSet::RemoveEntry: one element erased.");
delete entryToRemove;
return true;
}
- dbg.Verbose(0, "ElementSet::RemoveEntry: key not present");
+ Debug::Verbose(0, "ElementSet::RemoveEntry: key not present");
return false ;
}
if( TagHT.count(key) == 1 )
{
TagHT.erase(key);
- dbg.Verbose(0, "ElementSet::RemoveEntry: one element erased.");
+ Debug::Verbose(0, "ElementSet::RemoveEntry: one element erased.");
return true;
}
- dbg.Verbose(0, "ElementSet::RemoveEntry: key not present");
+ Debug::Verbose(0, "ElementSet::RemoveEntry: key not present");
return false ;
}
Program: gdcm
Module: $RCSfile: gdcmFile.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:27 $
- Version: $Revision: 1.183 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.184 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
{
if ( PixelReadConverter->GetRGBSize() > maxSize )
{
- dbg.Verbose(0, "File::GetImageDataIntoVector: pixel data bigger"
+ Debug::Verbose(0, "File::GetImageDataIntoVector: pixel data bigger"
"than caller's expected MaxSize");
return 0;
}
// Either no LUT conversion necessary or LUT conversion failed
if ( PixelReadConverter->GetRawSize() > maxSize )
{
- dbg.Verbose(0, "File::GetImageDataIntoVector: pixel data bigger"
+ Debug::Verbose(0, "File::GetImageDataIntoVector: pixel data bigger"
"than caller's expected MaxSize");
return 0;
}
std::ofstream fp1(fileName.c_str(), std::ios::out | std::ios::binary );
if (!fp1)
{
- dbg.Verbose(2, "Fail to open (write) file:", fileName.c_str());
+ Debug::Verbose(2, "Fail to open (write) file:", fileName.c_str());
return false;
}
case WMODE_RAW :
if( decSize!=PixelWriteConverter->GetUserDataSize() )
{
- dbg.Verbose(0, "File::CheckWriteIntegrity: Data size is incorrect (Raw)");
+ Debug::Verbose(0, "File::CheckWriteIntegrity: Data size is incorrect (Raw)");
//std::cerr << "File::CheckWriteIntegrity: Data size is incorrect (Raw)\n"
// << decSize << " / " << PixelWriteConverter->GetUserDataSize() << "\n";
return false;
case WMODE_RGB :
if( rgbSize!=PixelWriteConverter->GetUserDataSize() )
{
- dbg.Verbose(0, "File::CheckWriteIntegrity: Data size is incorrect (RGB)");
+ Debug::Verbose(0, "File::CheckWriteIntegrity: Data size is incorrect (RGB)");
//std::cerr << "File::CheckWriteIntegrity: Data size is incorrect (RGB)\n"
// << decSize << " / " << PixelWriteConverter->GetUserDataSize() << "\n";
return false;
raw = PixelReadConverter->GetRaw();
if ( ! raw )
{
- dbg.Verbose(0, "File::GetRaw: read/decompress of "
+ Debug::Verbose(0, "File::GetRaw: read/decompress of "
"pixel data apparently went wrong.");
return 0;
}
Program: gdcm
Module: $RCSfile: gdcmGlobal.cxx,v $
Language: C++
- Date: $Date: 2004/12/03 20:16:58 $
- Version: $Revision: 1.7 $
+ Date: $Date: 2005/01/07 16:26:12 $
+ Version: $Revision: 1.8 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
{
if (ValRes || TranSyn || Dicts || ddElem)
{
- dbg.Verbose(0, "Global::Global : VR or TS or Dicts already allocated");
+ Debug::Verbose(0, "Global::Global : VR or TS or Dicts already allocated");
return;
}
Dicts = new DictSet();
Program: gdcm
Module: $RCSfile: gdcmHeader.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:28 $
- Version: $Revision: 1.222 $
+ Date: $Date: 2005/01/07 16:26:13 $
+ Version: $Revision: 1.223 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
std::ios::out | std::ios::binary);
if (*fp == NULL)
{
- dbg.Verbose(2, "Failed to open (write) File: " , fileName.c_str());
+ Debug::Verbose(2, "Failed to open (write) File: " , fileName.c_str());
return false;
}
if ( strSpacing == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetXSpacing: unfound Pixel Spacing (0028,0030)");
+ Debug::Verbose(0, "Header::GetXSpacing: unfound Pixel Spacing (0028,0030)");
return 1.;
}
if ( xspacing == 0.)
{
- dbg.Verbose(0, "Header::GetXSpacing: gdcmData/CT-MONO2-8-abdo.dcm problem");
+ Debug::Verbose(0, "Header::GetXSpacing: gdcmData/CT-MONO2-8-abdo.dcm problem");
// seems to be a bug in the header ...
nbValues = sscanf( strSpacing.c_str(), "%f\\0\\%f", &yspacing, &xspacing);
assert( nbValues == 2 );
if ( strSpacing == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetYSpacing: unfound Pixel Spacing (0028,0030)");
+ Debug::Verbose(0, "Header::GetYSpacing: unfound Pixel Spacing (0028,0030)");
return 1.;
}
if ( strSpacingBSlices == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetZSpacing: unfound StrSpacingBSlices");
+ Debug::Verbose(0, "Header::GetZSpacing: unfound StrSpacingBSlices");
const std::string &strSliceThickness = GetEntryByNumber(0x0018,0x0050);
if ( strSliceThickness == GDCM_UNFOUND )
{
if( sscanf( strRescInter.c_str(), "%f", &resInter) != 1 )
{
// bug in the element 0x0028,0x1052
- dbg.Verbose(0, "Header::GetRescaleIntercept: Rescale Slope "
+ Debug::Verbose(0, "Header::GetRescaleIntercept: Rescale Slope "
"is empty");
}
}
if( sscanf( strRescSlope.c_str(), "%f", &resSlope) != 1)
{
// bug in the element 0x0028,0x1053
- dbg.Verbose(0, "Header::GetRescaleSlope: Rescale Slope is empty");
+ Debug::Verbose(0, "Header::GetRescaleSlope: Rescale Slope is empty");
}
}
if ( strImPos == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetXImagePosition: unfound Image "
+ Debug::Verbose(0, "Header::GetXImagePosition: unfound Image "
"Position Patient (0020,0032)");
strImPos = GetEntryByNumber(0x0020,0x0030); // For ACR-NEMA images
if ( strImPos == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetXImagePosition: unfound Image "
+ Debug::Verbose(0, "Header::GetXImagePosition: unfound Image "
"Position (RET) (0020,0030)");
/// \todo How to tell the caller nothing was found ?
return 0.;
if ( strImPos == GDCM_UNFOUND)
{
- dbg.Verbose(0, "Header::GetYImagePosition: unfound Image "
+ Debug::Verbose(0, "Header::GetYImagePosition: unfound Image "
"Position Patient (0020,0032)");
strImPos = GetEntryByNumber(0x0020,0x0030); // For ACR-NEMA images
if ( strImPos == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetYImagePosition: unfound Image "
+ Debug::Verbose(0, "Header::GetYImagePosition: unfound Image "
"Position (RET) (0020,0030)");
/// \todo How to tell the caller nothing was found ?
return 0.;
{
if( sscanf( strImPos.c_str(), "%f\\%f\\%f", &xImPos, &yImPos, &zImPos) != 3)
{
- dbg.Verbose(0, "Header::GetZImagePosition: wrong Image "
+ Debug::Verbose(0, "Header::GetZImagePosition: wrong Image "
"Position Patient (0020,0032)");
return 0.; // bug in the element 0x0020,0x0032
}
if( sscanf( strImPos.c_str(),
"%f\\%f\\%f", &xImPos, &yImPos, &zImPos ) != 3 )
{
- dbg.Verbose(0, "Header::GetZImagePosition: wrong Image Position (RET) (0020,0030)");
+ Debug::Verbose(0, "Header::GetZImagePosition: wrong Image Position (RET) (0020,0030)");
return 0.; // bug in the element 0x0020,0x0032
}
else
{
if( sscanf( strSliceLocation.c_str(), "%f", &zImPos) != 1)
{
- dbg.Verbose(0, "Header::GetZImagePosition: wrong Slice Location (0020,1041)");
+ Debug::Verbose(0, "Header::GetZImagePosition: wrong Slice Location (0020,1041)");
return 0.; // bug in the element 0x0020,0x1041
}
else
return zImPos;
}
}
- dbg.Verbose(0, "Header::GetZImagePosition: unfound Slice Location (0020,1041)");
+ Debug::Verbose(0, "Header::GetZImagePosition: unfound Slice Location (0020,1041)");
std::string strLocation = GetEntryByNumber(0x0020,0x0050);
if ( strLocation != GDCM_UNFOUND )
{
if( sscanf( strLocation.c_str(), "%f", &zImPos) != 1)
{
- dbg.Verbose(0, "Header::GetZImagePosition: wrong Location (0020,0050)");
+ Debug::Verbose(0, "Header::GetZImagePosition: wrong Location (0020,0050)");
return 0.; // bug in the element 0x0020,0x0050
}
else
return zImPos;
}
}
- dbg.Verbose(0, "Header::GetYImagePosition: unfound Location (0020,0050)");
+ Debug::Verbose(0, "Header::GetYImagePosition: unfound Location (0020,0050)");
return 0.; // Hopeless
}
std::string strSize = GetEntryByNumber( 0x0028, 0x0101 );
if ( strSize == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetBitsStored: this is supposed to "
+ Debug::Verbose(0, "Header::GetBitsStored: this is supposed to "
"be mandatory");
return 0; // It's supposed to be mandatory
// the caller will have to check
std::string strSize = GetEntryByNumber( 0x0028, 0x0102 );
if ( strSize == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetHighBitPosition: this is supposed "
+ Debug::Verbose(0, "Header::GetHighBitPosition: this is supposed "
"to be mandatory");
return 0;
}
std::string strSize = GetEntryByNumber( 0x0028, 0x0103 );
if ( strSize == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::IsSignedPixelData: this is supposed "
+ Debug::Verbose(0, "Header::IsSignedPixelData: this is supposed "
"to be mandatory");
return false;
}
std::string strSize = GetEntryByNumber(0x0028,0x0100);
if ( strSize == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetBitsStored: this is supposed to "
+ Debug::Verbose(0, "Header::GetBitsStored: this is supposed to "
"be mandatory");
return 0; // It's supposed to be mandatory
// the caller will have to check
const std::string& strSize = GetEntryByNumber(0x0028,0x0002);
if ( strSize == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetBitsStored: this is supposed to "
+ Debug::Verbose(0, "Header::GetBitsStored: this is supposed to "
"be mandatory");
return 1; // Well, it's supposed to be mandatory ...
// but sometimes it's missing : *we* assume Gray pixels
}
if ( PhotometricInterp == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::IsMonochrome: absent Photometric "
+ Debug::Verbose(0, "Header::IsMonochrome: absent Photometric "
"Interpretation");
}
return false;
}
if ( PhotometricInterp == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::IsPaletteColor: absent Photometric "
+ Debug::Verbose(0, "Header::IsPaletteColor: absent Photometric "
"Interpretation");
}
return false;
}
if ( PhotometricInterp == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::IsYBRFull: absent Photometric "
+ Debug::Verbose(0, "Header::IsYBRFull: absent Photometric "
"Interpretation");
}
return false;
{
return 8;
}
- dbg.Verbose(0, "Header::GetPixelSize: Unknown pixel type");
+ Debug::Verbose(0, "Header::GetPixelSize: Unknown pixel type");
return 0;
}
std::string bitsAlloc = GetEntryByNumber(0x0028, 0x0100); // Bits Allocated
if ( bitsAlloc == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetPixelType: unfound Bits Allocated");
+ Debug::Verbose(0, "Header::GetPixelType: unfound Bits Allocated");
bitsAlloc = "16";
}
if (sign == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetPixelType: unfound Pixel Representation");
+ Debug::Verbose(0, "Header::GetPixelType: unfound Pixel Representation");
bitsAlloc = "0";
}
else if ( sign == "0" )
}
if ( transfertSyntax == GDCM_UNFOUND )
{
- dbg.Verbose(0, "Header::GetTransfertSyntaxName:"
+ Debug::Verbose(0, "Header::GetTransfertSyntaxName:"
" unfound Transfert Syntax (0002,0010)");
return "Uncompressed ACR-NEMA";
}
if( sscanf( strImOriPat.c_str(), "%f\\%f\\%f\\%f\\%f\\%f",
&iop[0], &iop[1], &iop[2], &iop[3], &iop[4], &iop[5]) != 6 )
{
- dbg.Verbose(0, "Header::GetImageOrientationPatient: "
+ Debug::Verbose(0, "Header::GetImageOrientationPatient: "
"wrong Image Orientation Patient (0020,0037)");
}
}
if( sscanf( strImOriPat.c_str(), "%f\\%f\\%f\\%f\\%f\\%f",
&iop[0], &iop[1], &iop[2], &iop[3], &iop[4], &iop[5]) != 6 )
{
- dbg.Verbose(0, "Header::GetImageOrientationPatient: "
+ Debug::Verbose(0, "Header::GetImageOrientationPatient: "
"wrong Image Orientation Patient (0020,0035)");
}
}
Program: gdcm
Module: $RCSfile: gdcmPixelReadConvert.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:28 $
- Version: $Revision: 1.14 $
+ Date: $Date: 2005/01/07 16:26:13 $
+ Version: $Revision: 1.15 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
if ( numberOfReadBytes > fragmentSize )
{
- dbg.Verbose(0, "PixelReadConvert::ReadAndDecompressRLEFragment: we "
+ Debug::Verbose(0, "PixelReadConvert::ReadAndDecompressRLEFragment: we "
"read more bytes than the segment size.");
return false;
}
}
break;
default:
- dbg.Verbose( 0, "PixelReadConvert::ConvertSwapZone: SwapCode value "
+ Debug::Verbose( 0, "PixelReadConvert::ConvertSwapZone: SwapCode value "
"(16 bits) not allowed." );
}
}
}
break;
default:
- dbg.Verbose( 0, "PixelReadConvert::ConvertSwapZone: SwapCode value "
+ Debug::Verbose( 0, "PixelReadConvert::ConvertSwapZone: SwapCode value "
"(32 bits) not allowed." );
}
}
else
{
// other JPEG lossy not supported
- dbg.Error("PixelReadConvert::ReadAndDecompressJPEGFile: unknown "
+ Debug::Error("PixelReadConvert::ReadAndDecompressJPEGFile: unknown "
"jpeg lossy compression ");
return false;
}
if ( ! gdcm_read_JPEG_memory8( buffer, totalLength, Raw,
&howManyRead, &howManyWritten ) )
{
- dbg.Error(
+ Debug::Error(
"PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg8 "
);
delete [] buffer;
if ( ! gdcm_read_JPEG_memory12( buffer, totalLength, Raw,
&howManyRead, &howManyWritten ) )
{
- dbg.Error(
+ Debug::Error(
"PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg12 "
);
delete [] buffer;
if ( ! gdcm_read_JPEG_memory16( buffer, totalLength, Raw,
&howManyRead, &howManyWritten ) )
{
- dbg.Error(
+ Debug::Error(
"PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg16 "
);
delete [] buffer;
else
{
// other JPEG lossy not supported
- dbg.Error("PixelConvert::ReadAndDecompressJPEGFile: unknown "
+ Debug::Error("PixelConvert::ReadAndDecompressJPEGFile: unknown "
"jpeg lossy compression ");
delete [] buffer;
return false;
Raw+howManyWritten,
&howManyRead, &howManyWritten ) )
{
- dbg.Error("PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg8 ");
+ Debug::Error("PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg8 ");
delete [] buffer;
return false;
}
Raw+howManyWritten,
&howManyRead, &howManyWritten ) )
{
- dbg.Error("PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg12 ");
+ Debug::Error("PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg12 ");
delete [] buffer;
return false;
}
Raw+howManyWritten,
&howManyRead, &howManyWritten ) )
{
- dbg.Error("PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg16 ");
+ Debug::Error("PixelConvert::ReadAndDecompressJPEGFile: failed to read jpeg16 ");
delete [] buffer;
return false;
}
else
{
// other JPEG lossy not supported
- dbg.Error("PixelConvert::ReadAndDecompressJPEGFile: unknown "
+ Debug::Error("PixelConvert::ReadAndDecompressJPEGFile: unknown "
"jpeg lossy compression ");
delete [] buffer;
return false;
}
else
{
- dbg.Verbose(0, "PixelReadConvert::ConvertReArrangeBits: weird image");
+ Debug::Verbose(0, "PixelReadConvert::ConvertReArrangeBits: weird image");
throw FormatError( "PixelReadConvert::ConvertReArrangeBits()",
"weird image !?" );
}
//// First stage: get our hands on the Pixel Data.
if ( !fp )
{
- dbg.Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
+ Debug::Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
"unavailable file pointer." );
return false;
}
fp->seekg( PixelOffset, std::ios::beg );
if( fp->fail() || fp->eof()) //Fp->gcount() == 1
{
- dbg.Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
+ Debug::Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
"unable to find PixelOffset in file." );
return false;
}
// variable). But RawSize is the right size of the image !
if( PixelDataLength != RawSize)
{
- dbg.Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
+ Debug::Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
"Mismatch between PixelReadConvert and RawSize." );
}
if( PixelDataLength > RawSize)
if ( fp->fail() || fp->eof())//Fp->gcount() == 1
{
- dbg.Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
+ Debug::Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
"reading of Raw pixel data failed." );
return false;
}
{
if ( ! ReadAndDecompressRLEFile( fp ) )
{
- dbg.Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
+ Debug::Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
"RLE decompressor failed." );
return false;
}
// Default case concerns JPEG family
if ( ! ReadAndDecompressJPEGFile( fp ) )
{
- dbg.Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
+ Debug::Verbose( 0, "PixelReadConvert::ReadAndDecompressPixelData: "
"JPEG decompressor failed." );
return false;
}
LutRedData = (uint8_t*)header->GetEntryBinAreaByNumber( 0x0028, 0x1201 );
if ( ! LutRedData )
{
- dbg.Verbose(0, "PixelReadConvert::GrabInformationsFromHeader: "
+ Debug::Verbose(0, "PixelReadConvert::GrabInformationsFromHeader: "
"unable to read red LUT data" );
}
LutGreenData = (uint8_t*)header->GetEntryBinAreaByNumber(0x0028, 0x1202 );
if ( ! LutGreenData)
{
- dbg.Verbose(0, "PixelReadConvert::GrabInformationsFromHeader: "
+ Debug::Verbose(0, "PixelReadConvert::GrabInformationsFromHeader: "
"unable to read green LUT data" );
}
LutBlueData = (uint8_t*)header->GetEntryBinAreaByNumber( 0x0028, 0x1203 );
if ( ! LutBlueData )
{
- dbg.Verbose(0, "PixelReadConvert::GrabInformationsFromHeader: "
+ Debug::Verbose(0, "PixelReadConvert::GrabInformationsFromHeader: "
"unable to read blue LUT data" );
}
}
&lengthR, &debR, &nbitsR );
if( nbRead != 3 )
{
- dbg.Verbose(0, "PixelReadConvert::BuildLUTRGBA: wrong red LUT descriptor");
+ Debug::Verbose(0, "PixelReadConvert::BuildLUTRGBA: wrong red LUT descriptor");
}
int lengthG; // Green LUT length in Bytes
&lengthG, &debG, &nbitsG );
if( nbRead != 3 )
{
- dbg.Verbose(0, "PixelReadConvert::BuildLUTRGBA: wrong green LUT descriptor");
+ Debug::Verbose(0, "PixelReadConvert::BuildLUTRGBA: wrong green LUT descriptor");
}
int lengthB; // Blue LUT length in Bytes
&lengthB, &debB, &nbitsB );
if( nbRead != 3 )
{
- dbg.Verbose(0, "PixelReadConvert::BuildLUTRGBA: wrong blue LUT descriptor");
+ Debug::Verbose(0, "PixelReadConvert::BuildLUTRGBA: wrong blue LUT descriptor");
}
////////////////////////////////////////////////////////
}
else
{
- dbg.Verbose(0, "PixelReadConvert::Print: set as RLE file "
+ Debug::Verbose(0, "PixelReadConvert::Print: set as RLE file "
"but NO RLEinfo present.");
}
}
}
else
{
- dbg.Verbose(0, "PixelReadConvert::Print: set as JPEG file "
+ Debug::Verbose(0, "PixelReadConvert::Print: set as JPEG file "
"but NO JPEGinfo present.");
}
}
Program: gdcm
Module: $RCSfile: gdcmSQItem.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:28 $
- Version: $Revision: 1.45 $
+ Date: $Date: 2005/01/07 16:26:13 $
+ Version: $Revision: 1.46 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
if( *it == entryToRemove)
{
DocEntries.erase(it);
- dbg.Verbose(0, "SQItem::RemoveEntry: one element erased.");
+ Debug::Verbose(0, "SQItem::RemoveEntry: one element erased.");
delete entryToRemove;
return true;
}
}
- dbg.Verbose(0, "SQItem::RemoveEntry: value not present ");
+ Debug::Verbose(0, "SQItem::RemoveEntry: value not present ");
return false ;
}
if( *it == entryToRemove)
{
DocEntries.erase(it);
- dbg.Verbose(0, "SQItem::RemoveEntry: one element erased.");
+ Debug::Verbose(0, "SQItem::RemoveEntry: one element erased.");
return true;
}
}
- dbg.Verbose(0, "SQItem::RemoveEntry: value not present ");
+ Debug::Verbose(0, "SQItem::RemoveEntry: value not present ");
return false ;
}
Program: gdcm
Module: $RCSfile: gdcmTS.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:28 $
- Version: $Revision: 1.30 $
+ Date: $Date: 2005/01/07 16:26:13 $
+ Version: $Revision: 1.31 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
std::ifstream from(filename.c_str());
if( !from )
{
- dbg.Verbose(2, "TS::TS: can't open dictionary", filename.c_str());
+ Debug::Verbose(2, "TS::TS: can't open dictionary", filename.c_str());
FillDefaultTSDict( TsMap );
}
else
Program: gdcm
Module: $RCSfile: gdcmVR.cxx,v $
Language: C++
- Date: $Date: 2005/01/06 20:03:28 $
- Version: $Revision: 1.27 $
+ Date: $Date: 2005/01/07 16:26:13 $
+ Version: $Revision: 1.28 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
std::ifstream from(filename.c_str());
if(!from)
{
- dbg.Verbose(2, "VR::VR: can't open dictionary", filename.c_str());
+ Debug::Verbose(2, "VR::VR: can't open dictionary", filename.c_str());
FillDefaultVRDict(vr);
}
else