Presentation Graphics
Presentation Graphics Stream (PGS or PG) is a bitmap graphics format commonly used for subtitles.
| Type of format | Graphics & Subtitle Format | |
|---|---|---|
| First released | 2006 | |
| Developer | Blu-ray Disc Association (Panasonic) | |
| Filename extension | None* | |
| Limits | 32 Streams | |
| Open Format? | Yes | |
| Free Format? | ? | |
| Magic Number | "PG" 0x5047 |
|
The format is similar to Interactive Graphics, but instead of using it for interactive menus, it is used for subtitles or rarely decorations. It is an vast improvement over DVD subtitles.
Presentation Graphics are displayed on its own independent layer behind the Interactive Graphics; it is similar to Interactive Graphics (IG) used for menus (both layers are on top of the Primary Video). The graphics (along with its data and X-Y coordinates) are stored inside M2TS files that contains the video and audio streams. The graphics are decoded from the Blu-ray player's special graphics decoder. It can only use 32 streams. The max graphics memory buffer size is 4 MB. Presentation Graphics are available on both HDMV and BD-J.**
![]() |
| Example of PGS on top of the Primary Video using different colors and sizes. |
Features:
- It uses simple 8-bit colors and transparency (256 color palette), this is useful for simple graphics but complex ones like photos will cause dithering a la GIF.
- Unlike Java Graphics (PNG, JPEG), Presentation Graphics use simple animations: Fade In/Out, Color changing, Wipe In/Out, and Scrolling. Supports frame rates up to 30 Hz. Despite being simple, they take a lot of space in the graphics memory buffer if pushing it to its limits.
- It's resolution plane size supports 1920x1080/1280x720/720x480/720x576.
- Uses Run-length encoding, a simple compression method.
Presentation Graphics cannot be "opened" on a normal image program on a computer, it must be opened by demuxing the M2TS file or a specialized Blu-ray/subtitling editing software such as BDedit, BDReauthor, Scenarist, etc. When a PGS is extracted/demuxed from the M2TS file, it's usually saved in a file with the .sup extension (Subtitle Presentation).
Data
Data inside a PGS is made of several sections, each have the following header:
Presentation Graphics Stream Data| Name | Description | Byte Size |
|---|---|---|
| Magic Number |
"PG" 0x5047 |
2 |
| PTS |
Presentation Timestamp - Indicates exact moment a decoded PG's sub-picture should be displayed/presented (synchronized) to the user (at a frequency of 90KHz). | 4 |
| DTS | Decoding Timestamp - Indicates the precise moment when the decoding of the PG starts (at a frequency of 90KHz). | 4 |
| Segment Type |
|
1 |
| Segment Size | Size of the segment | 1 |
Presentation Graphics are divided 5 segments:
- Presentation Composition Segment (PCS)
- Window Definition Segment (WDS)
- Palette Definition Segment (PDS)
- Object Definition Segment (ODS)
- End of Display Set Segment (END)
Presentation Composition Segment (PCS) is used for composing the graphic's sub-picture. It is also called the Control Segment because it indicates a new Display Set (DS) definition, composed by definition segments (WDS, PDS, ODS) until an END segment is found.
In a Display Set, there can be several windows, palette and object definitions, and the composition objects define what's to be shown on screen.
Presentation Composition Segment fields:
| Name | Description | Byte Size |
|---|---|---|
| Width | Video width in pixels (ex. 0x780 = 1920) | 2 |
| Height | Video height in pixels (ex. 0x438 = 1080) | 2 |
| Frame Rate | Always 0x10. Can be ignored. | 1 |
| Composition Number | Number of this specific composition. It is incremented by one every time a graphics update occurs. | 2 |
| Composition State | Type of this composition. Allowed values are:
| 1 |
| Palette Update Flag | Indicates if this PCS describes a Palette only Display Update. Allowed values are:
| 1 |
| Palette ID | ID of the palette to be used in the Palette only Display Update | 1 |
| Number of Composition Objects | Number of composition objects defined in this segment | 1 |
Composition Objects define the position for each image to be displayed:
| Name | Description | Byte Size |
|---|---|---|
| Object ID | ID of the ODS segment that defines the image to be shown | 2 |
| Window ID | ID of the WDS segment to which the image is allocated in the PCS. Up to two images may be assigned to one window | 1 |
| Object Cropped Flag |
| 1 |
| Object Horizontal Position | X offset from the top left pixel of the image on the screen | 2 |
| Object Vertical Position | Y offset from the top left pixel of the image on the screen | 2 |
| Object Cropping Horizontal Position | X offset from the top left pixel of the cropped object in the screen. Only used when the Object Cropped Flag is set to 0x40. | 2 |
| Object Cropping Vertical Position | Y offset from the top left pixel of the cropped object in the screen. Only used when the Object Cropped Flag is set to 0x40. | 2 |
| Object Cropping Width | Width of the cropped object in the screen. Only used when the Object Cropped Flag is set to 0x40. | 2 |
| Object Cropping Height Position | Height of the cropped object in the screen. Only used when the Object Cropped Flag is set to 0x40. |
2 |
Window Definition Segment (WDS) defines the rectangular area on the screen where the graphic's sub-picture will be shown. This rectangular area is called a Window. This segment defines several windows, and all the fields from Window ID up to Window Height will repeat each other in the segment defining each window.
| Name | Description | Byte Size |
|---|---|---|
| Number of Windows | Number of windows defined in this segment | 1 |
| Window ID | ID of this window | 1 |
| Window Horizontal Position | X offset from the top left pixel of the window in the screen. | 2 |
| Window Vertical Position | Y offset from the top left pixel of the window in the screen. | 2 |
| Window Width | Width of the window | 2 |
| Window Height | Height of the window | 2 |
Palette Definition Segment (PDS) is used to define a palette for color conversion. Multiple palette entries are allowed, each with a unique palette ID, enabling the last five fields to repeat.
| Name | Description | Byte Size |
|---|---|---|
| Palette ID | ID of the palette | 1 |
| Palette Version Number | Version of this palette within the Epoch | 1 |
| Palette Entry ID | Entry number of the palette | 1 |
| Luminance (Y) | Luminance (Y value) | 1 |
| Color Difference Red (Cr) | Color Difference Red (Cr value) | 1 |
| Color Difference Blue (Cb) | Color Difference Blue (Cb value) | 1 |
| Transparency (Alpha) | Transparency (Alpha value) | 1 |
Object Definition Segment (ODS) defines the graphics object. These are images with rendered text on a transparent background.
| Name | Description | Byte Size |
|---|---|---|
| Object ID | ID of this object | 2 |
| Object Version Number | Version of this object | 1 |
| Last in Sequence Flag | If the image is split into a series of consecutive fragments, the last fragment has this flag set. Possible values:
| 1 |
| Object Data Length | The length of the Run-length Encoding (RLE) data buffer with the compressed image data. | 3 |
| Width | Width of the image | 2 |
| Height | Height of the image | 2 |
| Object Data | This is the image data compressed using Run-length Encoding (RLE). The size of the data is defined in the Object Data Length field. | Varies |
End of Display Set Segment (END) always has a segment size of zero and indicates the end of a Display Set (DS) definition. It appears immediately after the last ODS in one DS.
|
Example of how subtitles are
display. An Epoch in the drawing includes a DS1 (Epoch
Start), a DS2 (Normal Case), and a DS3 (Normal Case). The
DS1 contains a WDS for specifying the Window in which the
subtitles are displayed, an ODS for specifying the line “Actually ... I was hiding my feelings.”, and a first PCS. The DS2
contains a second PCS, and the DS3 contains a third PCS.
|
Subtitles
Presentation Graphics are commonly used for subtitles for the deaf/hard-of-hearing (SDH), translations, karaoke, and sing-a-along lyrics on screen. Basic subtitles for SDH in mainstream movies typically use white fonts and black outlines. Subtitles for foreign movies typically use either white or yellow colored fonts with black outlines, not only for dialog, but also signs and lyrics.
|
Example of speaker ID in SDH (voices are off-screen)
|
Example of non-speech information in SDH (source is off-screen)
|
Example of non-speech information in SDH (two sources: off-screen and on-screen)
|
Example of music description in SDH
|
Example of lyrics transcription in SDH
|
For diffrent languages, Presentation Graphics Streams are tied with its language code defined in ISO 639-2/T. Each code represents names of language by three characters, e.g. ENG, JAP, etc.
Forced Subtitles
Some
commercial Blu-rays contain forced subtitles, meaning they cannot be
turned off due to the HDMV programming, this can be "fixed" by ripping
the BD, modifying the code (or M2TS file), and making a new version to burn on a blank BD-R.
The reason why some PGS cannot be turned off is either artistic intent or
using it for decorative menus.
Footnotes
- *It doesn't use a file extension in a traditional sense. BD editing programs use other image formats and converts them to PG. When a PGS is extracted/demuxed from the M2TS file, it's usually saved in a file with the
.supextension (Subtitle Presentation). Scenarist also uses the.pesfile format for import, export, and editing (doesn't contain any magic numbers). - ** Presentation Graphics Streams and Text Subtitle Streams cannot be used and displayed at the same time.
Sources
- TheScorpius666 (2017-07-15). "Presentation Graphic Stream (SUP files) BluRay Subtitle Format". blog.thescorpius.com.
- Scenarist BD Development manual, BD-ROM Whitepaper (2010), and original research.
- Blu-ray Disc Demystified
- BDedit
- PGS specification is defined in the US Patent US 20090185789 A1.
Author(s) : Æ Firestone
Popular Pages
-
Reavon UBR-X100 is an high-end Ultra HD Blu-ray player from the French company, Reavon. There are two other identical models, UBR-X110 and ...
-
Oppo BDP-103 and BDP-103D are high-end Blu-ray players manufactured by Chinese company, Oppo Inc, who are known for their high quality Blu...
-
BD-ROMs use the BDMV application format as a standard for commercial movies, music albums and video games.

