Products | Support | Send comments on this topic. | Email a link to this topic. | Back to Getting Started | Help Version 18.0.10.23
LEADTOOLS DICOM C++ Class Library Help

LDicomDS::GetModalityLUTAttributes

Show in webframe

#include "ltdic.h"

L_UINT16 LDicomDS::GetModalityLUTAttributes(uFrameIndex, pModalityLUTAttributes, uStructSize, uFlags)

L_UINT32 uFrameIndex;

/* index value */

pDICOMMLUTATTRIBS pModalityLUTAttributes;

/* pointer to a structure */

L_UINTuStructSize;

/* size of a structure */

L_UINT uFlags;

/* reserved for future use */

Retrieves the attributes that describe the Modality LUT.

Parameter

Description

uFrameIndex

A zero-based index that identifies the frame number in the dataset.  If the dataset does not support Multi-frames, this parameter is ignored.

pModalityLUTAttributes

Pointer to a structure to be updated with the Modality LUT attributes.

uStructSize

Size of the DICOMMLUTATTRIBS structure. Pass sizeof(DICOMMLUTATTRIBS).

uFlags

Reserved for future use. Pass 0.

Returns

0

The function was successful.

> 0

An error occurred. Refer to Return Codes.

Comments

This function will retrieve the attributes of the "Modality LUT Module" and store their values in the structure pointed to by pModalityLUTAttributes.

pModalityLUTAttributes->uStructSize will be set to the value of the parameter uStructSize.

If the function doesnt find any of the attributes of the "Modality LUT Module" it will set both pModalityLUTAttributes->bIsModalityLUTSequence and

pModalityLUTAttributes->bIsRescaleSlopeIntercept to FALSE. In this case the rest of the members of the pModalityLUTAttributes structure are undefined.

If the function finds the "Rescale Intercept" (0028,1052) and "Rescale Slope" (0028,1053) elements, it will set pModalityLUTAttributes->bIsRescaleSlopeIntercept to TRUE and populate pModalityLUTAttributes->RescaleIntercept, pModalityLUTAttributes->RescaleSlope and pModalityLUTAttributes->szRescaleType with the values retrieved from the DICOM dataset.

If the function finds "Modality LUT Sequence" (0028,3000), it will set pModalityLUTAttributes->bIsModalityLUTSequence to TRUE and populate pModalityLUTAttributes->LUTDescriptor, pModalityLUTAttributes->pszLUTExplanation and pModalityLUTAttributes->szModalityLUTType with the values retrieved from the DICOM dataset.

It is prohibited by the DICOM standard for both "Rescale Intercept" and "Modality LUT Sequence" to exist in the same DICOM dataset. However if this function encounters such a dataset, it will ignore "Modality LUT Sequence" and assume that only "Rescale Intercept" exists.

The Multi-frame Functional Groups module may have a Shared Functional Groups Sequence item, and/or a Per-frame Functional Groups Sequence item. Either of these items may have a Pixel Value Transformation Sequence (0028,9145) item. If the following elements are not found at the top level in the dataset, this method looks in the Shared Functional Groups Sequence item and the Per-frame Functional Groups Sequence items.

Tag

Name

(0028,1052)

Rescale Intercept

(0028,1053)

Rescale Slope

(0028,1054)

Rescale Type

For a detailed discussion on Multi-frame Functional Groups and how the DICOM_SET_IMAGE_MFG flags are used, see the topic Multi-frame Functional Groups.

Required DLLs and Libraries

LTDIC

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application

Platforms

Win32, x64

See Also

Functions:

LDicomDS::GetModalityLUTData, LDicomDS::SetModalityLUT, LDicomDS::DeleteModalityLUT, Class Members

Topics:

LUT Encoding Overview

 

LUT Encoding: Modality LUT

 

How to Disable the Automatic Loading of the default DICOM IOD Table

Example

For an example, refer to LDicomDS::GetModalityLUTData.

Products | Support | Contact Us | Copyright Notices
© 2006-2014 All Rights Reserved. LEAD Technologies, Inc.