DeleteBitmapValue method

Delphi example

C++Builder example

 

Builder Syntax

int __fastcall DeleteBitmapValue(Cardinal uIndex, Cardinal uCount);

Delphi Syntax

function DeleteBitmapValue(uIndex: Cardinal; uCount: Cardinal): Integer;

Overview

Refer to Working with Data Sets.

Remarks

This method deletes the image(s) in the Pixel Data Element starting at the specified index and continuing for the specified count.

As an example, if you wish to delete 50 images starting with the 50th frame in the Pixel Data, call this method with uIndex set to 49 (the 50th frame in a zero-based index) and uCount set to 50.

Most DICOM files will only have one Data Element of type TAG_PIXEL_DATA. Therefore, in most instances the CurrentElement property can be Nil (NULL), since the method will automatically delete the images of the only Pixel Data Element in the file. If the CurrentElement property is not Nil, it must contain the Pixel Data Element itself.

If the DICOM file is CLASS_BASIC_DIRECTORY, the file may contain more than one Pixel Data Element. In this case you must specify in the CurrentElement property the Pixel Data Element from which to delete the images.

If you wish to replace only one image within the Pixel Data Element, you must use DeleteBitmapValue method and InsertBitmapValue method.

See Also

Elements:

GetBitmapValue method, GetBitmapListValue method, InsertBitmapValue method, InsertBitmapListValue method, SetBitmapListValue method, SetBitmapListValue method, DeleteBitmapValue method