gitframes 1.2.35 → 1.3.1
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/audio/index.mjs +4 -4
- package/dist/{audio-C4kiPbrV.mjs → audio-DvL7gQQ8.mjs} +3 -3
- package/dist/{audio-C4kiPbrV.mjs.map → audio-DvL7gQQ8.mjs.map} +1 -1
- package/dist/{audio-CiXUMGyk.mjs → audio-sZdRh_qg.mjs} +3 -3
- package/dist/{audio-CiXUMGyk.mjs.map → audio-sZdRh_qg.mjs.map} +1 -1
- package/dist/{dist-C37594c6.mjs → dist-8vbhZYqX.mjs} +471 -152
- package/dist/dist-8vbhZYqX.mjs.map +1 -0
- package/dist/{dist-CMF9eNLB.mjs → dist-B0vCkDzJ.mjs} +37 -3
- package/dist/dist-B0vCkDzJ.mjs.map +1 -0
- package/dist/effects/index.d.mts +2 -2
- package/dist/effects/index.mjs +3 -3
- package/dist/{effects-4t4qk-BR.mjs → effects-C3nV-k4T.mjs} +949 -1559
- package/dist/effects-C3nV-k4T.mjs.map +1 -0
- package/dist/fonts/index.mjs +1 -1
- package/dist/{fonts-Dn18r_ST.mjs → fonts-dn-pl4Pe.mjs} +3 -3
- package/dist/{fonts-Dn18r_ST.mjs.map → fonts-dn-pl4Pe.mjs.map} +1 -1
- package/dist/{index-YZsTjqut.d.mts → index-D-O2kwLx.d.mts} +3 -3
- package/dist/{index-YZsTjqut.d.mts.map → index-D-O2kwLx.d.mts.map} +1 -1
- package/dist/{index-B1557AUi.d.mts → index-t9GyO4Ei.d.mts} +35 -50
- package/dist/index-t9GyO4Ei.d.mts.map +1 -0
- package/dist/index.d.mts +89 -79
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +142 -126
- package/dist/index.mjs.map +1 -1
- package/dist/react/index.mjs +2 -2
- package/dist/renderer/index.d.mts +2 -2
- package/dist/renderer/index.mjs +3 -3
- package/dist/{renderer-DVi31fSv.mjs → renderer-CMDIVxhv.mjs} +317 -14
- package/dist/renderer-CMDIVxhv.mjs.map +1 -0
- package/dist/{renderers-CLJQRPVU-CMZnHNK0.mjs → renderers-CLJQRPVU-DuQ7-PaC.mjs} +3 -3
- package/dist/{renderers-CLJQRPVU-CMZnHNK0.mjs.map → renderers-CLJQRPVU-DuQ7-PaC.mjs.map} +1 -1
- package/dist/signals/index.mjs +5 -5
- package/dist/{signals-BB_kdndF.mjs → signals-CLaCq092.mjs} +2 -2
- package/dist/{signals-BB_kdndF.mjs.map → signals-CLaCq092.mjs.map} +1 -1
- package/package.json +55 -55
- package/dist/dist-C37594c6.mjs.map +0 -1
- package/dist/dist-CMF9eNLB.mjs.map +0 -1
- package/dist/effects-4t4qk-BR.mjs.map +0 -1
- package/dist/index-B1557AUi.d.mts.map +0 -1
- package/dist/renderer-DVi31fSv.mjs.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { C as SlugGeometry, F as drawLottieNode, G as inputStore, I as drawParagraphNode, L as drawSignalNode, N as drawGifNode, P as drawImageNode, R as drawSvgNode, S as SlugFontCache, X as mediaDecoderCache, Y as lutStore, at as useRenderContext, ct as getEnv, j as drawCaptionNode, k as clearVideoNodeState, lt as resolveMediaSourceUrl, nt as shaderStore, ot as GetFontAssetUrl, rt as signalRegistry, tt as registerHeadlessFont, z as drawVideoNode } from "./dist-8vbhZYqX.mjs";
|
|
2
2
|
import { nanoid } from "nanoid";
|
|
3
3
|
import z$1, { z } from "zod";
|
|
4
4
|
import { AudioSample, AudioSampleSink, AudioSampleSource, Mp3OutputFormat, Mp4OutputFormat, Output, QUALITY_VERY_HIGH, VideoSample, VideoSampleSource, WebMOutputFormat, canEncodeAudio } from "mediabunny";
|
|
@@ -763,6 +763,36 @@ const NodeMetadataSchema = z$1.object({
|
|
|
763
763
|
resultSchema: z$1.custom().optional(),
|
|
764
764
|
configHandles: z$1.array(ConfigHandleSchema).optional()
|
|
765
765
|
});
|
|
766
|
+
const STORE_KEY = Symbol.for("gitframes.renderDiagnostics");
|
|
767
|
+
const diagnosticsByRender = globalThis[STORE_KEY] ?? (globalThis[STORE_KEY] = /* @__PURE__ */ new Map());
|
|
768
|
+
const MAX_TRACKED_RENDERS = 256;
|
|
769
|
+
/** Record a diagnostic for a render; repeats (same code, layer and message) are kept once. */
|
|
770
|
+
function reportRenderDiagnostic(renderId, diagnostic) {
|
|
771
|
+
let forRender = diagnosticsByRender.get(renderId);
|
|
772
|
+
if (!forRender) {
|
|
773
|
+
if (diagnosticsByRender.size >= MAX_TRACKED_RENDERS) {
|
|
774
|
+
const oldest = diagnosticsByRender.keys().next().value;
|
|
775
|
+
if (oldest !== void 0) diagnosticsByRender.delete(oldest);
|
|
776
|
+
}
|
|
777
|
+
forRender = /* @__PURE__ */ new Map();
|
|
778
|
+
diagnosticsByRender.set(renderId, forRender);
|
|
779
|
+
}
|
|
780
|
+
const key = `${diagnostic.code}|${diagnostic.layerId ?? ""}|${diagnostic.message}`;
|
|
781
|
+
if (!forRender.has(key)) forRender.set(key, diagnostic);
|
|
782
|
+
}
|
|
783
|
+
/**
|
|
784
|
+
* Everything reported for a render, including its nested compositions (they
|
|
785
|
+
* render under derived ids, `${renderId}-…`), removing it from the store.
|
|
786
|
+
*/
|
|
787
|
+
function takeRenderDiagnostics(renderId) {
|
|
788
|
+
const collected = /* @__PURE__ */ new Map();
|
|
789
|
+
for (const [id, forRender] of diagnosticsByRender) {
|
|
790
|
+
if (id !== renderId && !id.startsWith(`${renderId}-`)) continue;
|
|
791
|
+
for (const [key, diagnostic] of forRender) collected.set(key, diagnostic);
|
|
792
|
+
diagnosticsByRender.delete(id);
|
|
793
|
+
}
|
|
794
|
+
return [...collected.values()];
|
|
795
|
+
}
|
|
766
796
|
const DataTypeVal = {
|
|
767
797
|
Text: "Text",
|
|
768
798
|
Number: "Number",
|
|
@@ -3001,8 +3031,10 @@ function normalizeTimeline(vv, fps, context = { timeOffsetSec: 0 }) {
|
|
|
3001
3031
|
children: (children || []).map((child) => normalizeTimeline(child, fps, childContext))
|
|
3002
3032
|
};
|
|
3003
3033
|
}
|
|
3034
|
+
const verbose = typeof process !== "undefined" && /^(debug|trace)$/i.test(process.env?.LOG_LEVEL ?? "");
|
|
3004
3035
|
let mediaLogger = {
|
|
3005
3036
|
info: (msg, ...args) => {
|
|
3037
|
+
if (!verbose) return;
|
|
3006
3038
|
if (typeof msg === "object" && msg !== null) console.info("[AudioExtractor]", msg, ...args);
|
|
3007
3039
|
else console.info(`[AudioExtractor] ${msg}`, ...args);
|
|
3008
3040
|
},
|
|
@@ -3691,6 +3723,7 @@ async function drawCompositionTree(ctx, encoder, targetView, targetTexture, targ
|
|
|
3691
3723
|
height: opText.height ? Number(opText.height) : void 0,
|
|
3692
3724
|
lineHeight: Number(opText.lineHeight ?? 1.2),
|
|
3693
3725
|
align: opText.align,
|
|
3726
|
+
verticalAlign: opText.verticalAlign,
|
|
3694
3727
|
fontWeight: opText.fontWeight,
|
|
3695
3728
|
fontStyle: opText.fontStyle,
|
|
3696
3729
|
letterSpacing: opText.letterSpacing,
|
|
@@ -3800,6 +3833,7 @@ async function drawCompositionTree(ctx, encoder, targetView, targetTexture, targ
|
|
|
3800
3833
|
height: opText.height ? Number(opText.height) : void 0,
|
|
3801
3834
|
lineHeight: Number(opText.lineHeight ?? 1.2),
|
|
3802
3835
|
align: opText.align,
|
|
3836
|
+
verticalAlign: opText.verticalAlign,
|
|
3803
3837
|
fontWeight: opText.fontWeight,
|
|
3804
3838
|
fontStyle: opText.fontStyle,
|
|
3805
3839
|
letterSpacing: opText.letterSpacing,
|
|
@@ -4058,5 +4092,5 @@ if (typeof window !== "undefined" && !isNode) canEncodeAudio("mp3").then((suppor
|
|
|
4058
4092
|
}).catch(() => {});
|
|
4059
4093
|
|
|
4060
4094
|
//#endregion
|
|
4061
|
-
export { DataTypes as $, frameArraySignal as $t, ImageResultSchema as A, TextOperationSchema as At, BaseMediaOperationPropsSchema as B, VideoTimingPropsSchema as Bt, preloadFont as C, SignalDataSchema as Ct, useCurrentFrame as D, SingleOutputGenericSchema as Dt, springCalculation as E, SignalStatsSchema as Et, defineRenderer as F, VideoAnimationSchema as Ft, ConfigHandleSchema as G, computed as Gt, CAPTION_LAYER_DEFAULTS as H, appendOperation as Ht, registerWebGPURenderer as I, VideoLayerTypeSchema as It, DEFAULT_DURATION_MS as J, createVirtualMedia as Jt, ConfigSchemaRegistry as K, cosineSignal as Kt, AnimationTypeSchema as L, VideoSpatialPropsSchema as Lt, VideoResultSchema as M, TimelineTransformSchema as Mt, configBuilder as N, TransitionSchema as Nt, useVideoConfig as O, SourceOperationSchema as Ot, audioRegistry as P, TransitionTypeSchema as Pt, DataTypeVal as Q, findSourceAsset as Qt, AnyOutputUnionSchema as R, VideoStylePropsSchema as Rt, parseColorToRgb as S,
|
|
4062
|
-
//# sourceMappingURL=dist-
|
|
4095
|
+
export { DataTypes as $, frameArraySignal as $t, ImageResultSchema as A, TextOperationSchema as At, BaseMediaOperationPropsSchema as B, VideoTimingPropsSchema as Bt, preloadFont as C, timeSignal as Cn, SignalDataSchema as Ct, useCurrentFrame as D, SingleOutputGenericSchema as Dt, springCalculation as E, SignalStatsSchema as Et, defineRenderer as F, VideoAnimationSchema as Ft, ConfigHandleSchema as G, computed as Gt, CAPTION_LAYER_DEFAULTS as H, appendOperation as Ht, registerWebGPURenderer as I, VideoLayerTypeSchema as It, DEFAULT_DURATION_MS as J, createVirtualMedia as Jt, ConfigSchemaRegistry as K, cosineSignal as Kt, AnimationTypeSchema as L, VideoSpatialPropsSchema as Lt, VideoResultSchema as M, TimelineTransformSchema as Mt, configBuilder as N, TransitionSchema as Nt, useVideoConfig as O, SourceOperationSchema as Ot, audioRegistry as P, TransitionTypeSchema as Pt, DataTypeVal as Q, findSourceAsset as Qt, AnyOutputUnionSchema as R, VideoStylePropsSchema as Rt, parseColorToRgb as S, takeRenderDiagnostics as Sn, SignalChannelMetaSchema as St, spring as T, SignalMathDataSchema as Tt, COMPOSITE_OPERATIONS$1 as U, checkNodeResultCache as Ut, BaseVideoLayerPropsSchema as V, VirtualMediaDataSchema as Vt, COMPOSITOR_DEFAULTS as W, computeVideoCropRenderProps as Wt, DEFAULT_MEDIA_DIMENSION as X, deserializeSignalData as Xt, DEFAULT_FPS as Y, dataTypeColors as Yt, DataType as Z, extractSvgDimensions as Zt, interpolate as _, serializeSignalData as _n, NodeResultSchema as _t, mixAudioTracks as a, getLeafMediaType as an, GeneratorSignalDataSchema as at, measureText as b, sineSignal as bn, ProgrammaticSignal as bt, LIGHT_UNIFORM_SIZE_BYTES as c, hasOnlySingleSource as cn, JsonValueSchema as ct, PlaybackContext as d, isVirtualMediaData as dn, MediaOperationSchema as dt, frameSignal as en, Effect as et, PlaybackProvider as f, programmaticSignal as fn, MediaSourceSchema as ft, hasDelayRender as g, resolveMediaMimeType as gn, NodeMetadataSchema as gt, computeStrokeRect as h, reportRenderDiagnostic as hn, MultiOutputGenericSchema as ht, drawCompositionTree as i, getFingerprint as in, FileDataSchema as it, SignalResultSchema as j, TimelineSegmentSchema as jt, ColorSchema as k, TEXT_LAYER_DEFAULTS as kt, MAX_LIGHTS as l, isEqual as ln, MIME_TYPES as lt, bezier as m, registerSignalDependency as mn, ModerationUnrefundableError as mt, compositionStateStore as n, getActiveMediaMetadata as nn, ExtendedLayerSchema as nt, useCompositionState as o, getMediaType as on, GlobalCompositeOperation$1 as ot, Vector3Math as p, progressSignal as pn, ModerationError as pt, DATA_TYPE_EXTENSIONS as q, createOutputItemSchema as qt, decodeAudioSource as r, getFileDataMetadata as rn, FileAssetSchema as rt, Easing as s, getRenderFingerprint as sn, HandleTypeVal as st, CanvasComposition as t, generateId as tn, ExportResultSchema as tt, Matrix4Math as u, isSignal as un, MediaMetadataSchema as ut, mapBlendModeToSkia as v, signal as vn, NodeVisualConfigSchema as vt, requiresIsolation as w, updateClockSignals as wn, SignalGateDataSchema as wt, measureTextAsync as x, stampResult as xn, Signal as xt, measureSpring as y, signalBuilder as yn, OutputItemSchema as yt, AudioExtractorSignalDataSchema as z, VideoTextPropsSchema as zt };
|
|
4096
|
+
//# sourceMappingURL=dist-B0vCkDzJ.mjs.map
|