When key images are selected for an interesting case in RadICS, the original DICOM file is archived with the associated, newly generated JPEG files in permanent file storage.7
After the case creation is complete, the case information and images are displayed in the Case Display, JSP-driven webpage (Fig. ). By default, the large version of the first image in the case is shown; clicking a thumbnail image will show its larger version (Fig. ). For case authors, an “Edit Image” link is present below the large image on the webpage. When the link is clicked, the case author is presented with a modified, open source Java DICOM viewer applet (Fig. ).
Fig. 1 The case information and images are displayed in the Case Display JSP-driven webpage. When the case author selects to edit an image, the original or resized DICOM image in permanent file storage is opened in the Java-based Optimization Applet. After window (more ...)
A completed interesting case in the RadICS, prior to optimization of the images.
Fig. 3 When the radiologist clicks on the “Edit Image” link, the selected image is displayed in a modified, open-source Java DICOM viewer applet. The radiologist is able to adjust the window and level of the image according to the diagram provided (more ...)
The open source Java DICOM viewer was obtained from the Nagoya Institute of Technology and modified to display only the selected image.8
The Java DICOM viewer is embedded as an applet in a JSP webpage, allowing the optimization tool to be presented to the author via any commonly used web browser. The only requirement is installation of the JRE version 5.0 or more recent. It was also modified to allow exchange of user-defined crop and window and level settings with servlets. Window and level values and cropping boundaries for the selected image are retrieved from the database and dynamically added as parameters nested under the HTML APPLET tag. If window and level values are not set in the database, the WindowLevel and WindowWidth DICOM header elements are used. Parameters are also set to communicate the unique case and image identifiers and modality of the selected image to the applet. The values of these HTML parameters are accessed within the applet using the getParameter method. As the DICOM viewer begins to run, it uses the window and level parameter values as the image defaults. After displaying the full image with these settings, a rectangle representing the cropping boundary is overlaid. In the absence of cropping boundary values, the image is displayed without an overlay.
There is a wide range of DICOM image sizes (i.e., typical magnetic resonance images are 256
256 pixels, whereas typical chest plain films are 1,760
2,140 pixels). Displaying large images in the applet requires a significant amount of memory resources on the client workstation because all image data are represented as Java objects, not downloaded as separate temporary image files. In addition, the spatial resolution limitations of displaying the entire web page on the screen without needing to scroll would require larger images to be scaled down. To address this, the resolution of the selected image is determined by row and column elements in the DICOM header. These values are stored in the MySQL database at the time of key image selection. If the image is 512
512 or smaller, the DICOM image data is displayed in the applet at actual size. If the image is larger than 512
512, the image is scaled down and stored as a new DICOM file. For rectangular images, the longest dimension is resized to 512 pixels and the other dimension is scaled proportionally. This smaller DICOM image is displayed in the applet.
The applet provides the user with “windowing” and “leveling” functionality by clicking and holding the left mouse button while dragging across the image. Users are provided this instruction as an adjacent diagram on the same web page. (Fig. -circle). The applet shows the window and level changes immediately in a real-time, PACS-like fashion familiar to radiologists. In addition, the window and level values are displayed as text in the bottom left corner of the applet for reference. The user can define cropping boundaries by clicking and holding the right mouse button while dragging across the image to create a square or rectangle around the desired focus of the image. An overlay is used to show cropping boundaries instead of displaying only image data within the boundaries. This allows the user to redefine more appropriate cropping boundaries in context of the full image. The relative x and y position along with the width and height of the cropping boundary are stored within the applet. The x and y position identify the pixel that will be the top, left pixel of the cropped image. The width and height of the boundary designate the number of pixels that enclose the desired focus of the image.
The case author is given the option to apply the window and level settings to all images in the same series or just to the selected image. The author is instructed to click on the “Submit Changes” button in the applet after adjustments are made (Fig. -circle). Clicking this button triggers the applet to create a uniform resource locator (URL) with parameters for window and level and crop settings, and the unique case identifier, image identifier, and image modality and whether to apply the window and level settings to all images in the same series. The applet passes this URL to the browser using the showDocument method. A servlet, invoked by the browser request, uses the URL parameters to generate new thumbnail and full-size JPEG images that reflect the desired window and level settings and crop adjustments. The DICOM-to-JPEG conversion is done using the OFFIS DICOM Toolkit (DCMTK).9
The new JPEG images are then cropped using ImageMagick, an open-source tool commonly installed on Linux servers.10
Although the resized DICOM image is displayed in the applet, all optimization adjustments are performed using the original full-size DICOM file, which always remains unchanged. The thumbnail JPEG is proportionally constrained to 128 pixels on its longest dimension. The larger JPEG file maintains the same spatial resolution as the full-size DICOM file (Fig. ).
After making the desired changes, the radiologist clicks on the “Submit Changes” button in the applet (circle). New thumbnail and full-size JPEG images are generated using the user-defined, optimum window and level settings.
The radiologist is instantaneously directed back to the interesting case in the RadICS displaying the newly generated JPEG images.