Mercurial > hg > orthanc-ohif
comparison Sources/Plugin.cpp @ 7:eab054ee7537
added modal in Orthanc Explorer to choose between the OHIF viewers
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sun, 18 Jun 2023 10:37:21 +0200 |
parents | e8e7ba4371e3 |
children | cc4c81d08bf0 |
comparison
equal
deleted
inserted
replaced
6:e8e7ba4371e3 | 7:eab054ee7537 |
---|---|
89 | 89 |
90 static TagsDictionary ohifStudyTags_, ohifSeriesTags_, ohifInstanceTags_, allTags_; | 90 static TagsDictionary ohifStudyTags_, ohifSeriesTags_, ohifInstanceTags_, allTags_; |
91 | 91 |
92 static void InitializeOhifTags() | 92 static void InitializeOhifTags() |
93 { | 93 { |
94 /** | |
95 * Those are the tags that are found in the documentation of the | |
96 * "DICOM JSON" data source: | |
97 * https://docs.ohif.org/configuration/dataSources/dicom-json | |
98 **/ | |
94 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_INSTANCE_UID] = TagInformation(DataType_String, "StudyInstanceUID"); | 99 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_INSTANCE_UID] = TagInformation(DataType_String, "StudyInstanceUID"); |
95 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_DATE] = TagInformation(DataType_String, "StudyDate"); | 100 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_DATE] = TagInformation(DataType_String, "StudyDate"); |
96 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_TIME] = TagInformation(DataType_String, "StudyTime"); | 101 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_TIME] = TagInformation(DataType_String, "StudyTime"); |
97 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_DESCRIPTION] = TagInformation(DataType_String, "StudyDescription"); | 102 ohifStudyTags_[Orthanc::DICOM_TAG_STUDY_DESCRIPTION] = TagInformation(DataType_String, "StudyDescription"); |
98 ohifStudyTags_[Orthanc::DICOM_TAG_PATIENT_NAME] = TagInformation(DataType_String, "PatientName"); | 103 ohifStudyTags_[Orthanc::DICOM_TAG_PATIENT_NAME] = TagInformation(DataType_String, "PatientName"); |
128 ohifInstanceTags_[Orthanc::DICOM_TAG_STUDY_INSTANCE_UID] = TagInformation(DataType_String, "StudyInstanceUID"); | 133 ohifInstanceTags_[Orthanc::DICOM_TAG_STUDY_INSTANCE_UID] = TagInformation(DataType_String, "StudyInstanceUID"); |
129 ohifInstanceTags_[Orthanc::DICOM_TAG_WINDOW_CENTER] = TagInformation(DataType_Float, "WindowCenter"); | 134 ohifInstanceTags_[Orthanc::DICOM_TAG_WINDOW_CENTER] = TagInformation(DataType_Float, "WindowCenter"); |
130 ohifInstanceTags_[Orthanc::DICOM_TAG_WINDOW_WIDTH] = TagInformation(DataType_Float, "WindowWidth"); | 135 ohifInstanceTags_[Orthanc::DICOM_TAG_WINDOW_WIDTH] = TagInformation(DataType_Float, "WindowWidth"); |
131 ohifInstanceTags_[Orthanc::DICOM_TAG_SERIES_DATE] = TagInformation(DataType_String, "SeriesDate"); | 136 ohifInstanceTags_[Orthanc::DICOM_TAG_SERIES_DATE] = TagInformation(DataType_String, "SeriesDate"); |
132 | 137 |
138 /** | |
139 * The items below are related to PET scans. Their list can be found | |
140 * by looking for "required metadata are missing" in | |
141 * "extensions/default/src/getPTImageIdInstanceMetadata.ts" | |
142 **/ | |
143 ohifInstanceTags_[Orthanc::DICOM_TAG_SERIES_TIME] = TagInformation(DataType_String, "SeriesTime"); | |
144 ohifInstanceTags_[Orthanc::DicomTag(0x0010, 0x1030)] = TagInformation(DataType_Float, "PatientWeight"); | |
145 ohifInstanceTags_[Orthanc::DicomTag(0x0028, 0x0051)] = TagInformation(DataType_ListOfStrings, "CorrectedImage"); | |
146 ohifInstanceTags_[Orthanc::DicomTag(0x0054, 0x1001)] = TagInformation(DataType_String, "Units"); | |
147 ohifInstanceTags_[Orthanc::DicomTag(0x0054, 0x1102)] = TagInformation(DataType_String, "DecayCorrection"); | |
148 | |
133 for (TagsDictionary::const_iterator it = ohifStudyTags_.begin(); it != ohifStudyTags_.end(); ++it) | 149 for (TagsDictionary::const_iterator it = ohifStudyTags_.begin(); it != ohifStudyTags_.end(); ++it) |
134 { | 150 { |
135 assert(allTags_.find(it->first) == allTags_.end() || | 151 assert(allTags_.find(it->first) == allTags_.end() || |
136 allTags_[it->first] == it->second); | 152 allTags_[it->first] == it->second); |
137 allTags_[it->first] = it->second; | 153 allTags_[it->first] = it->second; |