@vitreajs/vitrea 0.17.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -486,7 +486,25 @@ type AnalysisQuality = "exact" | "hint" | "none";
486
486
  type GroupHealth = "ok" | "demoted";
487
487
  declare const DEMOTION_REASONS: readonly ["no-webgpu", "no-backdrop-filter", "tainted-source", "incompatible-texture", "no-texture-supplied", "device-lost", "probe-failed", "governor"];
488
488
  type DemotionReason = (typeof DEMOTION_REASONS)[number];
489
+ /** W28's actual per-surface response input. Dimensions disclose a downscaled source;
490
+ * level zero is the finest imported image, not necessarily the original raster. */
491
+ interface SurfaceBackdropToneAbscissa$1 {
492
+ readonly surfaceId: string;
493
+ readonly kind: "source" | "silhouette" | "hint";
494
+ readonly encodedLuminance: number;
495
+ readonly luminance: number;
496
+ readonly linearLuminance: number;
497
+ readonly color: readonly [number, number, number];
498
+ readonly sampleCount: number;
499
+ readonly level: number;
500
+ readonly sourceWidth: number;
501
+ readonly sourceHeight: number;
502
+ readonly sampledWidth: number;
503
+ readonly sampledHeight: number;
504
+ }
489
505
  interface GlassGroupState {
506
+ /** Latest actual reduction for the drawn surfaces, absent before it is observed. */
507
+ readonly backdropToneAbscissae?: readonly SurfaceBackdropToneAbscissa$1[];
490
508
  /** What the app declared — never mutated by the runtime. */
491
509
  readonly configuredSource: ConfiguredSource;
492
510
  /** What is actually drawing. */
@@ -3168,6 +3186,10 @@ interface MaterialProfile {
3168
3186
  * extreme-dark region stays with the collapse constants that were fitted
3169
3187
  * on it.
3170
3188
  */
3189
+ /** W28: absent/source preserves the source solve; silhouette reduces raw pixels per surface. */
3190
+ readonly backdropToneAbscissa?: "source" | {
3191
+ readonly kind: "silhouette";
3192
+ };
3171
3193
  readonly backdropToneAnchorX: BackdropToneKnotRow;
3172
3194
  readonly backdropToneResponseThin: BackdropToneKnotRow;
3173
3195
  readonly backdropToneResponseThick: BackdropToneKnotRow;
@@ -3294,6 +3316,7 @@ interface MaterialProfilePatch {
3294
3316
  readonly rimCollapsed?: number;
3295
3317
  readonly rimCollapsedTinted?: number;
3296
3318
  readonly rimTintChroma?: number;
3319
+ readonly backdropToneAbscissa?: MaterialProfile["backdropToneAbscissa"];
3297
3320
  readonly backdropToneAnchorX?: BackdropToneKnotRow;
3298
3321
  readonly backdropToneResponseThin?: BackdropToneKnotRow;
3299
3322
  readonly backdropToneResponseThick?: BackdropToneKnotRow;
@@ -3701,6 +3724,8 @@ interface GroupRenderInput {
3701
3724
  * back to a level nobody measured.
3702
3725
  */
3703
3726
  readonly backdropTone?: Rgb;
3727
+ /** Author hints retain precedence over the silhouette reduction. */
3728
+ readonly backdropToneHint?: boolean;
3704
3729
  /**
3705
3730
  * The backdrop's ENCODED-space tone level (W9, claims §5.31–§5.34): the mean
3706
3731
  * taken in sRGB-encoded space, decoded once — the input the reference's tone
@@ -4253,6 +4278,22 @@ interface PyramidStore {
4253
4278
  destroy(): void;
4254
4279
  }
4255
4280
 
4281
+ /** Structural twin of core's readout: the renderer cannot import its parent package. */
4282
+ interface SurfaceBackdropToneAbscissa {
4283
+ readonly surfaceId: string;
4284
+ readonly kind: "source" | "silhouette" | "hint";
4285
+ readonly encodedLuminance: number;
4286
+ readonly luminance: number;
4287
+ readonly linearLuminance: number;
4288
+ readonly color: readonly [number, number, number];
4289
+ readonly sampleCount: number;
4290
+ readonly level: number;
4291
+ readonly sourceWidth: number;
4292
+ readonly sourceHeight: number;
4293
+ readonly sampledWidth: number;
4294
+ readonly sampledHeight: number;
4295
+ }
4296
+
4256
4297
  /**
4257
4298
  * The renderer: device, resources, and the frame.
4258
4299
  *
@@ -4434,6 +4475,8 @@ interface GlassRenderer {
4434
4475
  frameParticipant(): FrameParticipantView;
4435
4476
  /** Resolve any completed analysis readbacks into the adaptation drivers. */
4436
4477
  collectAdaptation(): Promise<number>;
4478
+ /** Actual GPU reduction, resolved asynchronously after the submitted draw. */
4479
+ backdropToneAbscissae(groupId: string): readonly SurfaceBackdropToneAbscissa[];
4437
4480
  destroy(): void;
4438
4481
  }
4439
4482
 
@@ -4505,4 +4548,4 @@ declare const VITREA_CONTRACTS: {
4505
4548
  declare const RENDERER_TIERS: readonly ["webgpu", "css"];
4506
4549
  type RendererTier = (typeof RENDERER_TIERS)[number];
4507
4550
 
4508
- export { ACCESSIBILITY_BEHAVIOR_TABLE, ACCESSIBILITY_FLAGS, ACCESSIBILITY_PRECEDENCE, type AccessibilityConsequences, type AccessibilityFlag, type AccessibilityOverride, type AccessibilityOverrides, type ActiveRenderer, type AnalysisQuality, type BackdropEstimatorProvider, type BackdropHint, type BackdropHintRequest, type BackdropProvider, type BackdropRebuildRequest, type BackdropResolutionPolicy, type BackdropSourceDescriptor, type BackdropSourceRecord, type BackdropTone, type CapabilityInputs, type ConcentricParent, type ConfiguredSource, type CopyProviderOptions, type CornerProfile, type CornerRadii, type CornerReference, DEFAULT_BACKDROP_RESOLUTION, DEFAULT_CLEAR_DIMMING, DEFAULT_GROUP_SAMPLING, DEMOTION_REASONS, DEMOTION_RECOVERY, DIAGNOSTIC_CODES, type DemotionReason, type DescriptorPatch, type Diagnostic, type DiagnosticCode, type DiagnosticSeverity, type DiagnosticSink, type DiagnosticsChannel, type DiagnosticsChannelOptions, type DimmingPolicy, type DomBackdropSource, FOREGROUND_MODES, FRAME_PHASES, type ForegroundAdaptation, type ForegroundMode, type ForegroundResolutionOptions, type FrameContext, type FrameInfo, type FrameParticipant, type FramePhase, type FrameReport, type FrameScheduler, type FrameSchedulerOptions, GLASS_PLANES, GOVERNOR_PRESSURES, type GlassGroupDescriptor, type GlassGroupRecord, type GlassGroupState, type GlassNodeDescriptor, type GlassNodeRecord, type GlassPlane, type GlassRenderer, type GlassScene, GlassSceneError, type GlassSceneErrorCode, type GlassSceneOptions, type GlassTint, type GovernorPressure, type GroupHealth, type GroupSamplingGeometry, type GroupStateChange, HINT_AVAILABILITIES, type HintAvailability, type InteractionState, MATERIAL_VARIANTS$1 as MATERIAL_VARIANTS, type MaterialProfile$1 as MaterialProfile, type MaterialRequest, type MaterialVariant$1 as MaterialVariant, type MotionChannel, type MotionDriverKind, NOMINAL_ACCESSIBILITY_POLICY, OVERRIDABLE_ACCESSIBILITY_FLAGS, type OverridableAccessibilityFlag, type PlaneOverlap, type PlatformProbe, type ProxyOverlap, RENDERER_TIERS, type RecoveryContract, type RecoveryTrigger, type Rect$1 as Rect, type RefractionQuality, type RendererTier, type ResolvedAccessibilityPolicy, type ResolvedBackdropHint, type ResolvedForegroundAdaptation, type ResolvedGroup, type ResolvedMaterial, type ResolvedMaterialPolicy, type ResolvedMotionPolicy, type ResolvedNode, SAMPLED_ASYNC_DEFAULTS, SAMPLED_ASYNC_RATE_LIMITS, type SamplingBackend, type SceneResolution, type ShapeChannels, type ShapeFamily, type SourceProbe, type StateChange, type SystemAccessibilityPreferences, type TextureBackdropSource, type TintColor, type TintMixingCheck, VITREA_CONTRACTS, type VariantMixingCheck, type Vec2, type VideoProviderOptions, WEBGPU_AVAILABILITIES, type WebGPUAvailability$1 as WebGPUAvailability, type WebGPURendererModule, type ZSlot, checkTintMixing, checkVariantMixing, classifyStateChange, clipRect, compareZSlot, createDiagnosticsChannel, createFrameScheduler, createGlassScene, defaultForegroundAdaptation, glassTint, inflateRect, isHealthy, loadWebGPURenderer, loadWebGPURendererModule, rectsOverlap, resolveAccessibilityPolicy, resolveBackdropHint, resolveForegroundAdaptation, resolveGlassGroupState, resolveMaterial, unionRect };
4551
+ export { ACCESSIBILITY_BEHAVIOR_TABLE, ACCESSIBILITY_FLAGS, ACCESSIBILITY_PRECEDENCE, type AccessibilityConsequences, type AccessibilityFlag, type AccessibilityOverride, type AccessibilityOverrides, type ActiveRenderer, type AnalysisQuality, type BackdropEstimatorProvider, type BackdropHint, type BackdropHintRequest, type BackdropProvider, type BackdropRebuildRequest, type BackdropResolutionPolicy, type BackdropSourceDescriptor, type BackdropSourceRecord, type BackdropTone, type CapabilityInputs, type ConcentricParent, type ConfiguredSource, type CopyProviderOptions, type CornerProfile, type CornerRadii, type CornerReference, DEFAULT_BACKDROP_RESOLUTION, DEFAULT_CLEAR_DIMMING, DEFAULT_GROUP_SAMPLING, DEMOTION_REASONS, DEMOTION_RECOVERY, DIAGNOSTIC_CODES, type DemotionReason, type DescriptorPatch, type Diagnostic, type DiagnosticCode, type DiagnosticSeverity, type DiagnosticSink, type DiagnosticsChannel, type DiagnosticsChannelOptions, type DimmingPolicy, type DomBackdropSource, FOREGROUND_MODES, FRAME_PHASES, type ForegroundAdaptation, type ForegroundMode, type ForegroundResolutionOptions, type FrameContext, type FrameInfo, type FrameParticipant, type FramePhase, type FrameReport, type FrameScheduler, type FrameSchedulerOptions, GLASS_PLANES, GOVERNOR_PRESSURES, type GlassGroupDescriptor, type GlassGroupRecord, type GlassGroupState, type GlassNodeDescriptor, type GlassNodeRecord, type GlassPlane, type GlassRenderer, type GlassScene, GlassSceneError, type GlassSceneErrorCode, type GlassSceneOptions, type GlassTint, type GovernorPressure, type GroupHealth, type GroupSamplingGeometry, type GroupStateChange, HINT_AVAILABILITIES, type HintAvailability, type InteractionState, MATERIAL_VARIANTS$1 as MATERIAL_VARIANTS, type MaterialProfile$1 as MaterialProfile, type MaterialRequest, type MaterialVariant$1 as MaterialVariant, type MotionChannel, type MotionDriverKind, NOMINAL_ACCESSIBILITY_POLICY, OVERRIDABLE_ACCESSIBILITY_FLAGS, type OverridableAccessibilityFlag, type PlaneOverlap, type PlatformProbe, type ProxyOverlap, RENDERER_TIERS, type RecoveryContract, type RecoveryTrigger, type Rect$1 as Rect, type RefractionQuality, type RendererTier, type ResolvedAccessibilityPolicy, type ResolvedBackdropHint, type ResolvedForegroundAdaptation, type ResolvedGroup, type ResolvedMaterial, type ResolvedMaterialPolicy, type ResolvedMotionPolicy, type ResolvedNode, SAMPLED_ASYNC_DEFAULTS, SAMPLED_ASYNC_RATE_LIMITS, type SamplingBackend, type SceneResolution, type ShapeChannels, type ShapeFamily, type SourceProbe, type StateChange, type SurfaceBackdropToneAbscissa$1 as SurfaceBackdropToneAbscissa, type SystemAccessibilityPreferences, type TextureBackdropSource, type TintColor, type TintMixingCheck, VITREA_CONTRACTS, type VariantMixingCheck, type Vec2, type VideoProviderOptions, WEBGPU_AVAILABILITIES, type WebGPUAvailability$1 as WebGPUAvailability, type WebGPURendererModule, type ZSlot, checkTintMixing, checkVariantMixing, classifyStateChange, clipRect, compareZSlot, createDiagnosticsChannel, createFrameScheduler, createGlassScene, defaultForegroundAdaptation, glassTint, inflateRect, isHealthy, loadWebGPURenderer, loadWebGPURendererModule, rectsOverlap, resolveAccessibilityPolicy, resolveBackdropHint, resolveForegroundAdaptation, resolveGlassGroupState, resolveMaterial, unionRect };
package/dist/index.js CHANGED
@@ -1092,7 +1092,7 @@ function isHealthy(state) {
1092
1092
 
1093
1093
  // src/renderer-seam.ts
1094
1094
  async function loadWebGPURendererModule() {
1095
- return import('./dist-T7PRMUM4.js');
1095
+ return import('./dist-VQPRX7BX.js');
1096
1096
  }
1097
1097
  async function loadWebGPURenderer() {
1098
1098
  const { createWebGPURenderer } = await loadWebGPURendererModule();