00001 /* 00002 * 00003 * Copyright (C) 1998-2005, OFFIS 00004 * 00005 * This software and supporting documentation were developed by 00006 * 00007 * Kuratorium OFFIS e.V. 00008 * Healthcare Information and Communication Systems 00009 * Escherweg 2 00010 * D-26121 Oldenburg, Germany 00011 * 00012 * THIS SOFTWARE IS MADE AVAILABLE, AS IS, AND OFFIS MAKES NO WARRANTY 00013 * REGARDING THE SOFTWARE, ITS PERFORMANCE, ITS MERCHANTABILITY OR 00014 * FITNESS FOR ANY PARTICULAR USE, FREEDOM FROM ANY COMPUTER DISEASES OR 00015 * ITS CONFORMITY TO ANY SPECIFICATION. THE ENTIRE RISK AS TO QUALITY AND 00016 * PERFORMANCE OF THE SOFTWARE IS WITH THE USER. 00017 * 00018 * Module: dcmpstat 00019 * 00020 * Author: Marco Eichelberg 00021 * 00022 * Purpose: 00023 * classes: DVPSGraphicLayer_PList 00024 * 00025 * Last Update: $Author: meichel $ 00026 * Update Date: $Date: 2005/12/08 16:03:46 $ 00027 * CVS/RCS Revision: $Revision: 1.11 $ 00028 * Status: $State: Exp $ 00029 * 00030 * CVS/RCS Log at end of file 00031 * 00032 */ 00033 00034 #ifndef __DVPSGLL_H__ 00035 #define __DVPSGLL_H__ 00036 00037 #include "dcmtk/config/osconfig.h" /* make sure OS specific configuration is included first */ 00038 #include "dcmtk/ofstd/oflist.h" 00039 #include "dcmtk/dcmdata/dctk.h" 00040 00041 class DVPSGraphicLayer; 00042 class DVPSOverlayCurveActivationLayer_PList; 00043 class DVPSGraphicAnnotation_PList; 00044 00050 class DVPSGraphicLayer_PList 00051 { 00052 public: 00054 DVPSGraphicLayer_PList(); 00055 00057 DVPSGraphicLayer_PList(const DVPSGraphicLayer_PList& copy); 00058 00063 DVPSGraphicLayer_PList *clone() { return new DVPSGraphicLayer_PList(*this); } 00064 00066 virtual ~DVPSGraphicLayer_PList(); 00067 00075 OFCondition read(DcmItem &dset); 00076 00083 OFCondition write(DcmItem &dset); 00084 00089 void clear(); 00090 00100 OFCondition addGraphicLayer(const char *gLayer, 00101 const Sint32 gLayerOrder, 00102 const char *gLayerDescription=NULL); 00103 00113 OFCondition addGraphicLayer( 00114 const char *gLayer, 00115 const char *gLayerDescription=NULL); 00116 00120 size_t size() const { return list_.size(); } 00121 00132 void sortGraphicLayers(Sint32 lowestLayer=1); 00133 00140 const char *getGraphicLayerName(size_t idx); 00141 00148 size_t getGraphicLayerIndex(const char *name); 00149 00156 const char *getGraphicLayerDescription(size_t idx); 00157 00162 OFBool haveGraphicLayerRecommendedDisplayValue(size_t idx); 00163 00172 OFCondition getGraphicLayerRecommendedDisplayValueGray(size_t idx, Uint16& gray); 00173 00183 OFCondition getGraphicLayerRecommendedDisplayValueRGB(size_t idx, Uint16& r, Uint16& g, Uint16& b); 00184 00192 OFCondition setGraphicLayerRecommendedDisplayValueGray(size_t idx, Uint16 gray); 00193 00203 OFCondition setGraphicLayerRecommendedDisplayValueRGB(size_t idx, Uint16 r, Uint16 g, Uint16 b); 00204 00209 void removeGraphicLayerRecommendedDisplayValue(size_t idx, OFBool rgb, OFBool monochrome); 00210 00217 OFCondition setGraphicLayerName(size_t idx, const char *name); 00218 00224 OFCondition setGraphicLayerDescription(size_t idx, const char *descr); 00225 00235 OFCondition toFrontGraphicLayer(size_t idx); 00236 00245 OFCondition toBackGraphicLayer(size_t idx); 00246 00254 OFCondition exchangeGraphicLayers(size_t idx1, size_t idx2); 00255 00260 OFCondition removeGraphicLayer(size_t idx); 00261 00266 void cleanupLayers( 00267 DVPSOverlayCurveActivationLayer_PList& activations, 00268 DVPSGraphicAnnotation_PList& annotations); 00269 00275 void setLog(OFConsole *stream, OFBool verbMode, OFBool dbgMode); 00276 00277 private: 00278 00280 DVPSGraphicLayer_PList& operator=(const DVPSGraphicLayer_PList&); 00281 00287 DVPSGraphicLayer *getGraphicLayer(size_t idx); 00288 00291 OFList<DVPSGraphicLayer *> list_; 00292 00295 OFConsole *logstream; 00296 00299 OFBool verboseMode; 00300 00303 OFBool debugMode; 00304 }; 00305 00306 #endif 00307 00308 /* 00309 * $Log: dvpsgll.h,v $ 00310 * Revision 1.11 2005/12/08 16:03:46 meichel 00311 * Changed include path schema for all DCMTK header files 00312 * 00313 * Revision 1.10 2003/06/04 10:18:06 meichel 00314 * Replaced private inheritance from template with aggregation 00315 * 00316 * Revision 1.9 2001/09/26 15:36:11 meichel 00317 * Adapted dcmpstat to class OFCondition 00318 * 00319 * Revision 1.8 2001/06/01 15:50:16 meichel 00320 * Updated copyright header 00321 * 00322 * Revision 1.7 2000/06/02 16:00:46 meichel 00323 * Adapted all dcmpstat classes to use OFConsole for log and error output 00324 * 00325 * Revision 1.6 2000/03/08 16:28:52 meichel 00326 * Updated copyright header. 00327 * 00328 * Revision 1.5 1999/07/30 13:34:46 meichel 00329 * Added new classes managing Stored Print objects 00330 * 00331 * Revision 1.4 1999/07/22 16:39:08 meichel 00332 * Adapted dcmpstat data structures and API to supplement 33 letter ballot text. 00333 * 00334 * Revision 1.3 1999/02/09 15:58:55 meichel 00335 * Implemented bitmap shutter activation amd method for 00336 * exchanging graphic layers. 00337 * 00338 * Revision 1.2 1998/12/14 16:10:29 meichel 00339 * Implemented Presentation State interface for graphic layers, 00340 * text and graphic annotations, presentation LUTs. 00341 * 00342 * Revision 1.1 1998/11/27 14:50:28 meichel 00343 * Initial Release. 00344 * 00345 * 00346 */ 00347