Mercurial > hg > orthanc
comparison Core/Enumerations.cpp @ 2381:b8969010b534
uncoupling DCMTK primitives from Orthanc::Configuration
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 29 Aug 2017 19:59:01 +0200 |
parents | e002430baa41 |
children | 7284093111b0 |
comparison
equal
deleted
inserted
replaced
2380:96b3ec054b69 | 2381:b8969010b534 |
---|---|
1473 | 1473 |
1474 case ValueRepresentation_NotSupported: | 1474 case ValueRepresentation_NotSupported: |
1475 default: | 1475 default: |
1476 throw OrthancException(ErrorCode_ParameterOutOfRange); | 1476 throw OrthancException(ErrorCode_ParameterOutOfRange); |
1477 } | 1477 } |
1478 } | 1478 } |
1479 | |
1480 | |
1481 static boost::mutex defaultEncodingMutex_; // Should not be necessary | |
1482 static Encoding defaultEncoding_ = ORTHANC_DEFAULT_DICOM_ENCODING; | |
1483 | |
1484 Encoding GetDefaultDicomEncoding() | |
1485 { | |
1486 boost::mutex::scoped_lock lock(defaultEncodingMutex_); | |
1487 return defaultEncoding_; | |
1488 } | |
1489 | |
1490 void SetDefaultDicomEncoding(Encoding encoding) | |
1491 { | |
1492 std::string name = EnumerationToString(encoding); | |
1493 | |
1494 { | |
1495 boost::mutex::scoped_lock lock(defaultEncodingMutex_); | |
1496 defaultEncoding_ = encoding; | |
1497 } | |
1498 | |
1499 LOG(INFO) << "Default encoding for DICOM was changed to: " << name; | |
1500 } | |
1501 | |
1479 } | 1502 } |