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

Add ability to parse untilTag and to stopAfterTag with namified or Group,Element syntax #149

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jmhmd
Copy link
Contributor

@jmhmd jmhmd commented Sep 7, 2020

Adds DicomMessage.readFile() options untilTag and stopAfterTag that terminate parsing and return the so far parsed data either up to or including the given tag. Adds normalization of namified or group,element type tags.

Use:

dicomData = dcmjs.data.DicomMessage.readFile(part10Buffer, {
    untilTag: 'StudyInstanceUID', // OR
    untilTag: '(0020,000D)', // OR
    stopAfterTag: 'PatientName', // OR
    stopAfterTag: 'x00100010', // etc...
});

Group,Element formats parsed:

(0028,7017)
[0028,7017]
0028,7017
00287017
x00287017

…r Group,Element syntax

# Conflicts:
#	src/DicomMessage.js
#	test/test_data.js
…r Group,Element syntax

# Conflicts:
#	src/Tag.js
#	test/test_data.js
Copy link
Collaborator

@pieper pieper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great 👍

Just needs to rebased after earlier PR was merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants