OXIESEC PANEL
- Current Dir:
/
/
usr
/
include
/
gdcm-2.8
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
10/28/2024 06:50:42 AM
rwxr-xr-x
📄
gdcmAAbortPDU.h
1.43 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAAssociateACPDU.h
3.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAAssociateRJPDU.h
1.35 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAAssociateRQPDU.h
5.41 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmARTIMTimer.h
2.48 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAReleaseRPPDU.h
1.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAReleaseRQPDU.h
1.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmASN1.h
1.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAbstractSyntax.h
1.78 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAnonymizeEvent.h
1.5 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAnonymizer.h
6.67 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmApplicationContext.h
1.56 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmApplicationEntity.h
1.81 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAsynchronousOperationsWindowSub.h
1.37 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAttribute.h
32.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmAudioCodec.h
1011 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBase64.h
1.9 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBaseCompositeMessage.h
2.39 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBaseNormalizedMessage.h
2.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBasePDU.h
1.96 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBaseQuery.h
2.74 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBaseRootQuery.h
4.33 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBasicOffsetTable.h
3.17 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBitmap.h
5.7 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBitmapToBitmapFilter.h
1.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmBoxRegion.h
2.02 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmByteBuffer.h
2.45 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmByteSwap.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmByteSwap.txx
4.55 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmByteSwapFilter.h
1.1 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmByteValue.h
6.53 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCAPICryptoFactory.h
931 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCAPICryptographicMessageSyntax.h
1.96 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCEchoMessages.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCFindMessages.h
1.65 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCMoveMessages.h
1.88 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCP246ExplicitDataElement.h
1.59 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCP246ExplicitDataElement.txx
6.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCSAElement.h
4.76 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCSAHeader.h
4.89 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCSAHeader.txx
957 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCSAHeaderDict.h
2.84 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCSAHeaderDictEntry.h
2.74 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCStoreMessages.h
1.8 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCodeString.h
3.67 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCodec.h
809 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCoder.h
1.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCommand.h
5.09 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCommandDataSet.h
1.7 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCompositeMessageFactory.h
2.44 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCompositeNetworkFunctions.h
5.84 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmConfigure.h
5.53 KB
02/05/2018 04:49:23 PM
rw-r--r--
📄
gdcmConstCharWrapper.h
1.6 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCryptoFactory.h
1.85 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCryptographicMessageSyntax.h
1.78 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmCurve.h
2.54 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDICOMDIR.h
984 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDICOMDIRGenerator.h
3.85 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDIMSE.h
2.61 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDataElement.h
9 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDataEvent.h
1.53 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDataSet.h
10.79 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDataSet.txx
16.02 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDataSetEvent.h
1.47 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDataSetHelper.h
1.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDecoder.h
1.16 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDefinedTerms.h
1.56 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDeflateStream.h
678 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDefs.h
2.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDeltaEncodingCodec.h
1.08 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDict.h
9.53 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDictConverter.h
2.05 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDictEntry.h
4.29 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDictPrinter.h
1.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDicts.h
2.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDirectionCosines.h
1.94 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDirectory.h
3.08 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDirectoryHelper.h
3.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDummyValueGenerator.h
1.15 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmDumper.h
1023 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmElement.h
23.5 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmEmptyMaskGenerator.h
2.64 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmEncapsulatedDocument.h
866 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmEnumeratedValues.h
1.53 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmEvent.h
3.07 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmException.h
3.24 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmExplicitDataElement.h
1.36 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmExplicitDataElement.txx
16.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmExplicitImplicitDataElement.h
1.81 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmExplicitImplicitDataElement.txx
14.69 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFiducials.h
800 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFile.h
2.1 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileAnonymizer.h
2.84 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileChangeTransferSyntax.h
2.2 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileDecompressLookupTable.h
1.49 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileDerivation.h
3.19 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileExplicitFilter.h
2.43 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileMetaInformation.h
4.78 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileNameEvent.h
1.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileSet.h
1.62 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFileStreamer.h
4.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFilename.h
2.26 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFilenameGenerator.h
2.09 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFindPatientRootQuery.h
1.2 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFindStudyRootQuery.h
1.41 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFragment.h
6.13 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmFragment.txx
711 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmGlobal.h
3.41 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmGroupDict.h
2.29 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIOD.h
1.85 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIODEntry.h
2.97 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIODs.h
2.02 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIPPSorter.h
4.62 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIconImage.h
2.47 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIconImageFilter.h
2.37 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmIconImageGenerator.h
3.09 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImage.h
3.63 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageApplyLookupTable.h
1.11 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageChangePhotometricInterpretation.h
3.77 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageChangePlanarConfiguration.h
2.72 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageChangeTransferSyntax.h
3.29 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageCodec.h
4.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageConverter.h
1.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageFragmentSplitter.h
1.53 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageHelper.h
6.92 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageReader.h
1.55 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageRegionReader.h
2.44 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageToImageFilter.h
1.15 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImageWriter.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImplementationClassUIDSub.h
1.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImplementationUIDSub.h
1.14 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImplementationVersionNameSub.h
1.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImplicitDataElement.h
1.49 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmImplicitDataElement.txx
18.5 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmItem.h
9.65 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmItem.txx
1.82 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJPEG12Codec.h
1.26 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJPEG16Codec.h
1.25 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJPEG2000Codec.h
2.73 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJPEG8Codec.h
1.25 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJPEGCodec.h
3.23 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJPEGLSCodec.h
2.99 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmJSON.h
1.12 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmKAKADUCodec.h
1.06 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmLO.h
1.81 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmLegacyMacro.h
2.72 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmLookupTable.h
3.33 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMD5.h
1.41 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMacro.h
2.93 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMacroEntry.h
2.57 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMacros.h
2.05 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMaximumLengthSub.h
1.39 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMediaStorage.h
7.39 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMeshPrimitive.h
2.34 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmModalityPerformedProcedureStepCreateQuery.h
1.3 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmModalityPerformedProcedureStepSetQuery.h
1.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmModule.h
3.15 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmModuleEntry.h
2.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmModules.h
2.06 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMovePatientRootQuery.h
1.21 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMoveStudyRootQuery.h
1.19 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmMrProtocol.h
2.17 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNActionMessages.h
1.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNCreateMessages.h
1.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNDeleteMessages.h
1.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNEventReportMessages.h
1.31 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNGetMessages.h
1.24 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNSetMessages.h
1.24 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNestedModuleEntries.h
1.88 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNetworkEvents.h
1.95 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNetworkStateID.h
2.69 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNormalizedMessageFactory.h
1.64 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmNormalizedNetworkFunctions.h
3.03 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmObject.h
2.98 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmOpenSSLCryptoFactory.h
1.18 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmOpenSSLCryptographicMessageSyntax.h
2.09 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmOpenSSLP7CryptoFactory.h
1.12 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmOpenSSLP7CryptographicMessageSyntax.h
2.37 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmOrientation.h
1.77 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmOverlay.h
3.71 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPDBElement.h
1.69 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPDBHeader.h
2.92 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPDFCodec.h
1003 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPDUFactory.h
3.42 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPDataTFPDU.h
1.89 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPGXCodec.h
1.21 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPNMCodec.h
1.52 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPVRGCodec.h
1.42 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmParseException.h
2.2 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmParser.h
3.98 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPatient.h
899 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPersonName.h
2.45 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPhotometricInterpretation.h
2.75 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPixelFormat.h
7.44 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPixmap.h
2.29 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPixmapReader.h
2.05 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPixmapToPixmapFilter.h
1.15 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPixmapWriter.h
1.99 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPreamble.h
1.9 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPresentationContext.h
2.21 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPresentationContextAC.h
1.77 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPresentationContextGenerator.h
3.79 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPresentationContextRQ.h
3.18 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPresentationDataValue.h
2.7 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPrinter.h
2.84 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmPrivateTag.h
2.5 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmProgressEvent.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmQueryBase.h
3.48 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmQueryFactory.h
3.58 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmQueryImage.h
1.45 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmQueryPatient.h
1.44 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmQuerySeries.h
1.43 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmQueryStudy.h
1.42 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmRAWCodec.h
1.45 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmRLECodec.h
2.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmReader.h
4.39 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmRegion.h
1.68 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmRescaler.h
4.63 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmRoleSelectionSub.h
1.36 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSHA1.h
1.42 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSOPClassExtendedNegociationSub.h
1.56 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSOPClassUIDToIOD.h
1.47 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmScanner.h
7.32 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSegment.h
4.18 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSegmentHelper.h
2.17 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSegmentReader.h
1.58 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSegmentWriter.h
1.52 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSegmentedPaletteColorLookupTable.h
1.16 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSequenceOfFragments.h
11.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSequenceOfFragments.txx
756 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSequenceOfItems.h
8.36 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSequenceOfItems.txx
1.22 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSerieHelper.h
3.03 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSeries.h
809 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmServiceClassApplicationInformation.h
1.28 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmServiceClassUser.h
3.94 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSimpleSubjectWatcher.h
2.91 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSmartPointer.h
2.86 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSorter.h
2.55 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSpacing.h
5.05 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSpectroscopy.h
824 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSplitMosaicFilter.h
2.15 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmStaticAssert.h
1.47 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmStreamImageReader.h
5.41 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmStreamImageWriter.h
6.21 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmStrictScanner.h
6.54 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmString.h
4.4 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmStringFilter.h
2.78 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmStudy.h
856 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSubject.h
2.43 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSurface.h
7.6 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSurfaceHelper.h
6.31 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSurfaceReader.h
1.27 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSurfaceWriter.h
1.62 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSwapCode.h
1.52 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSwapper.h
1.6 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSwapper.txx
6.14 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmSystem.h
5.16 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTable.h
1.61 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTableEntry.h
1.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTableReader.h
2.97 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTag.h
9.73 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTagKeywords.h
245.37 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTagPath.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTagToType.h
838.4 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTagToVR.h
734 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTerminal.h
1.56 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTestDriver.h
993 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTesting.h
4.38 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTrace.h
8.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTransferSyntax.h
4.34 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTransferSyntaxSub.h
1.65 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmType.h
1.86 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmTypes.h
1.96 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUIDGenerator.h
3.41 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUIDs.h
46.02 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULAction.h
3.35 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULActionAA.h
3.67 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULActionAE.h
3.7 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULActionAR.h
4.1 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULActionDT.h
1.73 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULBasicCallback.h
2.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULConnection.h
5.33 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULConnectionCallback.h
2.47 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULConnectionInfo.h
2.63 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULConnectionManager.h
6.94 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULEvent.h
2.65 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULTransitionTable.h
3.48 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmULWritingCallback.h
1.81 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUNExplicitDataElement.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUNExplicitDataElement.txx
6.18 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUNExplicitImplicitDataElement.h
1.8 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUNExplicitImplicitDataElement.txx
2.09 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUUIDGenerator.h
1.04 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUnpacker12Bits.h
1.72 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUsage.h
2.61 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmUserInformation.h
2.15 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmVL.h
3.23 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmVM.h
4.92 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmVR.h
9.97 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmVR16ExplicitDataElement.h
1.57 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmVR16ExplicitDataElement.txx
8.84 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmValidate.h
973 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmValue.h
1.34 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmValue.txx
681 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmValueIO.h
1.01 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmValueIO.txx
2.25 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmVersion.h
1.43 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmWLMFindQuery.h
1.26 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmWaveform.h
800 bytes
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmWin32.h
3.05 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmWriter.h
3.03 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmXMLDictReader.h
1.39 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmXMLPrinter.h
3.54 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcmXMLPrivateDictReader.h
1.46 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcm_j2k.h
15.51 KB
11/09/2017 08:09:58 AM
rw-r--r--
📄
gdcm_jp2.h
5.8 KB
11/09/2017 08:09:58 AM
rw-r--r--
📁
gdcmjpeg
-
10/28/2024 06:50:28 AM
rwxr-xr-x
📄
zipstreamimpl.h
10.7 KB
11/09/2017 08:09:58 AM
rw-r--r--
Editing: gdcmElement.h
Close
/*========================================================================= Program: GDCM (Grassroots DICOM). A DICOM library Copyright (c) 2006-2011 Mathieu Malaterre All rights reserved. See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details. This software is distributed WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the above copyright notice for more information. =========================================================================*/ #ifndef GDCMELEMENT_H #define GDCMELEMENT_H #include "gdcmTypes.h" #include "gdcmVR.h" #include "gdcmTag.h" #include "gdcmVM.h" #include "gdcmByteValue.h" #include "gdcmDataElement.h" #include "gdcmSwapper.h" #include <string> #include <vector> #include <sstream> #include <limits> #include <cmath> #include <cstring> namespace gdcm_ns { // Forward declaration /** * \brief EncodingImplementation * * \note TODO */ template<int T> class EncodingImplementation; /** * \brief A class which is used to produce compile errors for an * invalid combination of template parameters. * * Invalid combinations have specialized declarations with no * definition. */ template <int TVR, int TVM> class ElementDisableCombinations {}; template <> class ElementDisableCombinations<VR::OB, VM::VM1_n> {}; template <> class ElementDisableCombinations<VR::OW, VM::VM1_n> {}; // Make it impossible to compile these other cases template <int TVM> class ElementDisableCombinations<VR::OB, TVM>; template <int TVM> class ElementDisableCombinations<VR::OW, TVM>; /** * \brief Element class * * \note TODO */ template<int TVR, int TVM> class Element { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<TVR, TVM> ) }; public: typename VRToType<TVR>::Type Internal[VMToLength<TVM>::Length]; typedef typename VRToType<TVR>::Type Type; static VR GetVR() { return (VR::VRType)TVR; } static VM GetVM() { return (VM::VMType)TVM; } unsigned long GetLength() const { return VMToLength<TVM>::Length; } // Implementation of Print is common to all Mode (ASCII/Binary) // TODO: Can we print a \ when in ASCII...well I don't think so // it would mean we used a bad VM then, right ? void Print(std::ostream &_os) const { _os << Internal[0]; // VM is at least garantee to be one for(int i=1; i<VMToLength<TVM>::Length; ++i) _os << "," << Internal[i]; } const typename VRToType<TVR>::Type *GetValues() const { return Internal; } const typename VRToType<TVR>::Type &GetValue(unsigned int idx = 0) const { assert( idx < VMToLength<TVM>::Length ); return Internal[idx]; } typename VRToType<TVR>::Type &GetValue(unsigned int idx = 0) { assert( idx < VMToLength<TVM>::Length ); return Internal[idx]; } typename VRToType<TVR>::Type operator[] (unsigned int idx) const { return GetValue(idx); } void SetValue(typename VRToType<TVR>::Type v, unsigned int idx = 0) { assert( idx < VMToLength<TVM>::Length ); Internal[idx] = v; } void SetFromDataElement(DataElement const &de) { const ByteValue *bv = de.GetByteValue(); if( !bv ) return; #ifdef GDCM_WORDS_BIGENDIAN if( de.GetVR() == VR::UN /*|| de.GetVR() == VR::INVALID*/ ) #else if( de.GetVR() == VR::UN || de.GetVR() == VR::INVALID ) #endif { Set(de.GetValue()); } else { SetNoSwap(de.GetValue()); } } DataElement GetAsDataElement() const { DataElement ret; std::ostringstream os; EncodingImplementation<VRToEncoding<TVR>::Mode>::Write(Internal, GetLength(),os); ret.SetVR( (VR::VRType)TVR ); assert( ret.GetVR() != VR::SQ ); if( (VR::VRType)VRToEncoding<TVR>::Mode == VR::VRASCII ) { if( GetVR() != VR::UI ) { if( os.str().size() % 2 ) { os << " "; } } } VL::Type osStrSize = (VL::Type)os.str().size(); ret.SetByteValue( os.str().c_str(), osStrSize ); return ret; } void Read(std::istream &_is) { return EncodingImplementation<VRToEncoding<TVR>::Mode>::Read(Internal, GetLength(),_is); } void Write(std::ostream &_os) const { return EncodingImplementation<VRToEncoding<TVR>::Mode>::Write(Internal, GetLength(),_os); } // FIXME: remove this function // this is only used in gdcm::SplitMosaicFilter / to pass value of a CSAElement void Set(Value const &v) { const ByteValue *bv = dynamic_cast<const ByteValue*>(&v); if( bv ) { //memcpy(Internal, bv->GetPointer(), bv->GetLength()); std::stringstream ss; std::string s = std::string( bv->GetPointer(), bv->GetLength() ); ss.str( s ); EncodingImplementation<VRToEncoding<TVR>::Mode>::Read(Internal, GetLength(),ss); } } protected: void SetNoSwap(Value const &v) { const ByteValue *bv = dynamic_cast<const ByteValue*>(&v); assert( bv ); // That would be bad... //memcpy(Internal, bv->GetPointer(), bv->GetLength()); std::stringstream ss; std::string s = std::string( bv->GetPointer(), bv->GetLength() ); ss.str( s ); EncodingImplementation<VRToEncoding<TVR>::Mode>::ReadNoSwap(Internal, GetLength(),ss); } }; struct ignore_char { ignore_char(char c): m_char(c) {} char m_char; }; ignore_char const backslash('\\'); inline std::istream& operator>> (std::istream& in, ignore_char const& ic) { if (!in.eof()) in.clear(in.rdstate() & ~std::ios_base::failbit); if (in.get() != ic.m_char) in.setstate(std::ios_base::failbit); return in; } // Implementation to perform formatted read and write template<> class EncodingImplementation<VR::VRASCII> { public: template<typename T> // FIXME this should be VRToType<TVR>::Type static inline void ReadComputeLength(T* data, unsigned int &length, std::istream &_is) { assert( data ); //assert( length ); // != 0 length = 0; assert( _is ); #if 0 char sep; while( _is >> data[length++] ) { // Get the separator in between the values assert( _is ); _is.get(sep); assert( sep == '\\' || sep == ' ' ); // FIXME: Bad use of assert if( sep == ' ' ) length--; // FIXME } #else while( _is >> std::ws >> data[length++] >> std::ws >> backslash ) { } #endif } template<typename T> // FIXME this should be VRToType<TVR>::Type static inline void Read(T* data, unsigned long length, std::istream &_is) { assert( data ); assert( length ); // != 0 assert( _is ); // FIXME BUG: what if >> operation fails ? // gdcmData/MR00010001.dcm / SpacingBetweenSlices _is >> std::ws >> data[0]; char sep; //std::cout << "GetLength: " << af->GetLength() << std::endl; for(unsigned long i=1; i<length;++i) { assert( _is ); // Get the separator in between the values _is >> std::ws >> sep; //_is.get(sep); assert( sep == '\\' ); // FIXME: Bad use of assert _is >> std::ws >> data[i]; } } template<typename T> static inline void ReadNoSwap(T* data, unsigned long length, std::istream &_is) { Read(data,length,_is); } template<typename T> static inline void Write(const T* data, unsigned long length, std::ostream &_os) { assert( data ); assert( length ); assert( _os ); _os << data[0]; for(unsigned long i=1; i<length; ++i) { assert( _os ); _os << "\\" << data[i]; } } }; #define VRDS16ILLEGAL #ifdef VRDS16ILLEGAL template < typename Float > std::string to_string ( Float data ) { std::stringstream in; // in.imbue(std::locale::classic()); // This is not required AFAIK int const digits = static_cast< int >( - std::log( std::numeric_limits<Float>::epsilon() ) / static_cast< Float >( std::log( 10.0 ) ) ); if ( in << std::dec << std::setprecision(/*2+*/digits) << data ) { return ( in.str() ); } else { throw "Impossible Conversion"; // should not happen ... } } #else // http://stackoverflow.com/questions/32631178/writing-ieee-754-1985-double-as-ascii-on-a-limited-16-bytes-string static size_t shrink(char *fp_buffer) { int lead, expo; long long mant; int n0, n1; int n = sscanf(fp_buffer, "%d.%n%lld%ne%d", &lead, &n0, &mant, &n1, &expo); assert(n == 3); return sprintf(fp_buffer, "%d%0*llde%d", lead, n1 - n0, mant, expo - (n1 - n0)); } template < typename Float > static int x16printf(char *dest, size_t width, Float value) { if (!std::isfinite(value)) return 1; if (width < 5) return 2; if (std::signbit(value)) { value = -value; strcpy(dest++, "-"); width--; } int precision = width - 2; while (precision > 0) { char buffer[width + 10]; // %.*e prints 1 digit, '.' and then `precision - 1` digits snprintf(buffer, sizeof buffer, "%.*e", precision - 1, value); size_t n = shrink(buffer); if (n <= width) { strcpy(dest, buffer); return 0; } if (n > width + 1) precision -= n - width - 1; else precision--; } return 3; } #endif /* Writing VR::DS is not that easy after all */ // http://groups.google.com/group/comp.lang.c++/browse_thread/thread/69ccd26f000a0802 template<> inline void EncodingImplementation<VR::VRASCII>::Write(const float * data, unsigned long length, std::ostream &_os) { assert( data ); assert( length ); assert( _os ); #ifdef VRDS16ILLEGAL _os << to_string(data[0]); #else char buf[16+1]; x16printf(buf, sizeof buf, data[0]); _os << buf; #endif for(unsigned long i=1; i<length; ++i) { assert( _os ); #ifdef VRDS16ILLEGAL _os << "\\" << to_string(data[i]); #else x16printf(buf, sizeof buf, data[i]); _os << "\\" << buf; #endif } } template<> inline void EncodingImplementation<VR::VRASCII>::Write(const double* data, unsigned long length, std::ostream &_os) { assert( data ); assert( length ); assert( _os ); #ifdef VRDS16ILLEGAL _os << to_string(data[0]); #else char buf[16+1]; x16printf(buf, sizeof buf, data[0]); _os << buf; #endif for(unsigned long i=1; i<length; ++i) { assert( _os ); #ifdef VRDS16ILLEGAL _os << "\\" << to_string(data[i]); #else x16printf(buf, sizeof buf, data[i]); _os << "\\" << buf; #endif } } // Implementation to perform binary read and write // TODO rewrite operation so that either: // #1. dummy implementation use a pointer to Internal and do ++p (faster) // #2. Actually do some meta programming to unroll the loop // (no notion of order in VM ...) template<> class EncodingImplementation<VR::VRBINARY> { public: template<typename T> // FIXME this should be VRToType<TVR>::Type static inline void ReadComputeLength(T* data, unsigned int &length, std::istream &_is) { const unsigned int type_size = sizeof(T); assert( data ); // Can we read from pointer ? //assert( length ); length /= type_size; assert( _is ); // Is stream valid ? _is.read( reinterpret_cast<char*>(data+0), type_size); for(unsigned long i=1; i<length; ++i) { assert( _is ); _is.read( reinterpret_cast<char*>(data+i), type_size ); } } template<typename T> static inline void ReadNoSwap(T* data, unsigned long length, std::istream &_is) { const unsigned int type_size = sizeof(T); assert( data ); // Can we read from pointer ? assert( length ); assert( _is ); // Is stream valid ? _is.read( reinterpret_cast<char*>(data+0), type_size); for(unsigned long i=1; i<length; ++i) { assert( _is ); _is.read( reinterpret_cast<char*>(data+i), type_size ); } //ByteSwap<T>::SwapRangeFromSwapCodeIntoSystem(data, // _is.GetSwapCode(), length); //SwapperNoOp::SwapArray(data,length); } template<typename T> static inline void Read(T* data, unsigned long length, std::istream &_is) { const unsigned int type_size = sizeof(T); assert( data ); // Can we read from pointer ? assert( length ); assert( _is ); // Is stream valid ? _is.read( reinterpret_cast<char*>(data+0), type_size); for(unsigned long i=1; i<length; ++i) { assert( _is ); _is.read( reinterpret_cast<char*>(data+i), type_size ); } //ByteSwap<T>::SwapRangeFromSwapCodeIntoSystem(data, // _is.GetSwapCode(), length); SwapperNoOp::SwapArray(data,length); } template<typename T> static inline void Write(const T* data, unsigned long length, std::ostream &_os) { const unsigned int type_size = sizeof(T); assert( data ); // Can we write into pointer ? assert( length ); assert( _os ); // Is stream valid ? //ByteSwap<T>::SwapRangeFromSwapCodeIntoSystem((T*)data, // _os.GetSwapCode(), length); T swappedData = SwapperNoOp::Swap(data[0]); _os.write( reinterpret_cast<const char*>(&swappedData), type_size); for(unsigned long i=1; i<length;++i) { assert( _os ); swappedData = SwapperNoOp::Swap(data[i]); _os.write( reinterpret_cast<const char*>(&swappedData), type_size ); } //ByteSwap<T>::SwapRangeFromSwapCodeIntoSystem((T*)data, // _os.GetSwapCode(), length); } }; // For particular case for ASCII string // WARNING: This template explicitly instanciates a particular // EncodingImplementation THEREFORE it is required to be declared after the // EncodingImplementation is needs (doh!) #if 0 template<int TVM> class Element<TVM> { public: Element(const char array[]) { unsigned int i = 0; const char sep = '\\'; std::string sarray = array; std::string::size_type pos1 = 0; std::string::size_type pos2 = sarray.find(sep, pos1+1); while(pos2 != std::string::npos) { Internal[i++] = sarray.substr(pos1, pos2-pos1); pos1 = pos2+1; pos2 = sarray.find(sep, pos1+1); } Internal[i] = sarray.substr(pos1, pos2-pos1); // Shouldn't we do the contrary, since we know how many separators // (and default behavior is to discard anything after the VM declared assert( GetLength()-1 == i ); } unsigned long GetLength() const { return VMToLength<TVM>::Length; } // Implementation of Print is common to all Mode (ASCII/Binary) void Print(std::ostream &_os) const { _os << Internal[0]; // VM is at least garantee to be one for(int i=1; i<VMToLength<TVM>::Length; ++i) _os << "," << Internal[i]; } void Read(std::istream &_is) { EncodingImplementation<VR::VRASCII>::Read(Internal, GetLength(),_is); } void Write(std::ostream &_os) const { EncodingImplementation<VR::VRASCII>::Write(Internal, GetLength(),_os); } private: typename String Internal[VMToLength<TVM>::Length]; }; template< int TVM> class Element<VR::PN, TVM> : public StringElement<TVM> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<VR::PN, TVM> ) }; }; #endif // Implementation for the undefined length (dynamically allocated array) template<int TVR> class Element<TVR, VM::VM1_n> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<TVR, VM::VM1_n> ) }; public: // This the way to prevent default initialization explicit Element() { Internal=0; Length=0; Save = false; } ~Element() { if( Save ) { delete[] Internal; } Internal = 0; } static VR GetVR() { return (VR::VRType)TVR; } static VM GetVM() { return VM::VM1_n; } // Length manipulation // SetLength should really be protected anyway...all operation // should go through SetArray unsigned long GetLength() const { return Length; } typedef typename VRToType<TVR>::Type Type; void SetLength(unsigned long len) { const unsigned int size = sizeof(Type); if( len ) { if( len > Length ) { // perform realloc assert( (len / size) * size == len ); Type *internal = new Type[len / size]; assert( Save == false ); Save = true; // ???? if( Internal ) { memcpy(internal, Internal, len); delete[] Internal; } Internal = internal; } } Length = len / size; } // If save is set to zero user should not delete the pointer //void SetArray(const typename VRToType<TVR>::Type *array, int len, bool save = false) void SetArray(const Type *array, unsigned long len, bool save = false) { if( save ) { SetLength(len); // realloc memcpy(Internal, array, len/*/sizeof(Type)*/); assert( Save == false ); } else { // TODO rewrite this stupid code: assert( Length == 0 ); assert( Internal == 0 ); assert( Save == false ); Length = len / sizeof(Type); //assert( (len / sizeof(Type)) * sizeof(Type) == len ); // MR00010001.dcm is a tough kid: 0019,105a is supposed to be VR::FL, VM::VM3 but // length is 14 bytes instead of 12 bytes. Simply consider value is total garbage. if( (len / sizeof(Type)) * sizeof(Type) != len ) { Internal = 0; Length = 0; } else Internal = const_cast<Type*>(array); } Save = save; } void SetValue(typename VRToType<TVR>::Type v, unsigned int idx = 0) { assert( idx < Length ); Internal[idx] = v; } const typename VRToType<TVR>::Type &GetValue(unsigned int idx = 0) const { assert( idx < Length ); return Internal[idx]; } typename VRToType<TVR>::Type &GetValue(unsigned int idx = 0) { //assert( idx < Length ); return Internal[idx]; } typename VRToType<TVR>::Type operator[] (unsigned int idx) const { return GetValue(idx); } void Set(Value const &v) { const ByteValue *bv = dynamic_cast<const ByteValue*>(&v); assert( bv ); // That would be bad... if( (VR::VRType)(VRToEncoding<TVR>::Mode) == VR::VRBINARY ) { const Type* array = (Type*)bv->GetPointer(); if( array ) { assert( array ); // That would be bad... assert( Internal == 0 ); SetArray(array, bv->GetLength() ); } } else { std::stringstream ss; std::string s = std::string( bv->GetPointer(), bv->GetLength() ); ss.str( s ); EncodingImplementation<VRToEncoding<TVR>::Mode>::Read(Internal, GetLength(),ss); } } void SetFromDataElement(DataElement const &de) { const ByteValue *bv = de.GetByteValue(); if( !bv ) return; #ifdef GDCM_WORDS_BIGENDIAN if( de.GetVR() == VR::UN /*|| de.GetVR() == VR::INVALID*/ ) #else if( de.GetVR() == VR::UN || de.GetVR() == VR::INVALID ) #endif { Set(de.GetValue()); } else { SetNoSwap(de.GetValue()); } } // Need to be placed after definition of EncodingImplementation<VR::VRASCII> void WriteASCII(std::ostream &os) const { return EncodingImplementation<VR::VRASCII>::Write(Internal, GetLength(), os); } // Implementation of Print is common to all Mode (ASCII/Binary) void Print(std::ostream &_os) const { assert( Length ); assert( Internal ); _os << Internal[0]; // VM is at least garantee to be one const unsigned long length = GetLength() < 25 ? GetLength() : 25; for(unsigned long i=1; i<length; ++i) _os << "," << Internal[i]; } void Read(std::istream &_is) { if( !Internal ) return; EncodingImplementation<VRToEncoding<TVR>::Mode>::Read(Internal, GetLength(),_is); } //void ReadComputeLength(std::istream &_is) { // if( !Internal ) return; // EncodingImplementation<VRToEncoding<TVR>::Mode>::ReadComputeLength(Internal, // Length,_is); // } void Write(std::ostream &_os) const { EncodingImplementation<VRToEncoding<TVR>::Mode>::Write(Internal, GetLength(),_os); } DataElement GetAsDataElement() const { DataElement ret; ret.SetVR( (VR::VRType)TVR ); assert( ret.GetVR() != VR::SQ ); if( Internal ) { std::ostringstream os; EncodingImplementation<VRToEncoding<TVR>::Mode>::Write(Internal, GetLength(),os); if( (VR::VRType)VRToEncoding<TVR>::Mode == VR::VRASCII ) { if( GetVR() != VR::UI ) { if( os.str().size() % 2 ) { os << " "; } } } VL::Type osStrSize = (VL::Type)os.str().size(); ret.SetByteValue( os.str().c_str(), osStrSize ); } return ret; } Element(const Element&_val) { if( this != &_val) { *this = _val; } } Element &operator=(const Element &_val) { Length = 0; // SYITF Internal = 0; SetArray(_val.Internal, _val.Length, true); return *this; } protected: void SetNoSwap(Value const &v) { const ByteValue *bv = dynamic_cast<const ByteValue*>(&v); assert( bv ); // That would be bad... if( (VR::VRType)(VRToEncoding<TVR>::Mode) == VR::VRBINARY ) { const Type* array = (Type*)bv->GetPointer(); if( array ) { assert( array ); // That would be bad... assert( Internal == 0 ); SetArray(array, bv->GetLength() ); } } else { std::stringstream ss; std::string s = std::string( bv->GetPointer(), bv->GetLength() ); ss.str( s ); EncodingImplementation<VRToEncoding<TVR>::Mode>::ReadNoSwap(Internal, GetLength(),ss); } } private: typename VRToType<TVR>::Type *Internal; unsigned long Length; // unsigned int ?? bool Save; }; //template <int TVM = VM::VM1_n> //class Element<VR::OB, TVM > : public Element<VR::OB, VM::VM1_n> {}; // Partial specialization for derivatives of 1-n : 2-n, 3-n ... template<int TVR> class Element<TVR, VM::VM1_2> : public Element<TVR, VM::VM1_n> { public: typedef Element<TVR, VM::VM1_n> Parent; void SetLength(int len) { if( len != 1 && len != 2 ) return; Parent::SetLength(len); } }; template<int TVR> class Element<TVR, VM::VM2_n> : public Element<TVR, VM::VM1_n> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<TVR, VM::VM2_n> ) }; public: typedef Element<TVR, VM::VM1_n> Parent; void SetLength(int len) { if( len <= 1 ) return; Parent::SetLength(len); } }; template<int TVR> class Element<TVR, VM::VM2_2n> : public Element<TVR, VM::VM2_n> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<TVR, VM::VM2_2n> ) }; public: typedef Element<TVR, VM::VM2_n> Parent; void SetLength(int len) { if( len % 2 ) return; Parent::SetLength(len); } }; template<int TVR> class Element<TVR, VM::VM3_n> : public Element<TVR, VM::VM1_n> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<TVR, VM::VM3_n> ) }; public: typedef Element<TVR, VM::VM1_n> Parent; void SetLength(int len) { if( len <= 2 ) return; Parent::SetLength(len); } }; template<int TVR> class Element<TVR, VM::VM3_3n> : public Element<TVR, VM::VM3_n> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<TVR, VM::VM3_3n> ) }; public: typedef Element<TVR, VM::VM3_n> Parent; void SetLength(int len) { if( len % 3 ) return; Parent::SetLength(len); } }; //template<int T> struct VRToLength; //template <> struct VRToLength<VR::AS> //{ enum { Length = VM::VM1 }; } //template<> //class Element<VR::AS> : public Element<VR::AS, VRToLength<VR::AS>::Length > // only 0010 1010 AS 1 Patient's Age template<> class Element<VR::AS, VM::VM5> { enum { ElementDisableCombinationsCheck = sizeof ( ElementDisableCombinations<VR::AS, VM::VM5> ) }; public: char Internal[VMToLength<VM::VM5>::Length * sizeof( VRToType<VR::AS>::Type )]; void Print(std::ostream &_os) const { _os << Internal; } unsigned long GetLength() const { return VMToLength<VM::VM5>::Length; } }; template <> class Element<VR::OB, VM::VM1> : public Element<VR::OB, VM::VM1_n> {}; // Same for OW: template <> class Element<VR::OW, VM::VM1> : public Element<VR::OW, VM::VM1_n> {}; } // namespace gdcm_ns #endif //GDCMELEMENT_H