L_DicomChannelGetSamples

#include "Ltdic.h"

* L_LTDIC_API L_INT32 L_DicomChannelGetSamples(hDICOMWaveFormChannel, puNumberOfSamples)

HDICOMWAVEFORMCHANNEL hDICOMWaveFormChannel;

/* a DICOM waveform channel handle */

L_UINT32* puNumberOfSamples;

/* pointer to a variable to be updated */

Gets the samples (data) for a waveform channel.

Parameter

Description

hDICOMWaveFormChannel

A DICOM waveform channel handle

puNumberOfSamples

Pointer to a variable to be updated with the number of samples for the channel.

Returns

!NULL

Pointer to a buffer that holds the channel samples.

NULL

Channel has no samples set.

Comments

This function returns a pointer to a buffer that holds the channel samples (data). If puNumberOfSamples is not NULL then it gets updated with the number of samples for the channel.

Please note that the data is always encapsulated as 32-bit regardless of the bits allocated for the channel (8- or 16-bit). You can tell if the data for the channel is 8- or 16-bit from the waveform sample interpretation. For 8-bit channels the "Waveform Sample Interpretation" (5400,1006) can either be signed 8-bit linear (DICOM_SAMPLE_INTERPRETATION_SB), unsigned 8-bit linear (DICOM_SAMPLE_INTERPRETATION_UB), 8-bit mu-law (DICOM_SAMPLE_INTERPRETATION_MB) or 8-bit A-law(DICOM_SAMPLE_INTERPRETATION_AB). For 16-bit channels the "Waveform Sample Interpretation" can either be signed 16-bit linear (DICOM_SAMPLE_INTERPRETATION_SS) or unsigned 16-bit linear (DICOM_SAMPLE_INTERPRETATION_US). Use the L_DicomWaveGrpGetSampleInterpretation function to get the waveform sample interpretation.

Note: This function returns a pointer to an internal buffer that is managed by the toolkit. Therefore, you should not free it when you are done with it.

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:

L_DicomChannelSetSamples8, L_DicomChannelSetSamples16, L_DicomChannelSetSamples32, L_DicomChannelGetWaveformGroup, L_DicomWaveGrpGetNumberOfChannels, L_DicomWaveGrpGetChannel, L_DicomWaveGrpAddChannel, L_DicomWaveGrpDeleteChannel

Topics:

Working with DICOM Waveforms

Example

For an example, refer to L_DicomChannelSetSamples8.