image/graphic

A graphic file describes an image that is made of marks: a screen, a document, a diagram, or a chart. Examples include a screenshot, a slide, a map, a logo, and a scanned page. A graphic has no viewpoint, so nothing about lenses, light, or framing applies. A graphic has parts: a layout, text, and sometimes pictures inside it.

envelope the same fields in every typemeasured computed from the file's bytes; the same value every timeobserved what a model saw or heard; never a recommendationmixed some parts measured and some observed; the description says whichderived computed from other fields; the writer regenerates it and never edits itNo time marks: an image has no time at any level. Positions are fractions of the frame, measured from the top left: x, y for a point and x, y, w, h for a box.
checkout-flow.png.analyzemediaone JSON object next to the original

From top to bottom: the envelope, then six fields. This is the smallest type.

The envelopealways present, in this order
format
"analyzemedia"
Always this string.
version
"0.1"
Within a major version, changes only add fields.
type
"image/graphic"
The writer declares the type. Readers don't second-guess it.
generatedmeasured
{ at, by, models }
When the writer made the file, which writer, and which models it used. Nothing per item.
sourcethe file, and usually nothing else
name, bytes, sha256, quickHashmeasured
The hashes bind the sidecar to the file.
imagemeasured
{ format, width, height, orientation, colorSpace, bitDepth, hdr, alpha }
Width and height apply after orientation, so they match what a viewer shows.
camera · exposure · recorded · locationmeasured
as in scene, when the file carries them
A screenshot or an export has none of these fields. A scanned page might name a scanner as the software.
Sectionsone list of parts, in reading order

A graphic has no viewpoint, so nothing about lenses, light, or framing applies. A graphic is its parts: where each part is, what it is, and what it says or holds.

summaryobserved
string
What the graphic shows, in one paragraph. You can use it as alt text.
kindobserved
string
What sort of graphic this is: screen, document, slide, diagram, chart, table, map, logo, or icon.
languageobserved
BCP 47
The language of the text, when the graphic has text. One language per file.
picturemeasured
{ aspectRatio, orientation, palette [hex] }
The three measured facts that apply to marks: the shape of the image and the colors that it is made of. For a logo, the palette is the logo.
parts[]observed
[ { kind, box { x, y, w, h }, text } ]
Every part in reading order, each with its box. A screen has a header, a sidebar, buttons, and fields. A document has headings, paragraphs, lists, and figures. A chart has a title, axes, and a legend. A picture inside the graphic is a part with a one-sentence description. text holds the words when the part is text, and a description otherwise. A reader that wants only the words concatenates them.
quality[]observed
[ string ]
Conditions that are visible in the image: blurry, compressed, watermarked, cropped, or low resolution.
The example screenshot, with its parts drawn
1 header: logo left, cart (2) right
2 heading: Shipping address
3 field: Full name, filled
4 field
5 field
6 button: Pay €84.90, greyed out
7 sidebar: order summary
8 picture
parts[]: header {0,0,1,.06}, heading {.06,.10,.30,.04}, field {.06,.16,.50,.05}, …, button {.06,.62,.50,.06}, sidebar {.62,.10,.32,.58}, picture {.64,.16,.06,.08}

The screenshot shows a web checkout page as eight parts in reading order. The purple part is a picture inside the graphic, a product thumbnail. It is a part like the others, with the kind picture. Every box is a fraction of the frame, so you can point at a control without the pixel size.

A graphic file answers the question "what is on this screen or page, where is it, and what does it say". For a document, the text of the parts is the point of the file. For a screen, the parts give every control with its box. A graphic file never holds time, form, composition, people, or objects. A screenshot of a photo is a graphic with a picture part.

Rules you can rely on