import type { GPUVegaCanvasContext } from '../types/context.js'; import type { PathGeometry } from '../types/geometry.js'; import type { ItemTransform } from '../path/geometryForItem.js'; import type { FillStyle, SceneItem, StrokeStyle } from '../types/scene.js'; import { type MarkModule } from './util.js'; /** One item's shape, at the given curve flatness. */ type ShapeOf = (ctx: GPUVegaCanvasContext, item: T, scale?: number) => PathGeometry; interface ItemShapeMark { type: string; /** Labels this mark's pipelines, buffers and bind groups. */ name: string; shapeOf: ShapeOf; /** The rotation and scale the item carries, for a mark whose items do. */ transformOf?: (item: T) => ItemTransform; /** * Whether the triangulation is held between frames. Only for a mark whose * shape is settled by the fields `cachedGeometryData` compares: an arc is * drawn from angles and radii it does not look at, so a held one would * survive its own shape changing. */ cached?: boolean; } /** * arc and path: marks that triangulate one shape per item, fill it, and walk * its contours for the stroke. * * The two differ in where the shape comes from, whether the item carries a * transform of its own and whether the triangulation is worth holding. Paint * order, batching, the gradient routes and the outline are the same, and had * been written out twice. */ export declare function itemShapeMark({ type, name, shapeOf, transformOf, cached, }: ItemShapeMark): MarkModule; export {};