X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=Example%2FTestFromScratch.cxx;h=e9760b86cc997558a3f98b031c05b72e0af57d64;hb=d00680e05d899f27a8f3a739d1af55e318ae50f1;hp=228c52a49892ca761ce82c78d85d960770fc858b;hpb=0457dfff93b771bf63a8bf3378ac535217dbdad3;p=gdcm.git diff --git a/Example/TestFromScratch.cxx b/Example/TestFromScratch.cxx index 228c52a4..e9760b86 100644 --- a/Example/TestFromScratch.cxx +++ b/Example/TestFromScratch.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: TestFromScratch.cxx,v $ Language: C++ - Date: $Date: 2004/12/10 17:10:22 $ - Version: $Revision: 1.3 $ + Date: $Date: 2005/01/14 11:28:28 $ + 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 @@ -36,7 +36,8 @@ int main(int argc, char *argv[]) } // Doesn't seems to do anything: - dbg.SetDebug(-1); + gdcm::Debug::SetDebugOn(); + // Doesn't link properly: //gdcm::Debug::GetReference().SetDebug(1); @@ -53,18 +54,17 @@ int main(int argc, char *argv[]) // Hopefully default to something gdcm::Header *h2 = new gdcm::Header(); - h1->Initialize(); - gdcm::DocEntry* d = h1->GetNextEntry(); - // Copy of the header content + h1->InitTraversal(); + gdcm::DocEntry* d = h1->GetNextEntry(); while(d) { if ( gdcm::ValEntry* v = dynamic_cast(d) ) { // Do not bother with field from private dict - if( v->GetName() != "unkn" ) + if( v->GetName() != "gdcm::Unknown" ) { - h2->ReplaceOrCreateByNumber( + h2->ReplaceOrCreate( v->GetValue(), v->GetGroup(), v->GetElement(),