- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

# C:/AngioLocalizeNoAuto/MevisLabNoAutoReg/STUMevisApp/General/Sources/ML/STUImportRTStructure/STUImportRTStructure.h

    00001 /*
    00002 * Copyright (c) 2009 Stanford University, School of Medicine All rights reserved.
    00003 *
    00004 * STANFORD ACADEMIC SOFTWARE LICENSE AGREEMENT
    00005 * FOR AngioLocalize SOURCE CODE:
    00006 *
    00007 * 1.  This is a legal agreement between you, RECIPIENT, and STANFORD UNIVERSITY.
    00008 *       By accepting, receiving, and using AngioLocalize.including any accompanying information, materials or
    00009 *       manuals (Program), you are agreeing to be bound by the terms of this Agreement.
    00010 *       If you do not agree to the terms of this Agreement, promptly return the Program to the STANFORD.
    00011
    00012 * 2.  STANFORD grants to RECIPIENT a royalty-free, nonexclusive, and nontransferable license to use the Program
    00013 *       and accompanying source code furnished hereunder, upon the terms and conditions set out below.
    00014 *       documentation and/or other materials provided with the distribution.
    00015 * 3.  RECIPIENT acknowledges that the Program is a research tool still in the development stage and that
    00016 *       it is being supplied as is, without any accompanying services, support or improvements from STANFORD.
    00017 * 4.  RECIPIENT agrees to use the Program solely for internal non-commercial purposes.
    00018 * 5.  RECIPIENT may create derivatives and further transfer the Program under the following terms and conditions:
    00019 *        A) Recipient agrees to not commercially exploit the Program and agrees all uses will be for non-commercial purposes; and,
    00020 *        B) Recipient may not mark any derivatives with the title of Program and may not to use iPad mark for any derivatives; and,
    00021 *        C) Recipient agrees to mark and acknowledge all derivatives as follows: "This is a derivative work based on AngioLocalize:
    00022 *           Frameless AVM localization with 2D Digital Subtraction Angiography (DSA) and 3D Rotational Angiography (DRA) Images developed
    00023 *           by Dimitre Hristov, Lina Liu.
    00024 *        D) Recipient agrees to make all improvements, enhancements and derivatives available under
    00025 *           similar terms and conditions to the research community.
    00026 * 6.   RECIPIENT warrants that RECIPIENT will not remove or export any part of the software or Program from the United
    00027 *       States except in full compliance with all United States and other applicable laws and regulations.
    00028 * 7.  RECIPIENT will use the Program in compliance with all applicable laws, policies and regulations including, but not
    00029 *       limited to, any approvals, informed consent and patient confidentiality principles.
    00030 * 8.   RECIPIENT will indemnify, hold harmless, and defend Stanford against any claim of any kind arising out of or
    00031 *       related to the exercise of any rights granted under this Agreement or the breach of this Agreement by RECIPIENT.
    00032 * 9.  Title and copyright to the Program and any associated documentation shall at all times remain with STANFORD,
    00033 *       and RECIPIENT agrees to preserve same.
    00034 */
    00035 //----------------------------------------------------------------------------------
    00037
    00044 //----------------------------------------------------------------------------------
    00045
    00046
    00047 #ifndef __STUImportRTStructure_H
    00048 #define __STUImportRTStructure_H
    00049
    00050
    00051 // Local includes
    00052 #include "STUImportRTStructureSystem.h"
    00053 #include <CSOBase/CSOList.h>
    00054 #include <DCMTree_Lib.h>
    00055 #include "DCMTree_IOParameter.h"
    00056 #include "DCMTree_Reader.h"
    00057 #include "DCMTree_Dict.h"
    00058 #include "DCMTree_Tag.h"
    00059 #include "DCMTree_Value.h"
    00060 #include <dcmtree_dicomtags.h>
    00061 #include <dcmtree_exception.h>
    00062 #include <dcmtree_message.h>
    00063 #include <CSOTools/CSOGeneratePathPoints.h>
    00064
    00065
    00066 // ML includes
    00067 #include "mlOperatorIncludes.h"
    00068 #include "mlRTStructure.h"
    00069
    00070 ML_START_NAMESPACE
    00071
    00072
    00073
    00075 class STUIMPORTRTSTRUCTURE_EXPORT ImportRTStructure : public BaseOp
    00076 {
    00077 public:
    00078
    00079   enum outputType {panel, console};
    00081   ImportRTStructure ();
    00083   ~ImportRTStructure();
    00085   inline StringField        &getInDCMFileFld () const { return *_inDCMFileFld;}
    00086
    00088   inline StringField        &getAllTagsFld () const { return *_allTagsFld;}
    00089
    00091   inline NotifyField        &getApplyFld () const { return *_applyFld;}
    00092
    00094   virtual void handleNotification (Field *field);
    00095
    00097   virtual void activateAttachments ();
    00098
    00100   void removeContourData();
    00101
    00102   //void checkTagValues();
    00103
    00104 private:
    00105   // ----------------------------------------------------------
    00107   // ----------------------------------------------------------
    00108
    00110   BaseField   *_outListFld;
    00111
    00113   BaseField  *_dcmObjFld;
    00114   RTStructure *_objToTransfer;
    00115   DCMTree::TreePtr _treePtr;
    00117   CSOList         *_outList;
    00118
    00120   StringField *_inDCMFileFld;
    00121
    00123   IntField *_thresholdFld;
    00124
    00126   IntField *_dividendFld;
    00127
    00129   IntField *_divisorFld;
    00130
    00132   StringField *_allTagsFld;
    00134   StringField *_dicmFileFld;
    00135   StringField *_tagNameFld[9];
    00136
    00137   StringField *_tagValueFld[9];
    00138   NotifyField *_getValuesFld;
    00139   BoolField   *_trimSpacesFld;
    00140   BoolField   *_validFld;
    00141   NotifyField *_printFld;
    00142
    00144   std::string _allTagValues;
    00145
    00147   NotifyField *_applyFld;
    00148
    00149   //DCMTree::TreePtr _dcmTreePtr;
    00150   static const int tagFieldNum = 9;
    00151
    00153   bool RTStructure2CSO(std::string dcmfile);
    00154
    00156   void parseCSOGroup();
    00157
    00159   void parseCSO();
    00160
    00162   void fillUpDCMTagViewer();
    00163
    00165   void getDCMTreeFromFile(std::string inDCMFile);
    00166
    00168   std::string getTagValue(DCMTree::Const_TagPtr tagPtr);
    00169
    00171   ML_BASEOP_CLASS_HEADER(ImportRTStructure)
    00172 };
    00173
    00174
    00175 ML_END_NAMESPACE
    00176
    00177 #endif // __STUImportRTStructure_H
    00178

All Classes Namespaces Files Functions Variables Enumerator Friends