dcmpstat/include/dcmtk/dcmpstat/dvpspl.h

00001 /*
00002  *
00003  *  Copyright (C) 1998-2010, OFFIS e.V.
00004  *  All rights reserved.  See COPYRIGHT file for details.
00005  *
00006  *  This software and supporting documentation were developed by
00007  *
00008  *    OFFIS e.V.
00009  *    R&D Division Health
00010  *    Escherweg 2
00011  *    D-26121 Oldenburg, Germany
00012  *
00013  *
00014  *  Module: dcmpstat
00015  *
00016  *  Author: Marco Eichelberg
00017  *
00018  *  Purpose:
00019  *    classes: DVPSPresentationLUT
00020  *
00021  *  Last Update:      $Author: joergr $
00022  *  Update Date:      $Date: 2010-10-14 13:16:36 $
00023  *  CVS/RCS Revision: $Revision: 1.16 $
00024  *  Status:           $State: Exp $
00025  *
00026  *  CVS/RCS Log at end of file
00027  *
00028  */
00029 
00030 #ifndef DVPSPL_H
00031 #define DVPSPL_H
00032 
00033 #include "dcmtk/config/osconfig.h"    /* make sure OS specific configuration is included first */
00034 #include "dcmtk/dcmpstat/dvpstyp.h"     /* for enum types */
00035 #include "dcmtk/dcmdata/dcvrus.h"
00036 #include "dcmtk/dcmdata/dcvrui.h"
00037 #include "dcmtk/dcmdata/dcvrlo.h"
00038 
00039 struct T_DIMSE_Message;
00040 
00041 class DicomImage;
00042 class DiLookupTable;
00043 class DcmDataset;
00044 
00048 class DVPSPresentationLUT
00049 {
00050 public:
00052   DVPSPresentationLUT();
00053   
00055   DVPSPresentationLUT(const DVPSPresentationLUT& copy);
00056 
00061   DVPSPresentationLUT *clone() { return new DVPSPresentationLUT(*this); }
00062 
00064   virtual ~DVPSPresentationLUT();
00065 
00070   void clear();
00071 
00082   OFCondition read(DcmItem &dset, OFBool withSOPInstance);
00083   
00091   OFCondition write(DcmItem &dset, OFBool withSOPInstance);
00092 
00096   OFBool isInverse();
00097 
00101   DVPSPresentationLUTType getType() { return presentationLUT; }
00102 
00109   DVPSPrintPresentationLUTAlignment getAlignment();
00110   
00116   OFBool haveTable();
00117 
00125   const char *getCurrentExplanation();
00126 
00131   const char *getLUTExplanation();
00132 
00137   const char *getSOPInstanceUID();
00138 
00148   OFCondition setLUT(
00149     DcmUnsignedShort& lutDescriptor,
00150     DcmUnsignedShort& lutData,
00151     DcmLongString& lutExplanation);
00152 
00159   OFCondition setType(DVPSPresentationLUTType newType);
00160 
00164   OFCondition invert();
00165 
00174   OFBool activate(DicomImage *image, OFBool printLUT = OFFalse);
00175 
00181   OFBool activateInverseLUT(DicomImage *image);
00182 
00187   DiLookupTable *createDiLookupTable();
00188   
00194   OFBool compareDiLookupTable(DiLookupTable *lut);
00195 
00200   OFCondition setSOPInstanceUID(const char *value);
00201   
00206   OFBool isLegalPrintPresentationLUT();
00207   
00213   OFBool matchesImageDepth(OFBool is12bit);
00214 
00229   OFBool printSCPCreate(
00230     DcmDataset *rqDataset, 
00231     T_DIMSE_Message& rsp, 
00232     DcmDataset *& rspDataset, 
00233     OFBool matchRequired,
00234     OFBool supports12Bit);
00235 
00236 private:
00238   DVPSPresentationLUT& operator=(const DVPSPresentationLUT&);
00239     
00241   DVPSPresentationLUTType  presentationLUT;
00243   DcmUnsignedShort         presentationLUTDescriptor;
00245   DcmLongString            presentationLUTExplanation;
00247   DcmUnsignedShort         presentationLUTData;
00248 
00250   DcmUniqueIdentifier      sOPInstanceUID;
00251 
00252 };
00253 
00254 #endif
00255 
00256 /*
00257  *  $Log: dvpspl.h,v $
00258  *  Revision 1.16  2010-10-14 13:16:36  joergr
00259  *  Updated copyright header. Added reference to COPYRIGHT file.
00260  *
00261  *  Revision 1.15  2010-10-07 14:31:36  joergr
00262  *  Removed leading underscore characters from preprocessor symbols (reserved).
00263  *
00264  *  Revision 1.14  2009-11-24 14:12:57  uli
00265  *  Switched to logging mechanism provided by the "new" oflog module.
00266  *
00267  *  Revision 1.13  2009-09-30 10:42:38  uli
00268  *  Make dcmpstat's include headers self-sufficient by including all
00269  *  needed headers directly and stop using dctk.h
00270  *
00271  *  Revision 1.12  2005-12-08 16:03:55  meichel
00272  *  Changed include path schema for all DCMTK header files
00273  *
00274  *  Revision 1.11  2003/08/27 14:59:09  meichel
00275  *  Moved all methods of class DVPSPresentationLUT that depend on module dcmimgle
00276  *    into a separate implementation file
00277  *
00278  *  Revision 1.10  2001/09/26 15:36:14  meichel
00279  *  Adapted dcmpstat to class OFCondition
00280  *
00281  *  Revision 1.9  2001/06/01 15:50:19  meichel
00282  *  Updated copyright header
00283  *
00284  *  Revision 1.8  2000/06/09 10:14:11  joergr
00285  *  Added support for rendering inverse presentation LUT into print bitmaps.
00286  *
00287  *  Revision 1.7  2000/06/07 14:20:18  joergr
00288  *  Added support for rendering "hardcopy" and "softcopy" presentation LUTs.
00289  *
00290  *  Revision 1.6  2000/06/02 16:00:49  meichel
00291  *  Adapted all dcmpstat classes to use OFConsole for log and error output
00292  *
00293  *  Revision 1.5  2000/05/31 12:56:39  meichel
00294  *  Added initial Print SCP support
00295  *
00296  *  Revision 1.4  2000/03/08 16:28:54  meichel
00297  *  Updated copyright header.
00298  *
00299  *  Revision 1.3  1999/10/07 17:21:49  meichel
00300  *  Reworked management of Presentation LUTs in order to create tighter
00301  *    coupling between Softcopy and Print.
00302  *
00303  *  Revision 1.2  1999/09/24 15:23:46  meichel
00304  *  Print spooler (dcmprtsv) now logs diagnostic messages in log files
00305  *    when operating in spool mode.
00306  *
00307  *  Revision 1.1  1999/07/30 13:34:49  meichel
00308  *  Added new classes managing Stored Print objects
00309  *
00310  *
00311  */


Generated on 6 Jan 2011 for OFFIS DCMTK Version 3.6.0 by Doxygen 1.5.1