00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef DJCPARAM_H
00035 #define DJCPARAM_H
00036
00037 #include "osconfig.h"
00038 #include "dccodec.h"
00039 #include "djutils.h"
00040
00043 class DJCodecParameter: public DcmCodecParameter
00044 {
00045 public:
00046
00076 DJCodecParameter(
00077 E_CompressionColorSpaceConversion pCompressionCSConversion,
00078 E_DecompressionColorSpaceConversion pDecompressionCSConversion,
00079 E_UIDCreation pCreateSOPInstanceUID,
00080 E_PlanarConfiguration pPlanarConfiguration,
00081 OFBool pVerbose = OFFalse,
00082 OFBool pOptimizeHuffman = OFFalse,
00083 int pSmoothingFactor = 0,
00084 int pForcedBitDepth = 0,
00085 Uint32 pFragmentSize = 0,
00086 OFBool pCreateOffsetTable = OFTrue,
00087 E_SubSampling pSampleFactors = ESS_444,
00088 OFBool pWriteYBR422 = OFFalse,
00089 OFBool pConvertToSC = OFFalse,
00090 unsigned long pWindowType = 0,
00091 unsigned long pWindowParameter = 0,
00092 double pVoiCenter = 0.0,
00093 double pVoiWidth = 0.0,
00094 unsigned long pRoiLeft = 0,
00095 unsigned long pRoiTop = 0,
00096 unsigned long pRoiWidth = 0,
00097 unsigned long pRoiHeight = 0,
00098 OFBool pUsePixelValues = OFTrue,
00099 OFBool pUseModalityRescale = OFFalse);
00100
00102 DJCodecParameter(const DJCodecParameter& arg);
00103
00105 virtual ~DJCodecParameter();
00106
00111 virtual DcmCodecParameter *clone() const;
00112
00116 virtual const char *className() const;
00117
00121 OFBool getOptimizeHuffmanCoding() const
00122 {
00123 return optimizeHuffman;
00124 }
00125
00129 int getSmoothingFactor() const
00130 {
00131 return smoothingFactor;
00132 }
00133
00137 int getForcedBitDepth() const
00138 {
00139 return forcedBitDepth;
00140 }
00141
00145 Uint32 getFragmentSize() const
00146 {
00147 return fragmentSize;
00148 }
00149
00153 OFBool getCreateOffsetTable() const
00154 {
00155 return createOffsetTable;
00156 }
00157
00161 E_SubSampling getSampleFactors() const
00162 {
00163 return sampleFactors;
00164 }
00165
00170 OFBool getWriteYBR422() const
00171 {
00172 return writeYBR422;
00173 }
00174
00178 OFBool getConvertToSC() const
00179 {
00180 return convertToSC;
00181 }
00182
00186 E_UIDCreation getUIDCreation() const
00187 {
00188 return uidCreation;
00189 }
00190
00194 unsigned long getWindowType() const
00195 {
00196 return windowType;
00197 }
00198
00202 unsigned long getWindowParameter() const
00203 {
00204 return windowParameter;
00205 }
00206
00211 void getVOIWindow(double& center, double& width) const
00212 {
00213 center = voiCenter;
00214 width = voiWidth;
00215 }
00216
00223 void getROI(
00224 unsigned long& left_pos,
00225 unsigned long& top_pos,
00226 unsigned long& width,
00227 unsigned long& height) const
00228 {
00229 left_pos = roiLeft;
00230 top_pos = roiTop;
00231 width = roiWidth;
00232 height = roiHeight;
00233 }
00234
00238 E_PlanarConfiguration getPlanarConfiguration() const
00239 {
00240 return planarConfiguration;
00241 }
00242
00246 E_CompressionColorSpaceConversion getCompressionColorSpaceConversion() const
00247 {
00248 return compressionCSConversion;
00249 }
00250
00254 E_DecompressionColorSpaceConversion getDecompressionColorSpaceConversion() const
00255 {
00256 return decompressionCSConversion;
00257 }
00258
00262 OFBool getUsePixelValues() const
00263 {
00264 return usePixelValues;
00265 }
00266
00270 OFBool getUseModalityRescale() const
00271 {
00272 return useModalityRescale;
00273 }
00274
00278 OFBool isVerbose() const
00279 {
00280 return verboseMode;
00281 }
00282
00283 private:
00284
00286 DJCodecParameter& operator=(const DJCodecParameter&);
00287
00289 E_CompressionColorSpaceConversion compressionCSConversion;
00290
00292 E_DecompressionColorSpaceConversion decompressionCSConversion;
00293
00295 E_PlanarConfiguration planarConfiguration;
00296
00298 OFBool optimizeHuffman;
00299
00301 int smoothingFactor;
00302
00304 int forcedBitDepth;
00305
00307 Uint32 fragmentSize;
00308
00310 OFBool createOffsetTable;
00311
00313 E_SubSampling sampleFactors;
00314
00318 OFBool writeYBR422;
00319
00321 OFBool convertToSC;
00322
00324 E_UIDCreation uidCreation;
00325
00327 unsigned long windowType;
00328
00330 unsigned long windowParameter;
00331
00333 double voiCenter;
00334
00336 double voiWidth;
00337
00339 unsigned long roiLeft;
00340
00342 unsigned long roiTop;
00343
00345 unsigned long roiWidth;
00346
00348 unsigned long roiHeight;
00349
00351 OFBool usePixelValues;
00352
00354 OFBool useModalityRescale;
00355
00357 OFBool verboseMode;
00358 };
00359
00360
00361 #endif
00362
00363
00364
00365
00366
00367
00368
00369
00370
00371
00372
00373
00374
00375
00376
00377
00378
00379