|
|
Donner 0.8.0-pre
Embeddable browser-grade SVG2 engine
|
#include <cstdint>#include <deque>#include <memory>#include <optional>#include <string>#include <unordered_map>#include <unordered_set>#include <vector>#include "glad/glad.h"#include "donner/base/Box.h"#include "donner/base/Transform.h"#include "donner/base/Vector2.h"#include "donner/editor/AsyncRenderer.h"#include "donner/editor/FrameCostBreakdown.h"#include "donner/editor/ImGuiIncludes.h"Classes | |
| struct | donner::editor::CompositedTileTextureIdentity |
| Stable identity for deciding whether a metadata-only composited tile can reuse an existing presentation texture. More... | |
| struct | donner::editor::PresentationResourceStats |
| Approximate resource footprint retained by the editor presentation texture cache. More... | |
| struct | donner::editor::PresentationCoverageDiagnostics |
| Presentation coverage state for composited tile fallback diagnostics. More... | |
| class | donner::editor::GlTextureCache |
| Owns the GL textures the advanced editor uses for overlay and composited presentation. More... | |
| struct | donner::editor::GlTextureCache::TileView |
| One composite-tile entry as the presenter sees it: the GL texture handle (resolved from the upload cache) plus the geometry fields the presenter needs to blit in paint order. More... | |
Namespaces | |
| namespace | donner |
| Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css. | |
Functions | |
| CompositedTileTextureIdentity | donner::editor::TextureIdentityForCompositedTile (const RenderResult::CompositedTile &tile) |
| Return the presentation texture identity carried by tile. | |
| bool | donner::editor::TextureIdentityMatchesCompositedTile (const CompositedTileTextureIdentity &cachedIdentity, const RenderResult::CompositedTile &tile) |
| Return true when a metadata-only tile can reuse cachedIdentity. | |
| Vector2i | donner::editor::PowerOfTwoTextureDimensionsForPayload (const Vector2i &payloadDimensions) |
| Return the power-of-two backing texture dimensions for a payload. | |
| Vector2d | donner::editor::TextureUvBottomRightForPayload (const Vector2i &payloadDimensions, const Vector2i &allocationDimensions) |
| Return the max UV that samples only the payload inside a backing texture. | |
| std::uint64_t | donner::editor::BitmapPayloadBytes (const svg::RendererBitmap &bitmap) |
| Return the byte size of a CPU bitmap payload as submitted to the presentation cache. | |
| std::uint64_t | donner::editor::TexturePayloadBytes (const Vector2i &dimensions) |
| Return the approximate byte size of a backend texture payload, assuming RGBA8 storage. | |
| FrameCostBreakdown::CompositedUpload | donner::editor::CostForCompositedPreviewUpload (const RenderResult::CompositedPreview &preview) |
| Compute upload-cost counters for a composited preview without touching GL/WGPU state. | |
| struct donner::editor::GlTextureCache::TileView |
One composite-tile entry as the presenter sees it: the GL texture handle (resolved from the upload cache) plus the geometry fields the presenter needs to blit in paint order.
| Class Members | ||
|---|---|---|
| Vector2d | bitmapDimsDoc = Vector2d::Zero() | |
| Vector2i | bitmapDimsPx = Vector2i::Zero() | |
| Vector2d | canvasOffsetDoc = Vector2d::Zero() | |
| Transform2d | documentFromCachedDocument = Transform2d() | |
| Vector2d | dragTranslationDoc = Vector2d::Zero() | |
| uint64_t | generation = 0 | |
| string | id | |
| bool | isDragTarget = false | |
| Kind | kind = RenderResult::CompositedTile::Kind::Segment | |
| Entity | layerEntity = entt::null | |
| bool | metadataOnly = false | |
| Vector2i | rasterCanvasSize = Vector2i::Zero() | |
| ImTextureID | texture = 0 | |
| Vector2d | uvBottomRight = Vector2d(1.0, 1.0) | |
|
nodiscard |
Return the byte size of a CPU bitmap payload as submitted to the presentation cache.
| bitmap | CPU renderer bitmap. |
|
nodiscard |
Compute upload-cost counters for a composited preview without touching GL/WGPU state.
| preview | Composited preview to inspect. |
|
nodiscard |
Return the power-of-two backing texture dimensions for a payload.
| payloadDimensions | Valid content dimensions in pixels. |
|
nodiscard |
Return the presentation texture identity carried by tile.
| tile | Composited tile whose payload or metadata should be identified. |
|
nodiscard |
Return true when a metadata-only tile can reuse cachedIdentity.
| cachedIdentity | Identity recorded for the currently cached texture. |
| tile | Incoming composited tile metadata. |
|
nodiscard |
Return the approximate byte size of a backend texture payload, assuming RGBA8 storage.
| dimensions | Texture dimensions in pixels. |
|
nodiscard |
Return the max UV that samples only the payload inside a backing texture.
| payloadDimensions | Valid content dimensions in pixels. |
| allocationDimensions | Backing texture allocation dimensions in pixels. |