-
Notifications
You must be signed in to change notification settings - Fork 184
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2767 from MRtrix3/allow_DICOM_header_read_with_un…
…supported_transfer_syntax DICOM: add null imageIO handler to allow parsing of DICOM data even with unsupported transfer syntax
- Loading branch information
Showing
4 changed files
with
147 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/* Copyright (c) 2008-2025 the MRtrix3 contributors. | ||
* | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
* | ||
* Covered Software is provided under this License on an "as is" | ||
* basis, without warranty of any kind, either expressed, implied, or | ||
* statutory, including, without limitation, warranties that the | ||
* Covered Software is free of defects, merchantable, fit for a | ||
* particular purpose or non-infringing. | ||
* See the Mozilla Public License v. 2.0 for more details. | ||
* | ||
* For more details, see http://www.mrtrix.org/. | ||
*/ | ||
|
||
#include "image_io/null.h" | ||
#include "header.h" | ||
|
||
namespace MR { | ||
namespace ImageIO { | ||
|
||
void Null::load(const Header &header, size_t) { | ||
throw Exception("No suitable handler to access data in \"" + header.name() + | ||
"\""); | ||
} | ||
|
||
void Null::unload(const Header &header) { | ||
throw Exception("No suitable handler to access data in \"" + header.name() + | ||
"\""); | ||
} | ||
|
||
} // namespace ImageIO | ||
} // namespace MR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/* Copyright (c) 2008-2025 the MRtrix3 contributors. | ||
* | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
* | ||
* Covered Software is provided under this License on an "as is" | ||
* basis, without warranty of any kind, either expressed, implied, or | ||
* statutory, including, without limitation, warranties that the | ||
* Covered Software is free of defects, merchantable, fit for a | ||
* particular purpose or non-infringing. | ||
* See the Mozilla Public License v. 2.0 for more details. | ||
* | ||
* For more details, see http://www.mrtrix.org/. | ||
*/ | ||
|
||
#ifndef __image_io_null_h__ | ||
#define __image_io_null_h__ | ||
|
||
#include "image_io/base.h" | ||
|
||
namespace MR { | ||
namespace ImageIO { | ||
|
||
class Null : public Base { | ||
NOMEMALIGN | ||
public: | ||
Null(const Header &header) : Base(header) {} | ||
|
||
protected: | ||
virtual void load(const Header &, size_t); | ||
virtual void unload(const Header &); | ||
}; | ||
|
||
} // namespace ImageIO | ||
} // namespace MR | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters