Skip to content
ChartForgeX
Class

PreparedVisual

ChartForgeX.Rendering

Namespace
ChartForgeX.Rendering
Assembly
ChartForgeX
Modifiers
sealed

A detached immutable scene. SVG and native raster export consume the same prepared decisions.

Inheritance

  • object
  • PreparedVisual

Usage

Explore 39 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 8

Methods

CaptureLayer 6 overloads
public CapturedVisualLayer CaptureLayer(VisualOutline effect, VisualRenderOptions? options = null, CancellationToken cancellationToken = default) #

Captures a square-kernel outer alpha band, additively merged with this unchanged native child.

Parameters

effect ChartForgeX.Effects.VisualOutline required
Immutable literal tint and logical radius, on the selected device grid.
options ChartForgeX.Rendering.VisualRenderOptions? = null optional
Existing device density, supersampling, pixel cap and text policy.
cancellationToken System.Threading.CancellationToken = default optional
Cancels before capture, between rows and before the detached snapshot is published.

Returns

CapturedVisualLayer A baked layer containing source and outward band. Radius zero or transparent tint preserves source bytes.
public CapturedVisualLayer CaptureLayer(VisualBloom effect, VisualRenderOptions? options = null, CancellationToken cancellationToken = default) #

Captures the explicit sRGB luminance bright pass, Gaussian approximation and Screen merge as one layer.

Parameters

effect ChartForgeX.Effects.VisualBloom required
Required immutable threshold and strength with logical-unit sigma targets.
options ChartForgeX.Rendering.VisualRenderOptions? = null optional
Existing density, supersampling, pixel cap and text policy.
cancellationToken System.Threading.CancellationToken = default optional
Cancels before allocations, between rows and before publication.

Returns

CapturedVisualLayer A baked source-plus-bloom snapshot. No bright samples retain original source pixels and bounds.
public CapturedVisualLayer CaptureLayer(VisualLayerBlur effect, VisualRenderOptions? options = null, CancellationToken cancellationToken = default) #

Captures this complete prepared viewport as one immutable blurred composition layer.

Parameters

effect ChartForgeX.Effects.VisualLayerBlur required
Explicit immutable logical-unit blur. Existing ordinary exports are never changed.
options ChartForgeX.Rendering.VisualRenderOptions? = null optional
Existing native output density, coverage, source pixel budget and hinting policy.
cancellationToken System.Threading.CancellationToken = default optional
Cancellation observed before and after native capture, within effect rows and before publishing the snapshot.

Returns

CapturedVisualLayer A bounded static layer whose image, SVG and composition consumer use the same private pixels.
public CapturedVisualLayer CaptureLayer(VisualDropShadow effect, VisualRenderOptions? options = null, CancellationToken cancellationToken = default) #

Captures this complete prepared viewport with one spread/blurred alpha shadow beneath its original source.

Parameters

effect ChartForgeX.Effects.VisualDropShadow required
Explicit immutable logical-unit shadow; source and shadow support are retained separately.
options ChartForgeX.Rendering.VisualRenderOptions? = null optional
Existing output density, coverage, source budget and hinting policy.
cancellationToken System.Threading.CancellationToken = default optional
Cancellation checked around native capture, within effect rows and before publication.

Returns

CapturedVisualLayer A detached static layer covering the union of the source and propagated shadow support.
public CapturedVisualLayer CaptureLayer(VisualInnerShadow effect, VisualRenderOptions? options = null, CancellationToken cancellationToken = default) #

Captures an original-sized alpha-preserving inner shadow through the existing finite effect plan.

Parameters

effect ChartForgeX.Effects.VisualInnerShadow required
Immutable inset request; transparent tint or zero opacity preserves captured source bytes.
options ChartForgeX.Rendering.VisualRenderOptions? = null optional
Existing native density, coverage, pixel budget and text policy.
cancellationToken System.Threading.CancellationToken = default optional
Observed before allocation, during existing kernel/output rows and before publication.

Returns

CapturedVisualLayer A detached captured layer with original viewport bounds and independent source facts.
public CapturedVisualLayer CaptureLayer(VisualMask mask, VisualRenderOptions? options = null, CancellationToken cancellationToken = default) #

Captures this complete viewport and applies one detached fixed-grid mask without changing source facts or geometry.

Parameters

mask ChartForgeX.Effects.VisualMask required
Immutable mask in the original child's coordinates, with the same density as the capture.
options ChartForgeX.Rendering.VisualRenderOptions? = null optional
Existing native density, coverage, budget and text policy.
cancellationToken System.Threading.CancellationToken = default optional
Cancels before capture, within mask rows and before snapshot publication.

Returns

CapturedVisualLayer A static baked layer retaining its original source and viewport.
ToPng 2 overloads
public byte[] ToPng(VisualRenderOptions? options = null) #

Exports PNG from the native raster backend.

Parameters

options ChartForgeX.Rendering.VisualRenderOptions? = null optional

Returns

byte[]
public byte[] ToPng(VisualRenderOptions? options, CancellationToken cancellationToken) #

Exports native PNG with cancellation at native scopes and effect rows, without changing prepared facts.

Parameters

options ChartForgeX.Rendering.VisualRenderOptions? required
cancellationToken System.Threading.CancellationToken required

Returns

byte[]
public RgbaImage ToRgbaImage(VisualRenderOptions? options = null) #

Exports native RGBA pixels without repeating layout or parsing SVG.

Parameters

options ChartForgeX.Rendering.VisualRenderOptions? = null optional

Returns

RgbaImage
ToSvg 4 overloads
public string ToSvg() #

Exports script-free SVG without repeating layout.

Returns

string
public string ToSvg(string idScope) #

Exports SVG with a host-owned ID namespace, allowing identical prepared visuals in one document.

Parameters

idScope string required
A unique host prefix beginning with an ASCII letter and containing only letters, digits, hyphens, underscores and periods.

Returns

string
public string ToSvg(VisualSvgOptions options) #

Exports SVG using detached host namespace, color and safe link policies.

Parameters

options ChartForgeX.Rendering.VisualSvgOptions required

Returns

string
public string ToSvg(VisualSvgOptions options, CancellationToken cancellationToken) #

Exports SVG with operation cancellation and the selected typed effect representation.

Parameters

options ChartForgeX.Rendering.VisualSvgOptions required
cancellationToken System.Threading.CancellationToken required

Returns

string
public PreparedVisual WithBloom(VisualBloom effect) #

Retains an explicit luminance-ramp bloom in the fixed source viewport.

Parameters

effect ChartForgeX.Effects.VisualBloom required
Immutable threshold, strength, sigma and quantization policy.

Returns

PreparedVisual A detached retained presentation. Threshold one or strength zero returns this source unchanged.
public PreparedVisual WithDropShadow(VisualDropShadow effect) #

Retains the complete source with its alpha shadow inside the fixed native viewport.

Parameters

effect ChartForgeX.Effects.VisualDropShadow required
Immutable shadow policy; a zero-alpha tint or opacity returns this source unchanged.

Returns

PreparedVisual A detached retained source-plus-shadow presentation.
public PreparedVisual WithInnerShadow(VisualInnerShadow effect) #

Retains a finite inner shadow on this complete root with its original viewport, facts and source alpha.

Parameters

effect ChartForgeX.Effects.VisualInnerShadow required
Immutable inset request. Zero geometry alone is not identity for semitransparent source.

Returns

PreparedVisual This source for zero tint/opacity, otherwise an independent retained presentation.
public PreparedVisual WithMask(VisualMask mask) #

Returns a detached complete-root mask presentation in this fixed source viewport.

Parameters

mask ChartForgeX.Effects.VisualMask required
Immutable fixed-density input; native export density must match its grid.

Returns

PreparedVisual A retained presentation with unchanged source facts, regions and projections.
public PreparedVisual WithOutline(VisualOutline effect) #

Retains one complete-root outer alpha-band policy in this fixed viewport.

Parameters

effect ChartForgeX.Effects.VisualOutline required
Immutable outline; zero radius or transparent tint returns this source unchanged.

Returns

PreparedVisual A detached retained presentation with the same source facts, regions and projections.

Properties

public TopologyHierarchyView? TopologyHierarchyView { get; } #

Gets the immutable organization hierarchy request, independently of numeric chart hierarchy views.

public ChartHierarchyView? HierarchyView { get; } #

Gets the immutable subtree request, or null for the complete source hierarchy.

public ChartVisibilityView? VisibilityView { get; } #

Gets the immutable whole-series view captured by native visibility preparation, or null for ordinary preparation.

public VisualSize Size { get; } #

Gets the logical viewport.

public IReadOnlyList<VisualDiagnostic> Diagnostics { get; } #

Gets preparation diagnostics.

public IReadOnlyList<VisualSemanticRegion> Regions { get; } #

Gets descriptive source regions.

public ChartAxisProjection? XProjection { get; } #

Gets the detached primary horizontal projection for a supported usable Cartesian scene, or null otherwise.

public ChartAxisProjection? YProjection { get; } #

Gets the detached primary Y projection for a supported usable Cartesian scene.

public ChartAxisProjection? SecondaryXProjection { get; } #

Gets the detached secondary horizontal value projection on a supported horizontal chart.

public ChartAxisProjection? SecondaryYProjection { get; } #

Gets the detached secondary vertical value projection on a supported vertical chart.

public ChartCartesianViewport? CartesianViewport { get; } #

Gets the captured immutable Cartesian request, or null for full-domain preparation.

public ChartOrientation? CartesianOrientation { get; } #

Gets the captured Cartesian orientation, or null for a non-Cartesian or unusable scene.

public ChartPolarProjection? PolarProjection { get; } #

Gets the detached directional/radius projection for a usable continuous Polar scene.

public ChartPolarViewport? PolarViewport { get; } #

Gets the captured polar request, or null for its full view.

public VisualAccessibility Accessibility { get; } #

Gets an independent copy of the text alternative.

Extension Methods

ToArtifact 2 overloads
public static VisualArtifact ToArtifact(PreparedVisual prepared, string? id = null) #

Wraps a prepared visual using its captured semantic identity and family when available.

Parameters

prepared ChartForgeX.Rendering.PreparedVisual required
The detached static output.
id string? = null optional
Optional host ID; defaults to the captured ID or "prepared-visual" for a scene without semantics.
public static VisualArtifact ToArtifact(PreparedVisual prepared, string id, VisualArtifactKind kind, VisualArtifactInterchangeEnvelope? semanticInterchange = null, string? title = null, string? subtitle = null) #

Wraps an immutable prepared visual for static export and portable host handoff.

Parameters

prepared ChartForgeX.Rendering.PreparedVisual required
The detached static output.
id string required
The stable artifact ID; it must match a supplied semantic envelope.
kind ChartForgeX.VisualArtifacts.VisualArtifactKind required
The declared artifact kind; it must match a supplied semantic envelope.
semanticInterchange ChartForgeX.VisualArtifacts.VisualArtifactInterchangeEnvelope? = null optional
Optional source-model semantics, captured independently of the display scene.
title string? = null optional
Optional artifact title; defaults to the semantic title or prepared accessible name.
subtitle string? = null optional
Optional artifact subtitle; defaults to the semantic subtitle.

Returns

VisualArtifact A mutable host envelope whose render model and captured semantic data are detached snapshots.