Presentation states


What is a Presentation State ?

A Presentation State is an independent DICOM SOP Instance that contains information on how a particular image should be displayed. The Presentation State may contain label information(types of Label and Positions), windowing values, zoom value, scrolling (panning) values, rotations or any other visual display element that is defined within the DICOM standard. However Presentation States contain no Pixel Data as they are intended for use with an existing Dicom Image. A presentation state can be applied to an image so that the image is displayed with all the visual specifications defined by that presentation state. The advantage of using presentation states is that you can always revert back to the original image as the underlying pixel data is not modified but rather displayed differently. Presentation states can be sent to a PACS (Provided the PACS supports the Presentations state SOP classes) and retrieved when required.

Using Presentation States with DicomObjects

DicomObjects fully supports presentation states. DicomObjects can be used to create Presentations states from scratch or to apply an existing presentation states to an image. After all the necessary display changes have been made to an image you can create a Presentation state. With VB6.0 use the following Code:

Apply this code after the display changes have been made to the image:

Dim PImage As DicomImage
Set PImage = Dicomviewer1.CurrentImage
PImage.CurrentToPresentationState (True)
PSpath = "c:\MyPStatesFolder"
PImage.PresentationState.WriteFile PSpath & "\PS01", True, "1.2.840.10008.1.2.1", 1
MsgBox " This presentation sate has been saved with file name PS01"

The presentation state can then be used in conjunction with the original image as and when required. If so desired the presentation state could be sent to a server using the Send method for retrieval at a later time.

And to apply an existing Presentation State to an Image with DicomObjects in VB6.0.

Dim g As New DicomGlobal
Dim ps As New DicomDataSet
'The Presentation State does not have to be read from disk it could
'be retrieved from a server.
Set ps = g.ReadFile(PSpath & "\PS01")
DicomViewer1.CurrentImage.PresentationState = ps

Normally, a Presentation State completely controls the display of an image, so PresentationStateToCurrent is required if you wish to modify display settings after a presentation state is applied to the DicomImage. This modifies all the current properties of the image and its labels collection to match those of the presentation state, then sets the actual PresentationState to null, allowing changes to be made.


An example showing how to use Presentation States with DicomObjects is available on request from Medical Connections.

Applying Presentation States to Multiple Images in the Series

According to the following table taken from the part 3 of DICOM Standard, one Presentation State can be applied to more than one images in the Series.

Following sample VB.NET code demonstrates how to make a Presentation State which can apply to 2 different images. In DO.NET. Slight modification will be required if using COM version of DicomObjects.

Dim PSObject As DicomDataSet
Dim Image2 As DicomImage

Image1.CurrentToPresentationState(Image1.Size, True)

'Create Presentation State Object
PSObject = Image1.PresentationState

Dim Referenced_Series_Sequence As New DicomDataSetCollection
Dim Referenced_Series_Sequence_Item As New DicomDataSet
Dim Referenced_Image_Sequence As New DicomDataSetCollection
Dim Referenced_Image_Sequence_Item As New DicomDataSet

'Find existing series sequence to add new item to
PSObject = Image1.PresentationState

Referenced_Series_Sequence = PSObject(&H8, &H1115).Value
Referenced_Series_Sequence_Item = Referenced_Series_Sequence(0)
Referenced_Image_Sequence = Referenced_Series_Sequence_Item(&H8, &H1140).Value

'Create new item for new image to add to that sequence
Referenced_Image_Sequence_Item.Add(&H8, &H1150, Image2.SOPClass)
Referenced_Image_Sequence_Item.Add(&H8, &H1155, Image2.InstanceUID)

'Add the new dataset to the sequence

'Save Presentation State to File
PSObject.Write("c:\PS1", "1.2.840.10008.1.2.1")


Applying Presentation States to Multiple Series in the Study

To apply Presentation States to Multiple Series in the Study, just add one or more new Series into the "Referenced Series Sequence (0008, 1115)", with each of the new Series containing its own list of instances in the "Referenced Image Sequence (0008, 1140)".