Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Development #902

Merged
merged 4 commits into from
Dec 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions console/makefile
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
# Regular use
CFLAGS=-s -O3

# Universal files used for everything
UFILES=main_console.cpp nii_foreign.cpp nii_dicom.cpp jpg_0XC3.cpp ujpeg.cpp nifti1_io_core.cpp nii_ortho.cpp nii_dicom_batch.cpp -o dcm2niix -DmyDisableOpenJPEG
# Common files used for everything
CFILES=main_console.cpp nii_foreign.cpp nii_dicom.cpp jpg_0XC3.cpp ujpeg.cpp nifti1_io_core.cpp nii_ortho.cpp nii_dicom_batch.cpp -o dcm2niix

# Universal files used for almost everything
UFILES=$(CFILES) -DmyDisableOpenJPEG
# Debugging
#CFLAGS=-g

Expand Down Expand Up @@ -55,6 +58,9 @@ sanitize:
debug:
g++ -O0 $(LFLAGS) $(UFILES)

jp2:
g++ -O0 $(LFLAGS) $(CFILES) -I/opt/homebrew/Cellar/openjpeg/2.5.3/include/openjpeg-2.5/ -L/opt/homebrew/Cellar/openjpeg/2.5.3/lib/ -lopenjp2

noroi:
g++ $(CFLAGS) -I. $(JSFLAGS) $(JFLAGS) $(LFLAGS) $(UFILES) -DmyNoRois

Expand Down
4 changes: 4 additions & 0 deletions console/nii_dicom.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5403,6 +5403,10 @@ struct TDICOMdata readDICOMx(char *fname, struct TDCMprefs *prefs, struct TDTI4D
} else if ((compressFlag != kCompressNone) && (strcmp(transferSyntax, "1.2.840.10008.1.2.4.90") == 0)) {
d.compressionScheme = kCompressYes;
// printMessage("JPEG2000 Lossless support is new: please validate conversion\n");
} else if ((compressFlag != kCompressNone) && (strcmp(transferSyntax, "1.2.840.10008.1.2.4.201") == 0)) {
d.compressionScheme = kCompressYes; //High-Throughput JPEG 2000 issue 897
} else if ((compressFlag != kCompressNone) && (strcmp(transferSyntax, "1.2.840.10008.1.2.4.203") == 0)) {
d.compressionScheme = kCompressYes; //High-Throughput JPEG 2000 issue 897
} else if ((strcmp(transferSyntax, "1.2.840.10008.1.2.1.99") == 0)) {
// n.b. Deflate compression applied applies to the encoding of the **entire** DICOM Data Set, not just image data
// see https://www.medicalconnections.co.uk/kb/Transfer-Syntax/
Expand Down
2 changes: 1 addition & 1 deletion js/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ <h1>dcm2niix WASM Demo</h1>
const t0 = performance.now();

const inputFileList = selectedFiles
const resultFileList = await dcm2niix.input(inputFileList).run()
const resultFileList = await dcm2niix.input(inputFileList).z('y').run()
console.log(resultFileList);

const t1 = performance.now();
Expand Down
4 changes: 2 additions & 2 deletions js/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@niivue/dcm2niix",
"version": "0.1.1-dev.2",
"version": "1.0.0",
"main": "dist/index.js",
"module": "dist/index.js",
"exports": {
Expand Down
Loading