Frame Level Retrieval

Frame Level Retrieval (DICOM Supplement 119) is written by Dr. David Harvey, our managing director, and is fully supported by DicomObjects.

There are 2 (actually 3, with the 3rd one using Content Time values to specify a Time Range) ways to ask for specific frames:

Simple Frame List

Contains a list of frame numbers, each specifying a frame to be included in the returned object.

Calculated Frame List

Calculated Frame List (0008,1162) is a multi-valued attribute containing a list of 3-tuples, each representing a sub-range of frames to be included in the returned object.

  • The first number shall be the frame number of the first frame of the sub-range
  • The second number shall be the upper limit of the sub-range, and shall be greater than or equal to the first number
  • The third number shall be the increment between requested frames of the sub-range

Sample Code

Below is very simple C# code to show how to perform a simple C-GET/C-MOVE request to retrieve some frames from a multi-frame DICOM image, using DicomObjects.NET version:

DicomQuery q = new DicomQuery ();
q.Node = ip;
q.Port = port;
q.CallingAE = localAET;
q.CalledAE = serverAET;

q.Root = DicomObjects.Enums.QueryRoot.CompositeInstance;
q.Level = DicomObjects.Enums.QueryLevel.FRAME;

DicomDataSet queryDataSet = q.QueryDataSet();
queryDataSet.Add(Keyword.QueryRetrieveLevel, "FRAME");
queryDataSet.InstanceUID = InstanceUID;

if (simpleFrameList)
{
     int[] frames = new int[] {1, 3, 5, 7, 9, 11, 22, 54 }; // Asking for frame 1, 3, 5, 7, 9, 11, 22 and 54
     queryDataSet.Add(Keyword.SimpleFrameList, frames);
}
else if (calculatedFrameList)
{
     int[] frames = new int[] {1, 10, 4, 11, 20, 5, 22, 30, 2 }; // Asking for frame 1, 5, 9, 11, 16, 22, 24, 26, 28 and 30
     queryDataSet.Add(Keyword.CalculatedFrameList, frames);
}

if (CGET) // C-GET
{
    DicomDataSetCollection results = q.Get(queryDataSet);
}
else if (CMOVE) // C-MOVE
{
      queryDataSet.Add(Keyword.MoveDestination, moveDestination);
      q.Move(queryDataSet);
}

 

A complete c# sample project (Frame Level Retrival Client) can be downloaded from the Examples page.

 

 

 

Relevance: