]> Creatis software - gdcm.git/commitdiff
Typo, comments, doxygenation
authorjpr <jpr>
Fri, 11 Feb 2005 15:22:18 +0000 (15:22 +0000)
committerjpr <jpr>
Fri, 11 Feb 2005 15:22:18 +0000 (15:22 +0000)
14 files changed:
src/gdcmCommon.h
src/gdcmDebug.h
src/gdcmDicomDir.h
src/gdcmDicomDirElement.cxx
src/gdcmDicomDirElement.h
src/gdcmDict.cxx
src/gdcmDocEntrySet.cxx
src/gdcmGlobal.cxx
src/gdcmJpegLS.cxx
src/gdcmSeqEntry.cxx
src/gdcmSeqEntry.h
src/gdcmTS.cxx
src/gdcmUtil.cxx
src/gdcmVR.cxx

index 094ad90cc15b971aafce0a489f877a7630967927..0a115ec234c71e9ad4683d04e6b7377cee1c6b42 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmCommon.h,v $
   Language:  C++
-  Date:      $Date: 2005/02/07 19:17:27 $
-  Version:   $Revision: 1.61 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.62 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -79,6 +79,7 @@ typedef  unsigned int        uint32_t;
 
 #include <string>
 
+/// \brief namespace for Grass root DiCoM
 namespace gdcm
 {
 
@@ -136,6 +137,7 @@ enum FileType {
    ACR_LIBIDO
 };
 
+/// \brief type of the elements composing a DICOMDIR (for internal use only)
 enum DicomDirType {
    DD_UNKNOWN = 0,
    DD_META,
index 1b6d80ce08ae433cf641c0c16b8080290ac2ee53..8bb1aa465458fcc24776046da7b181bdca5bc23d 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDebug.h,v $
   Language:  C++
-  Date:      $Date: 2005/02/09 21:37:45 $
-  Version:   $Revision: 1.31 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.32 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -47,8 +47,8 @@ public:
    Debug();
    ~Debug();
 
-   /// This is a global flag that controls whether any debug, warning
-   /// messages are displayed.
+   /// \brief This is a global flag that controls whether any debug, warning
+   ///        messages are displayed.
    static void SetDebugFlag (bool flag);
    static bool GetDebugFlag ();
    /// \brief Sets the Debug Flag to true
@@ -56,8 +56,8 @@ public:
    /// \brief Sets the Debug Flag to false
    static void DebugOff () { SetDebugFlag(false); };
 
-   /// This is a global flag that controls if debug are redirected
-   /// to a file or not
+   /// \brief This is a global flag that controls if debug are redirected
+   ///        to a file or not
    static void SetDebugToFile (bool flag);
    static bool GetDebugToFile ();
    /// \brief Next debug messages will be sent in the debug file
index 0e7cdcf67d04c1c03bf95492addca61a5f86648a..7a5af4303ca529569e1ec02a675d36c3cccb9d34 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDicomDir.h,v $
   Language:  C++
-  Date:      $Date: 2005/02/07 14:48:34 $
-  Version:   $Revision: 1.55 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.56 $
   
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -64,7 +64,7 @@ public:
    // Meta
    DicomDirMeta    *NewMeta();
    /// Returns a pointer to the DicomDirMeta for this DICOMDIR. 
-   DicomDirMetaGetMeta() { return MetaElems; };
+   DicomDirMeta *GetMeta() { return MetaElems; };
 
    // Patients
    DicomDirPatient *NewPatient();
@@ -131,14 +131,14 @@ private:
    void SetElements(std::string const &path, VectDocument const &list);
    void SetElement (std::string const &path, DicomDirType type,
                     Document *header);
-   void MoveSQItem(DocEntrySet *dst,DocEntrySet *src);
+   void MoveSQItem(DocEntrySet *dst, DocEntrySet *src);
 
    static bool HeaderLessThan(Document *header1, Document *header2);
    
 // Variables
 
    /// Pointer on *the* DicomDirObject 'DicomDirMeta Elements'
-   DicomDirMetaMetaElems;
+   DicomDirMeta *MetaElems;
 
    /// Chained list of DicomDirPatient (to be exploited hierarchicaly) 
    ListDicomDirPatient Patients;
index 6850027251346654cb9c29ca76e5cd6d3f72bb6f..b71f0f8ff519e645e0530770f46dc6b5c34d858b 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDicomDirElement.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/07 14:48:34 $
-  Version:   $Revision: 1.35 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.36 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -27,6 +27,8 @@
 namespace gdcm 
 {
 //-----------------------------------------------------------------------------
+/// \brief auto generate function, to fill up the default elements for 
+///        a DICOMDIR, if relevant file is not found on user's disk
 void FillDefaultDIRDict(DicomDirElement *dde);
 
 //-----------------------------------------------------------------------------
index a214c47e622c29f4b2014ff5feb1fca7ba4f4a6f..4540ce16d26abec5aae39ac882d0231345a16f78 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDicomDirElement.h,v $
   Language:  C++
-  Date:      $Date: 2005/02/07 14:48:34 $
-  Version:   $Revision: 1.27 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  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
@@ -35,6 +35,30 @@ typedef std::list<Element> ListDicomDirStudyElem;
 typedef std::list<Element> ListDicomDirSerieElem;
 typedef std::list<Element> ListDicomDirImageElem;
 
+// For future use (Full DICOMDIR)
+/*
+typedef std::list<Element> ListDicomDirVisit;
+typedef std::list<Element> ListDicomDirResult;
+typedef std::list<Element> ListDicomDirStudyComponent;
+
+typedef std::list<Element> ListDicomDirOverlay;
+typedef std::list<Element> ListDicomDirModalityLut;
+typedef std::list<Element> ListDicomDirModalityLut;
+typedef std::list<Element> ListDicomDirCurve;
+typedef std::list<Element> ListDicomDirStoredPrint;
+typedef std::list<Element> ListDicomDirRtDose;
+typedef std::list<Element> ListDicomDirRtStructureSet;
+typedef std::list<Element> ListDicomDirRtPlan;
+typedef std::list<Element> ListDicomDirRtTreatRecord;
+typedef std::list<Element> ListDicomDirPresentation;
+typedef std::list<Element> ListDicomDirSrDocument;
+typedef std::list<Element> ListDicomDirKeyObjectDoc;
+typedef std::list<Element> ListDicomDirSpectroscopy;
+typedef std::list<Element> ListDicomDirRawData;
+typedef std::list<Element> ListDicomDirRegistration;
+typedef std::list<Element> ListDicomDirFiducial;
+*/
+
 //-----------------------------------------------------------------------------
 /**
  * \brief   Represents elements contained in a DicomDir class
index 21df55adec56ab565ebd62b530c4921e08817b8e..fc7c07f2d69dae556afb8222e035b278293a662c 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDict.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:08 $
-  Version:   $Revision: 1.73 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.74 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -27,6 +27,8 @@
 namespace gdcm 
 {
 //-----------------------------------------------------------------------------
+/// \brief auto generate function, to fill up the Dicom Dictionnary,
+///       if relevant file is not found on user's disk
 void FillDefaultDataDict(Dict *d);
 
 //-----------------------------------------------------------------------------
index ceba6d0747a1f6783269b7e8999c00f717eeb569..2f0de0e39d730c292ade0fa7c22ee7fdb6c4c0ee 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmDocEntrySet.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:08 $
-  Version:   $Revision: 1.54 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.55 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -372,7 +372,7 @@ BinEntry *DocEntrySet::InsertBinEntry(uint8_t *binArea, int lgth,
 }  
 
 /**
- * \brief   Modifies the value of a given Header Entry (Dicom Element)
+ * \brief   Modifies the value of a given Doc Entry (Dicom Element)
  *          when it exists. Creates it when unexistant.
  * @param   group   Group number of the Entry 
  * @param   elem  Element number of the Entry
@@ -382,7 +382,7 @@ BinEntry *DocEntrySet::InsertBinEntry(uint8_t *binArea, int lgth,
 SeqEntry *DocEntrySet::InsertSeqEntry(uint16_t group, uint16_t elem)
 {
    SeqEntry *seqEntry = 0;
-   DocEntry *currentEntry = GetDocEntry( group, elem);
+   DocEntry *currentEntry = GetDocEntry( group, elem );
 
    // Verify the currentEntry
    if( currentEntry )
@@ -391,10 +391,9 @@ SeqEntry *DocEntrySet::InsertSeqEntry(uint16_t group, uint16_t elem)
 
       // Verify the VR
       if( seqEntry )
-         if( seqEntry->GetVR()!="SQ" )
-            seqEntry = NULL;
+         seqEntry = NULL;
 
-      // if currentEntry doesn't correspond to the requested valEntry
+      // if currentEntry doesn't correspond to the requested seqEntry
       if( !seqEntry )
       {
          if (!RemoveEntry(currentEntry))
@@ -418,8 +417,13 @@ SeqEntry *DocEntrySet::InsertSeqEntry(uint16_t group, uint16_t elem)
          return NULL;
       }
    }
+
+   // TODO : Find a trick to insert a SequenceDelimitationItem 
+   //       in the SeqEntry, at the end.
    return seqEntry;
 } 
+
+
  
 /**
  * \brief   Checks if a given Dicom Element exists within the H table
index fe6840c72fb9f841851ab4b7558d4503df450c95..1a31c1c60ee27c4054f766ed7e345939c75a2797 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmGlobal.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/07 14:48:34 $
-  Version:   $Revision: 1.20 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.21 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
 namespace gdcm 
 {
 //-----------------------------------------------------------------------------
-// Those global string that are return by reference everywhere in gdcm code
-// used to be in gdcmCommon.h but due to a 'bug' in gcc/MacOSX
-// you cannot have static initialization in a multithreaded environment
-// since there is a lazy construction everything got skrew up somehow
-// Therefore the actual initialization is done in a cxx file (avoid
-// duplicated symbol), and an extern is used in gdcmCommon.h
+/// \brief Those global string that are return by reference everywhere in 
+/// gdcm code used to be in gdcmCommon.h but due to a 'bug' in gcc/MacOSX
+/// you cannot have static initialization in a multithreaded environment
+/// since there is a lazy construction everything got skrew up somehow
+/// Therefore the actual initialization is done in a cxx file (avoid
+/// duplicated symbol), and an extern is used in gdcmCommon.h
 const std::string GDCM_UNKNOWN   = "gdcm::Unknown";
 const std::string GDCM_UNFOUND   = "gdcm::Unfound";
 const std::string GDCM_BINLOADED = "gdcm::Binary data loaded";
index a850d3593b4f4613df554bf991bd8c0c6569c5a4..200d20966a95252110d3758bbebaf3e604de5f6b 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmJpegLS.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:09 $
-  Version:   $Revision: 1.3 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.4 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -34,8 +34,10 @@ namespace gdcm
  * @warning : not yet made
  */
 
-bool gdcm_read_JPEGLS_file (std::ifstream* , void* )
+bool gdcm_read_JPEGLS_file (std::ifstream *fp, void *image_buffer)
 {
+   (void)fp;
+   (void)image_buffer;
    gdcmWarningMacro( "Sorry JPEG-LS File not yet taken into account" );
    return false;
 }
index 11033cdbab0e9bb284ac21db73f06a5354710864..815031811b443b9c86dc3c2ad1d7ac1cfb3fc919 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmSeqEntry.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:09 $
-  Version:   $Revision: 1.54 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.55 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -18,6 +18,7 @@
 
 #include "gdcmSeqEntry.h"
 #include "gdcmSQItem.h"
+#include "gdcmValEntry.h"
 #include "gdcmTS.h"
 #include "gdcmGlobal.h"
 #include "gdcmUtil.h"
@@ -46,7 +47,7 @@ SeqEntry::SeqEntry( DictEntry *e )
 }
 
 /**
- * \brief   Constructor from a given SeqEntry
+ * \brief   Constructor from a given DocEntry
  * @param   e Pointer to existing Doc entry
  * @param   depth depth level of the current Seq entry
  */
index 621c0614fd5ef87d18ffc082eb1069ab8c3752d1..7804b6cfe96f777aef64d863fbf38cb03e084fbf 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmSeqEntry.h,v $
   Language:  C++
-  Date:      $Date: 2005/02/04 14:49:01 $
-  Version:   $Revision: 1.33 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  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
@@ -59,6 +59,7 @@ public:
 
    /// Sets the Sequence Delimitation Item
    void SetDelimitationItem(DocEntry *e) { SeqTerm = e;   }
+
    /// Gets the Sequence Delimitation Item
    DocEntry *GetDelimitationItem()       { return SeqTerm;}
 
index 190c151e03f7c451758cbbc73870df506f756a98..598c92dbfdd97e2a05102cbf6052db878abc4056 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmTS.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:09 $
-  Version:   $Revision: 1.42 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.43 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
 // TODO
 // a lot of troubles expected with TS : 1.2.840.113619.5.2
 // Implicit VR - Big Endian
-// see : http://www.gemedicalsystemseurope.com/euen/it_solutions/pdf/lsqxi_rev2.pdf
+// http://www.gemedicalsystemseurope.com/euen/it_solutions/pdf/lsqxi_rev2.pdf
 // 
 
 namespace gdcm 
 {
 //-----------------------------------------------------------------------------
+/// \brief Transfer Syntaxes gdcm deals with (internal use onky)
 static const char *SpecialStrings[] =  {
   // Implicit VR Little Endian
   "1.2.840.10008.1.2",
@@ -57,7 +58,8 @@ static const char *SpecialStrings[] =  {
   "1.2.840.10008.1.2.4.55",
   // JPEG Lossless, Non-Hierarchical (Process 14)
   "1.2.840.10008.1.2.4.57",
-  // JPEG Lossless, Hierarchical, First-Order Prediction (Process 14, [Selection Value 1])
+  // JPEG Lossless, Hierarchical, First-Order Prediction (Process 14,
+  //                                                       [Selection Value 1])
   "1.2.840.10008.1.2.4.70",
   // JPEG-LS Lossless Image Compression
   "1.2.840.10008.1.2.4.80",
@@ -74,6 +76,8 @@ static const char *SpecialStrings[] =  {
 };
 
 //-----------------------------------------------------------------------------
+/// \brief auto generated function, to fill up the Dicom Dictionnary,
+///       if relevant file is not found on user's disk
 void FillDefaultTSDict(TSHT &ts);
 
 //-----------------------------------------------------------------------------
@@ -114,14 +118,18 @@ TS::~TS()
 
 //-----------------------------------------------------------------------------
 // Public
+
+/// \brief returns occurence number of the given key
 int TS::Count(TSKey const &key) 
 {
    return TsMap.count(key);
 }
 
+/// \brief returns the human reabable value of a Transfer Synatx string 
 TSAtr const &TS::GetValue(TSKey const &key) 
 {
-   // First thing clean up the string sometime the transfer syntax is padded with spaces
+   // First thing clean up the string 
+   // (sometime the transfer syntax is padded with spaces)
    std::string copy = key;
    while ( copy.size() && !isdigit((unsigned char)copy[copy.size()-1]) )
    {
index d51514cc332c2c742e8d6fda7df13571e68a6190..0e08e053372cc07878e79532524460cfb56208e9 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmUtil.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:09 $
-  Version:   $Revision: 1.132 $
+  Date:      $Date: 2005/02/11 15:22:18 $
+  Version:   $Revision: 1.133 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -437,7 +437,7 @@ bool Util::DicomStringEqual(const std::string &s1, const char *s2)
            OUT AsnObjectIdentifier * supportedView);
 #endif //_WIN32
 
-
+/// \brief gets current M.A.C adress (for internal use only)
 int GetMacAddrSys ( unsigned char *addr )
 {
 #ifdef _WIN32
@@ -450,8 +450,8 @@ int GetMacAddrSys ( unsigned char *addr )
 
    HANDLE PollForTrapEvent;
    AsnObjectIdentifier SupportedView;
-   UINT OID_ifEntryType[] = { 1, 3, 6, 1, 2, 1, 2, 2, 1, 3 };
-   UINT OID_ifEntryNum[] = { 1, 3, 6, 1, 2, 1, 2, 1 };
+   UINT OID_ifEntryType[]  = { 1, 3, 6, 1, 2, 1, 2, 2, 1, 3 };
+   UINT OID_ifEntryNum[]   = { 1, 3, 6, 1, 2, 1, 2, 1 };
    UINT OID_ipMACEntAddr[] = { 1, 3, 6, 1, 2, 1, 2, 2, 1, 6 };
    AsnObjectIdentifier MIB_ifMACEntAddr = {
        sizeof(OID_ipMACEntAddr) / sizeof(UINT), OID_ipMACEntAddr };
@@ -699,9 +699,9 @@ int GetMacAddrSys ( unsigned char *addr )
 }
 
 /**
- * Mini function to return the last digit from a number express in base 256
- * pre condition data contain an array of 6 unsigned char
- * post condition carry contain the last digit
+ * \brief Mini function to return the last digit from a number express in base 256
+ *        pre condition data contain an array of 6 unsigned char
+ *        post condition carry contain the last digit
  */
 inline int getlastdigit(unsigned char *data)
 {
@@ -810,7 +810,7 @@ const std::string &Util::GetRootUID()
 
 //-------------------------------------------------------------------------
 /**
- * \brief
+ * \brief class for binary write
  * @param os ostream to write to
  * @param val val
  */ 
index a1936d0eb375e4c8281a54939d7517b08c3529b3..ea98ceb8e0fbc2d5e0c93bea17151152040da665 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmVR.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/02/05 01:37:09 $
-  Version:   $Revision: 1.35 $
+  Date:      $Date: 2005/02/11 15:22:19 $
+  Version:   $Revision: 1.36 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -27,6 +27,8 @@
 namespace gdcm 
 {
 //-----------------------------------------------------------------------------
+/// \brief auto generated function, to fill up the 'Value Representation'
+///        Dictionnary, if relevant file is not found on user's disk
 void FillDefaultVRDict(VRHT &vr);
 
 //-----------------------------------------------------------------------------