X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=Example%2FReWrite.cxx;h=1aa4b8f9075f8b7d965fac783ad03d8ff120f6b3;hb=4acee42d42762de879ce2fc64324764585ed8199;hp=1a6c735b7a67d89beba9be6769a87107a88c43ea;hpb=f3cc252fad08c3e8dbc395f2ca7cabf47bf95302;p=gdcm.git diff --git a/Example/ReWrite.cxx b/Example/ReWrite.cxx index 1a6c735b..1aa4b8f9 100644 --- a/Example/ReWrite.cxx +++ b/Example/ReWrite.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: ReWrite.cxx,v $ Language: C++ - Date: $Date: 2005/08/30 15:13:05 $ - Version: $Revision: 1.11 $ + Date: $Date: 2005/10/18 08:35:43 $ + Version: $Revision: 1.13 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -150,7 +150,7 @@ int main(int argc, char *argv[]) << " SampleserPixel=" << sPP << " PlanarConfiguration=" << planarConfig << " PhotometricInterpretation=" - << f->GetEntryValue(0x0028,0x0004) + << f->GetEntryString(0x0028,0x0004) << std::endl; int numberOfScalarComponents=f->GetNumberOfScalarComponents(); @@ -196,6 +196,33 @@ int main(int argc, char *argv[]) std::cout << "WriteRaw" << std::endl; fh->WriteRawData(outputFileName); break; + + // Just for fun : + // Write a 'Videon inverse' version of the file/ + // *Not* described, on purpose, in the USAGE + + case 'V' : + case 'v' : + + if ( fh->GetFile()->GetBitsAllocated() == 8) + { + std::cout << "videoinv for 8 bits" << std::endl; + for (int i=0; iWriteDcmExplVR(outputFileName); + break; } delete f;