Open Heyex Raw Files


Kris Sheets (ksheet at


2010/09/25 (v1.0):  First version

2010/09/30 (v1.1):  SLO image now has overlay annotating position of B-scan lines. Fixed bug with NaN values in segmentation layers and total retinal thickness.

2010/10/04 (v1.2):  Fixed bug with TRT in 3D files.  Open_Heyex_Raw now includes Log window with exam information.  Results table now includes B-Scan quality in dB.  Greatly improved speed throughout.  Added Open_Heyex_Results and Open_Heyex_Info.

2010/10/13 (v1.3):  Now correctly interprets OCT data exported from Spectralis v5.0

2011/08/16 (v2.0):  Complete overhaul.  The previous five plugins are now public methods within the Open_Heyex_Raw class.  Method calls are loaded into the Plugins>Open Heyex Raw subfolder.  The previous plugins are included within the jar for backwards compatability with users calling the plugins from macros.




Save Open_Heyex_Raw.jar to the plugins folder and restart ImageJ.


Results table with segmented layer values is slow for 3D-OCT files.  Improved in v1.2 but depending on 3D oct size, it may still be quite slow.  Presently, results seem much faster using ImageJ 64-bit on Mac OS X than on Windows XP 64bit.  Exam time and Scan Pattern included with v1.2 Info Log are not correct, working on a fix. There is no change to these limitations in v2.0.  Not tested for clinical or diagnostic use (see disclaimer below).


This plugin is intended to expand the compatability of Heidelberg OCT raw files, allowing investigators to view, share, and analyze Heidelberg Spectralis OCT images using ImageJ.  They are provided on an "As Is" basis and it is the responsibility of the investigator to verify correct interpretation of raw files.  These plugins are not tested, nor intended, for clinical or diagnostic use.  For such purposes, use of Heidelberg Spectralis software only is recommended.


If this plugin aids your investigations, please cite the following.

Exp Eye Res. 2011 Feb;92(2):155-60. Epub 2010 Oct 28.

Spatial correlation of mouse photoreceptor-RPE thickness between SD-OCT and histology.

Knott EJ, Sheets KG, Zhou Y, Gordon WC, Bazan NG.

Neuroscience Center of Excellence, Louisiana State University Health Sciences Center, New Orleans, LA 70112, USA.

PubMed ID: 21035444


These plugins interpret raw binary files exported from Heidelberg Spectralis Viewing Software.  They successfully import both 8-bit SLO and 32-bit SD-OCT images, retaining pixel scale (optical and SD-OCT), segmentation data, and B-scan position relative to the SLO image (included in v1.1+).  In addition to single B-scan SD-OCT images, the plug-in also opens multiple B-scan SD-OCT images as a stack, enabling 3-D reconstruction, analysis, and modeling.  The plug-in is compatible with Spectralis Viewing Module exporting raw data in HSF-OCT-### format.  Compatability has been tested with HSF-OCT-101, 102, and 103.  If you are using a different HSF-OCT version please contact me.  I will update the compatability list  or amend the plugin as necessary. Scan patterns of single line, volume in ART mode, and fast volume, were all successfully tested. 

I have been experimenting an algorithm that processes small animal OCT images to produce signal quality more similar to that observed in human OCT scans.  If interested please email me.

Proper lateral (optical) scale depends upon corneal curvature values entered in the patient exam information prior to raw export.  The Heidelberg Spectralis has a default corneal curvature value suitable for a human eye.  When working with small animals, such as mice, the optical properties of the eye are significantly different and require adjustment of the corneal curvature value.  In our paper (see citation) we adjusted corneal curvature values until the lateral measurements matched those of histologic sections.  Others (Fischer et al., 2009 and Huber et al., 2009) have injected micron-sized beads and adjusted corneal curvature until they were spherical in measure.  To ensure proper lateral scale, corneal curvature values must be changed accordingly prior to exporting the raw file.

All OCT images are displayed as 1:1 pixel ratio.  Adjusting an image to a 1:1 µm ratio can easily be done by stretching the A-scan data axially (Y scale) or by shrinking the A-scan data laterally (X scale).  Stretching will introduce interpolation artifacts such as aliasing, blurring and edge halos.  Shrinking, however, will eliminate data points and depending on the resolution difference between the dimensions, this may result in an unacceptably small image.  For 20° x 15° 3D OCT scans of mouse retina, we stretch A-scan data in the axial direction using bicubic interpolation.

To Stretch, scale the image as:

X Scale: 1.0

Y Scale: Pixel Height ÷ Pixel Width

To Shrink, scale the image as:

X Scale: Pixel Width ÷ Pixel Height

Y Scale: 1.0

Six opening methods are available.  All methods are located in the Plugins>Open Heyex Raw subfolder.

  1. Open OCT
    • opens only the OCT image in a 1:1 pixel ratio.  B-scans are opened in 32-bit format and appear darker than the 8-bit compressed image displayed by the Spectralis Viewer.  To approximate the compressed 8-bit view, perform a gamma correction using Process>Math>Gamma… and use a gamma value of 0.33.  Be aware that this is a destructive modification to your image.
  2. Open SLO
    • opens just the cSLO image without B-scan lines.
  3. Open SLO with Scan Lines
    • opens the cSLO image with green overlay lines indicating the position of the  B-scans.
  4. Display Retinal Thickness Results
    • values of layers segmented by Spectralis are listed in a results table. The y position, in pixels from top of image, is listed underneath a column labeled with the appropriate layer. The A-scan and B-scan coordinates are also listed. Total retinal thickness (TRT) is the calcuated vertical difference between the ILM and RPE layers and is listed in µm. The scan quality for each B-scan, in dB, is also listed.
  5. Display Info
    • creates a log window containing the exam information. 
  6. Open All - opens the OCT, SLO with Scan Lines, Retinal Thickness Results, and Info log.

Note to Macro Users:  The previous plugins are included in this jar file for your convenience.  Please update calls to Open_Heyex_Raw using the new methods.  For more info see the plugins.cfg file contained in the Open_Heyex_Raw.jar

See Also:

My LearnImageJ website with all my ImageJ Plugins and other image processing and analysis information

|Plugins | Home |