Segmented Hypergraphics

Segmented Hypergraphics (SHG), and its alter-ego Multiple Resolution Bitmap (MRB), are graphics formats used almost exclusively in the development of HLP (WinHelp) files. An SHG/MRB file contains one or more images in a BMP-like format, or WMF format. It also contains information about regions of the images that should be treated as hyperlinks.

Loosely speaking, SHG files are supposed to contain a single image, while MRB files contain more than one image. In practice, neither the file extension nor the file signature can be relied upon to be consistent with the image count, so the definition of SHG vs. MRB may be a matter of opinion.

Identification
SHG/MRB files begin with  or.

Specifications

 * helpdeco → helpfile.txt has information based on reverse-engineering.
 * Windows Help File Format / Annotation File Format / SHG and MRB File Format
 * SHED.ZIP - "a rather questionable specification"
 * Windows Undocumented File Formats - 1997 book by Pete Davis, Mike Wallace

Software
See also HLP (WinHelp). (Open source WinHelp software can presumably decode SHG/MRB in some way, though it may not expose that functionality to the user.)
 * helpdeco → splitmrb [Ed. note: The splitmrb (v1.5) utility is in disrepair, and is unlikely to work correctly if built with a modern compiler.]
 * Deark
 * Konvertor

Sample files

 * Some examples found on the web:, , ,
 * SHG/MRB files are embedded in countless HLP files.
 * https://telparia.com/fileFormatSamples/image/shg/
 * https://telparia.com/fileFormatSamples/image/multipleResolutionBitmap/

Links

 * Wikipedia: Segmented Hyper Graphics
 * Using Graphics Within a Help File