Package com.pixelmed.convert

# Class RawRGBToDicomMultiFrame

java.lang.Object
com.pixelmed.convert.RawRGBToDicomMultiFrame

public class RawRGBToDicomMultiFrame extends Object

A class for converting raw RGB color single frame image input format files (such as from Visible Human) into one or more DICOM multi-frame secondary capture images.

## Constructor Summary

Constructors
Constructor
Description
`RawRGBToDicomMultiFrame(String formatFileName, String inputFolderName, String inputFileNameSuffix, String outputFolderName, String patientName, String patientID, String studyID, String seriesNumber)`
Read raw RGB color single frame image input format files (such as from Visible Human) into one or more DICOM multi-frame secondary capture images.

## Method Summary

Modifier and Type
Method
Description
`static AttributeList`
`generateDICOMPixelDataModuleAttributesFromRawRGBFiles(String[] inputFileNames, String inputFileNameSuffix, RawRGBInformation rawRGBInfo, AttributeList list)`
Create DICOM Pixel Data Module attributes.
`static AttributeList`
`generateGeometryFunctionalGroupsFromRawRGBInformation(RawRGBInformation rawRGBInfo, AttributeList list, int numberOfFrames)`
Read a per-frame and shared functional group sequences for the geometry defined in a raw image file description.
`protected static String[]`
`getSortedInputFileNames(String inputFolderName, String inputFileNameSuffix)`
`static void`
`main(String[] arg)`
Read raw RGB color single frame image input format files (such as from Visible Human) into one or more DICOM multi-frame secondary capture images.

### Methods inherited from class java.lang.Object

`clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### RawRGBToDicomMultiFrame

public RawRGBToDicomMultiFrame(String formatFileName, String inputFolderName, String inputFileNameSuffix, String outputFolderName, String patientName, String patientID, String studyID, String seriesNumber) throws IOException, DicomException

Read raw RGB color single frame image input format files (such as from Visible Human) into one or more DICOM multi-frame secondary capture images.

Will obtain the description of the geometry of the raw RGB files, e.g., a Visible Human README file, from the specified format description file.

The order of the frames is assumed to be by their lexicographically sorted file name (hence numeric file names need to be the same length, e.g., zero-padded.

Parameters:
  `formatFileName` -
  `inputFolderName` -
  `inputFileNameSuffix` -
  `outputFolderName` -
  `patientName` -
  `patientID` -
  `studyID` -
  `seriesNumber` -
Throws:
  `IOException`
  `DicomException`

## Method Details

### generateGeometryFunctionalGroupsFromRawRGBInformation

public static AttributeList generateGeometryFunctionalGroupsFromRawRGBInformation(RawRGBInformation rawRGBInfo, AttributeList list, int numberOfFrames) throws DicomException

Read a per-frame and shared functional group sequences for the geometry defined in a raw image file description.

Parameters:
  `rawRGBInfo` - description of the size of the raw image
  `list` - an existing (possibly empty) attribute list, if null, a new one will be created; may already shared and per-frame functional group sequences or they will be added
  `numberOfFrames` - return attribute list with per-frame and shared functional group sequences for geometry added
Throws:
  `DicomException`

### generateDICOMPixelDataModuleAttributesFromRawRGBFiles

public static AttributeList generateDICOMPixelDataModuleAttributesFromRawRGBFiles(String[] inputFileNames, String inputFileNameSuffix, RawRGBInformation rawRGBInfo, AttributeList list) throws IOException, DicomException

Create DICOM Pixel Data Module attributes.

Parameters:
  `inputFileNames` - the single frame raw RGB format image files sorted in the correct order
  `inputFileNameSuffix` - so we can tell whether or not the input files are compressed
  `rawRGBInfo` - description of the size of the raw image already read from the inputFile
  `list` - an existing (possibly empty) attribute list, if null, a new one will be created; may already include "better" image pixel module attributes to use return attribute list with Image Pixel Module (including Pixel Data) and other attributes added
Throws:
  `IOException`
  `DicomException`

### getSortedInputFileNames

protected static String[] getSortedInputFileNames(String inputFolderName, String inputFileNameSuffix) throws IOException

Throws:
  `IOException`

### main

public static void main(String[] arg)

Read raw RGB color single frame image input format files (such as from Visible Human) into one or more DICOM multi-frame secondary capture images.

Will obtain the description of the geometry of the raw RGB files, e.g., a Visible Human README file, from the specified format description file.

Parameters:
  `arg` - eight parameters, the format description file, inputFolder, inputFileNameSuffix, outputFolder, patientName, patientID, studyID, seriesNumber