@motionscript/core 0.1.1-alpha.4 → 0.1.1-alpha.5

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.
@@ -1,2 +1,2 @@
1
- import{Ee as d,Fe as m,Ge as p,Kd as o,Ld as r,Od as s,Re as f,Sd as n,Td as t,We as _,Yd as a,ee as c,ie as x,te as i,ye as e}from"./chunks/chunk-BPA7KSK2.js";import"./chunks/chunk-5TDMGUXQ.js";var v=o,w=m,S=p,h=t,C=r,D=e;export{x as Aim,s as Corners,n as Flow,f as Material,a as Paint,c as Shapes,i as TextLayout,d as TextStyle,C as Types,_ as View3D,h as commandsFor,v as component2d,S as component3d,w as componentAudio,D as provides};
1
+ import{Ee as d,Fe as m,Ge as p,Kd as o,Ld as r,Od as s,Re as f,Sd as n,Td as t,We as _,Yd as a,ee as c,ie as x,te as i,ye as e}from"./chunks/chunk-XCGYJHZR.js";import"./chunks/chunk-5TDMGUXQ.js";var v=o,w=m,S=p,h=t,C=r,D=e;export{x as Aim,s as Corners,n as Flow,f as Material,a as Paint,c as Shapes,i as TextLayout,d as TextStyle,C as Types,_ as View3D,h as commandsFor,v as component2d,S as component3d,w as componentAudio,D as provides};
2
2
  //# sourceMappingURL=experimental.js.map
@@ -1,2 +1,2 @@
1
- import{$ as $o,$a as Ri,$b as Wa,A as io,Aa as ci,Ab as ma,Ac as pn,B as ao,Ba as gi,Bb as ca,Bc as mn,C as no,Ca as li,Cb as ga,Cc as cn,D as fo,Da as xi,Db as la,Dc as gn,E as ho,Ea as ui,Eb as xa,Ec as ln,F as po,Fa as wi,Fb as ua,Fc as w,G as mo,Ga as yi,Gb as wa,Gc as xn,H as co,Ha as _i,Hb as ya,Hc as y,I as go,Ia as Ai,Ib as _a,Ic as _,J as Fo,Ja as Fi,Jb as Aa,Jc as f,K as Lo,Ka as Li,Kb as Fa,Kc as un,L as Po,La as Pi,Lb as La,Lc as wn,M as Eo,Ma as Ei,Mb as Pa,Mc as yn,N as No,Na as Ni,Nb as Ea,Nc as _n,O as So,Oa as Si,Ob as Na,Oc as Ln,P as To,Pa as Ti,Pb as Sa,Pc as Pn,Q as bo,Qa as bi,Qb as Ta,Qc as En,R as Do,Ra as Di,Rb as x,Rc as Nn,S as Mo,Sa as Mi,Sb as u,T as Uo,Ta as Ui,Tb as ba,U as vo,Ua as vi,Ub as Da,V as Vo,Va as Vi,Vb as Ma,W as Co,Wa as Ci,Wb as Ua,X as Io,Xa as Ii,Xb as va,Y as Wo,Ya as d,Yb as Va,Z as Ko,Za as Wi,Zb as Ca,_ as Ro,_a as Ki,_b as Ia,a as Ze,aa as jo,ab as $i,ac as Ka,b as ke,ba as Yo,bb as ji,bc as Ra,c as Oe,ca as qo,cb as Yi,cc as $a,d as tr,da as zo,db as qi,dc as ja,e as er,ea as Bo,eb as zi,ec as Ya,f as rr,fa as Go,fb as Bi,fc as qa,g as sr,ga as Ho,gb as Gi,gc as za,h as or,ha as Jo,hb as Hi,hc as Ba,i as ir,ia as Qo,ib as Ji,ic as Ga,j as br,ja as Xo,jb as Qi,jc as Ha,k as Dr,ka as Zo,kb as Xi,kc as Ja,l as Mr,la as ko,lb as Zi,lc as Qa,m as Ur,ma as Oo,mb as ki,mc as Xa,n as gs,na as ti,nb as Oi,nc as Za,o as ls,oa as ei,ob as ta,oc as ka,p as xs,pa as ri,pb as ea,pc as Oa,q as us,qa as si,qb as ra,qc as tn,r as Ls,ra as oi,rb as sa,rc as en,s as Zs,sa as ii,sb as oa,sc as rn,t as ks,ta as ai,tb as ia,tc as sn,u as Os,ua as ni,ub as aa,uc as on,v as to,va as di,vb as na,vc as an,w as eo,wa as fi,wb as da,wc as nn,x as ro,xa as hi,xb as fa,xc as dn,y as so,ya as pi,yb as ha,yc as fn,z as oo,za as mi,zb as pa,zc as hn}from"./chunks/chunk-TL432UO5.js";import{$ as St,$a as Te,$c as cs,A as et,Aa as kt,Ab as fr,Ac as Zr,Ad as Bs,B as rt,Ba as Ot,Bb as hr,Bd as Gs,C as st,Ca as te,Cb as pr,Cc as kr,Cd as Hs,D as ot,Da as ee,Db as mr,Dc as o,E as it,Ea as re,Eb as cr,Ec as Or,Ed as Js,Fa as se,Fb as gr,Fc as ts,G as at,Gb as lr,Gc as es,H as nt,Ha as oe,Hb as xr,Hc as rs,Hd as Qs,I as dt,Ia as ie,Ib as ur,Ic as ss,Id as Xs,J as ft,Jb as wr,Jc as os,K as ht,Ka as ae,Kb as yr,Kc as is,L as pt,La as me,Lb as _r,Lc as as,M as mt,Ma as ce,Mc as ns,N as ct,Na as ge,Nc as ds,O as gt,Oa as le,Ob as Ar,Oc as fs,P as lt,Pa as xe,Pb as Fr,Q as xt,Qa as ue,Qb as Lr,R as ut,Ra as we,Rb as Pr,S as wt,Sa as ye,Sb as Er,T as yt,Ta as _e,Tb as Nr,Tc as hs,U as _t,Ua as Ae,Ub as Sr,V as At,Va as Fe,Vb as Tr,W as Ft,Wa as Le,X as Lt,Xa as Pe,Y as Pt,Ya as Ee,Z as Et,Za as Ne,Zb as g,Zc as ps,_ as Nt,_a as Se,_c as ms,a as F,aa as Tt,ab as be,ad as ws,b as L,ba as bt,bb as De,bd as ys,c as P,ca as Dt,cb as Me,cd as _s,d as S,da as Mt,db as Ue,dd as As,e as T,ed as Fs,f as b,fa as Ut,fb as ve,fc as vr,fd as Ps,g as C,ga as vt,gb as Ve,gc as Vr,gd as Es,h as I,ha as Vt,hb as Ce,hc as Cr,hd as Ns,i as W,ia as Ct,ib as Ie,ic as Ir,id as Ss,j as K,ja as It,jb as We,jc as Wr,jd as Ts,je as lo,k as R,ka as Wt,kb as Ke,kc as Kr,kd as bs,ke as xo,l as $,la as Kt,lb as Re,lc as Rr,ld as Ds,le as uo,m as j,ma as Rt,mb as $e,mc as $r,md as Ms,n as Y,na as $t,nb as je,nc as jr,nd as Us,o as q,ob as Ye,oc as Yr,od as vs,p as z,pa as jt,pb as qe,pc as qr,pd as Vs,q as B,qa as Yt,qb as ze,qc as zr,qd as Cs,r as G,ra as qt,rb as Be,rc as Br,rd as Is,s as H,sa as zt,sb as Ge,sc as Gr,sd as Ws,t as J,ta as Bt,tb as He,tc as Hr,td as Ks,u as Q,ua as Gt,ub as Je,uc as Jr,ud as Rs,ue as wo,v as X,va as Ht,vb as Qe,vc as Qr,vd as $s,ve as yo,w as Z,wa as Jt,wb as Xe,wc as l,wd as js,we as _o,x as k,xa as Qt,xb as ar,xd as Ys,xe as Ao,y as O,ya as Xt,yb as nr,yd as qs,z as tt,za as Zt,zb as dr,zc as Xr,zd as zs}from"./chunks/chunk-BPA7KSK2.js";import{g as An,h as Fn}from"./chunks/chunk-GEJEQQER.js";import{b as E,c as N,d as D,e as M,f as U,g as v,h as V,i as ne,j as de,k as fe,l as he,m as pe}from"./chunks/chunk-5TDMGUXQ.js";var p={width:1920,height:1080},m=60,bn={viewport:p,fps:m},A={image:{},video:{},audio:{},font:{}},h=class{platform;viewport;fps;constructor(t,e={}){this.platform=t,this._registry=new d({nodes:e.nodes,shaders:e.shaders,lerps:e.lerps,dynamicNodes:e.dynamicNodes,strict:e.strict}),this.viewport=e.viewport??p,this.fps=e.fps??m,this._manifest=e.manifest??A,this._exporter=t.createExporter()}get manifest(){return this._manifest}get exporter(){return this._exporter}setManifest(t){this._manifest=t;for(let e of this._manifestListeners)e(t)}open(t){return new f(this,t)}knows(t){return this._registry.hasNode(t)}get registry(){return this._registry}async registerNode(t,e){return typeof t=="string"?this._registry.addNodeFromSource(t,e):(this._registry.addNode(t,e),t)}registerShader(t,e,r){return this._registry.addShader(t,e,r)}dispose(){this._manifestListeners.clear(),this.platform.dispose?.()}_registry;_manifest;_exporter;_manifestListeners=new Set;_onManifestChange(t){return this._manifestListeners.add(t),()=>this._manifestListeners.delete(t)}};var i=class{get schedulesAudio(){return!0}setMuted(t){}setVolume(t){}dispose(){this.stop()}};var a=class{catalog;viewport;constructor(t,e){this.catalog=t,this.viewport=e}setCatalog(t){this.catalog=t}inFlightLoads=new Map;cachedAssets=new Set;isLoaded(t){return this.cachedAssets.has(t)}async loadAsset(t,e){let r=this.inFlightLoads.get(t);if(r)return r;if(this.cachedAssets.has(t))return;let s=this.runLoad(t,e);this.inFlightLoads.set(t,s);try{await s}finally{this.inFlightLoads.delete(t)}}async runLoad(t,e){let r=!0;switch(e.type){case"image":await this.loadImage(t);break;case"video":await this.loadVideo(t,e.startFrame,e.endFrame,e.trimStart,e.trimEnd);break;case"font":{let{fontFamily:s,fontWeight:c}=this.parseFontKey(t);if(r=await this.loadFont(t,s,c),!r&&this.getDecodePolicy()==="exact")throw new o("font",s,`The manifest has no font entry for "${s}", so this frame would be shaped against the fallback face and differ from the one drawn once it is described. Add the family to the manifest's font record.`);break}case"audio":break;case"loader":throw new Error("Loader records must not be routed through StorageAdapter.loadAsset");default:{let s=e;throw new Error(`Unsupported asset type: ${s.type}`)}}r&&this.cachedAssets.add(t)}parseFontKey(t){let[e,r]=t.split("@"),s=r?parseInt(r,10):400;return{fontFamily:e||t,fontWeight:isNaN(s)?400:s}}async warmPendingVideo(){return!1}setDecodePolicy(t){}getDecodePolicy(){return"interactive"}hasPendingDecodes(){return!1}async warmPendingDecodes(){return this.warmPendingVideo()}hasPendingUpgrades(){return!1}async warmPendingUpgrades(){return!1}setPlaying(t){}dispose(){this.inFlightLoads.clear(),this.cachedAssets.clear()}};export{z as ASCII_CHARSETS,ji as AUDIO_ROOT_ID,lo as AUTOFIT_PROBE_SIZE,Pt as AdjustmentChain,Nt as Adjustments,ei as AmbientLight3D,ai as AreaLight3D,u as AssetDeclaration,x as AssetManager,o as AssetNotLoadedError,Ja as AssetTimeline,bo as AudioBus,Je as AudioEffectChain,ar as AudioEffectRegistry,Qe as AudioEffects,i as AudioSink,G as BLEND_MODES_LIST,ho as BooleanGroup,Co as Box3D,Xr as COMMAND_META,mo as Camera,ni as Camera3D,Ls as Canvas2D,hi as Canvas3D,Qs as CanvasRenderContext2D,zo as Capsule3D,Yo as Circle3D,hs as Clip,ja as ClipInstance,qa as ClipStore,Bi as ClipTimeline,Ro as Cone3D,Qr as ContextMap,Ko as Cylinder3D,le as DEFAULT_CAP_SCALE,Pe as DEFAULT_EASE,m as DEFAULT_FPS,bn as DEFAULT_OUTPUT,Ya as DEFAULT_PRECOMP_BUDGET_MS,p as DEFAULT_VIEWPORT,Ei as DOCUMENT_FORMAT_VERSION,Si as DOCUMENT_MIGRATIONS,jt as DRAWABLE_KINDS,_o as DataToken,Eo as DefaultTextStyle,si as DirectionalLight3D,Ni as DocumentTooNewError,R as EFFECT_OPTION_KEYS,A as EMPTY_MANIFEST,ne as EMPTY_PATH_DATA,Nr as EMPTY_TEXT_STYLE,dt as EffectChain,ft as Effects,ks as Ellipse,h as Engine,fi as Environment3D,Gs as ExpressionError,Go as Extrude3D,lt as FillChain,xt as Fills,di as Fog3D,ta as Geo,vt as Graphics2D,qt as Graphics3D,vo as Group3D,ri as HemisphereLight3D,ao as Hexagon,is as IDENTITY_QUATERNION,Qo as Instances3D,Ho as Lathe3D,Zo as Line3D,Dr as MAX_SHADER_PROPERTIES,Mr as MAX_SHADER_SOURCE,wt as MINOR_WIDTH_RATIO,Sa as MUTABLE_MATERIAL_KEYS,w as ManifestAssetCatalog,po as MaskGroup,ea as Mat,Vo as Mesh3D,Oo as Model3D,ti as ModelView3D,Ns as NODE_META,xr as NO_PROJECTION_3D,kr as Node,ps as Node2D,Es as Node3D,ws as NodeAudio,H as NodeBlendModes,Xs as NullRenderContext,Lo as NumberNode,no as Octagon,co as OrbitCamera,de as PATH_UNIT_EXTENT,fe as PATH_UNIT_HALF,ro as Path,Ut as PathBuilder,eo as PathShape,io as Pentagon,Wo as Plane3D,xn as Playback,ln as PlaybackController,oi as PointLight3D,Xo as Points3D,Os as Polygon,to as Polygram,Bo as Polyhedron3D,g as PropSlot,No as Provider,li as ROOT_NODE_ID,Ce as RampChain,En as Random,Zs as Rect,d as Registry,ki as RenderBackendError,zt as RenderContext3D,Po as RichText,oo as RightTriangle,qo as Ring3D,go as RotatedBox,Ba as SETTLE_PASSES,bs as SHAPE_ALIGNMENT_KEYS,Ta as STRUCTURAL_MATERIAL_KEYS,Gt as Scene3D,Pn as SeedGenerator,Ao as SeedToken,f as Session,tr as Sound,To as SoundNode,Io as Sphere3D,ii as SpotLight3D,ko as Sprite3D,fo as Star,za as StateEvaluator,_ as SteppedClock,a as StorageAdapter,te as TEXTURE_KEYS,Er as TEXT_SHAPING_KEYS,Pr as TEXT_STYLE_KEYS,ra as Tex,Fo as Text,wo as TextStyleToken,So as ThemeProvider,yo as ThemeToken,y as Ticker,$o as Torus3D,jo as TorusKnot3D,so as Triangle,Jo as Tube3D,he as UNIT_PATH_BOX,Do as Video,Et as VideoAdjustmentChain,St as VideoAdjustments,et as WGSL_CONTRACT,Ma as __resetSchedulerForTests,bt as alignmentOps,us as applyEditorStates,ga as applyMatrix4,mr as applyToPoint,Pi as asProjectDocument,vi as assertValidDocument,Ui as assertValidProjectDocument,nr as audioEffectsOps,Be as audioParamOps,ct as backdropEffects,ys as busPathOf,_s as busPathTo,ir as busStopKey,gr as cameraMatrix,oe as canLerpFill,Ht as canvas3DResourceKey,kt as canvas3DResourceLoader,Qi as caretCount,cn as caretOffsetAt,gn as caretRangeQuads,Fa as centeredBox3,en as childPlanePointAt,Fe as clamp,Le as clamp01,zi as clipDocument,Oe as clipDurationOf,Ua as clipFrameToTime,Ze as clipTimeAtSource,va as clipTimeToFrame,pn as collectBoxes,Xa as collectBoxes3D,Y as colorOps,Br as commandParallel,zr as commandSequence,Ai as commandSpan,la as compose4,Rs as containsClip,$s as containsOps,S as cornerRadiusOps,T as cornerStyleOps,Pa as corners3,Ha as createAssetTimelineProfile,Jr as createContext,Ln as createRef,Ue as curveEase,De as curveSegmentT,be as curveSegments,da as cylinderRadii,st as describeEffect,Bs as distanceToSegment,Fi as documentDuration,Ti as documentFormatVersion,Yr as driveCommand,Ne as easeIn,Te as easeInOut,ve as easeOfSpec,Se as easeOut,ot as effectDescriptors,it as effectSurface,ui as effectiveSpan,yi as effectiveSpanIn,wi as effectiveSpans,er as effectsKey,pt as effectsOps,Fn as enterBudget,ze as equalsParam,os as euler3Ops,ha as evaluateParametric,oa as evaluateRoundedBox,Hs as expressionOps,wr as facesAway,ae as fillOps,Ft as filterSurface,As as findBusById,ms as findNode2D,Or as flowOps,re as forEachTexture3D,gt as foregroundShaderEffects,cs as frameIn,Va as frameSpecAtTime,Ra as frameTime,_n as generateList,Na as geometryBounds3D,J as getBlendModeHash,Zr as getCommandMeta,Ss as getNodeDescriptor,l as getPropSlot,Tr as getPropertyMeta,v as getTypographyPreset,on as handleValueAt,Ot as hasCanvas3DBackend,_t as hasFilter,ur as hasProjection3D,gi as hasTimeline,We as hold,fr as identity,pa as identity4,Dt as insetsOps,Ge as integrateSpeedToClipTime,cr as invert,ca as invert4,ci as isAudioDocument,mt as isBackdropEffect,$r as isCommand,mi as isCompositionDocument,Ct as isDataTexture3D,Me as isEaseCurve,Oi as isFatalRenderIssue,br as isKnownShaderProperty,Mo as isOrbitCamera3D,yt as isPixelFilter,Li as isProjectDocument,dr as isProjective,Ke as isRamp,Nn as isSteppable,pi as isStillDocument,xe as isStrokeMarker,It as isSurfaceTexture3D,ee as isTextureLike,P as isUniformCorners,Qa as isViewport3D,tt as isWgslShader,j as lerpColor,b as lerpCornerScalarStyle,L as lerpCorners,at as lerpEffect,ss as lerpEuler3,ie as lerpFill,At as lerpFilter,Lt as lerpFilterArray,_r as lerpLookAt,E as lerpNumber,qe as lerpParam,N as lerpPerspective,k as lerpUniformRecord,X as lerpUniformValue,D as lerpVector2,es as lerpVector3,Ee as linear,xa as lookAtRotation4,Rt as looksLikeAssetPath,qr as loopCommand,Vr as loopPasses,Wr as loopPhase,Cr as loopRepeats,Ir as loopSpan,Yi as loweredAudioDocument,jr as makeCommand,bi as migrateDocument,Js as migrateNodeProps,Vi as missingNodeOf,pr as multiply,ma as multiply4,zs as nearPolyline,An as niceStep,dn as nodeAt,an as nodeBox,nn as nodeBoxAt,sn as nodeHandlesAt,lr as nodeLocalMatrix,gs as nodePath,yr as nodeProjectedMatrix,xi as nodeSpan,mn as nodeTextLayout,Wi as nodeTypeIsA,ns as normalizeQuaternion,Ur as normalizeShaderPack,Q as normalizeUniforms,ba as now,Aa as orthographic4,Ye as paramKey,Ki as parentIssue,tn as parentPlanePointAt,Ps as parentSpaceOf,wn as parseCSV,Jt as parseCanvas3DResourceKey,V as parseColor,yn as parseData,pe as pathOps,_a as perspective4,hn as pickNode,ka as pickNode3D,Ia as placeTracks,$i as placementIssues,qs as pointInPolygon,js as polygonVertices,Ys as polygramVertices,Hr as prepareNumericCellTween,Gr as prepareNumericTween,xs as primeMotionTree,Za as projectNode3D,fn as projectNode3DAt,ds as quaternionFromEuler,fs as quaternionOps,Ie as ramp,Xt as registerCanvas3DResourceLoader,Qt as registerCanvas3DWarmup,Ci as registryVocabulary,Zi as renderIssueKey,Oa as renderMatrix,Ga as renderSettled,rn as reparentPlacementAt,xo as requireFontFamily,B as resolveAsciiCharset,Xe as resolveAudioEffects,fa as resolveBevel3D,Uo as resolveCameraPlacement,Tt as resolveChainAdjustments,ht as resolveChainEffects,ut as resolveChainFill,F as resolveCorners,C as resolveEffectAxis,W as resolveEffectColor,se as resolveFill,$t as resolveFill3D,Yt as resolveMaterialShorthand3D,q as resolveMotionBlurAlignment,vs as resolvePivotPosition,un as resolveProjectDocument,Re as resolveRamp,nt as resolveShaderProperties,me as resolveShadow,na as resolveShadowOptions3D,Bt as resolveShadows3D,Us as resolveShapeAlignment,Ts as resolveShapePivot,_e as resolveStroke,ge as resolveStrokeAlign,ue as resolveStrokeCap,we as resolveStrokeEnd,ye as resolveStrokeJoin,Vt as resolveSurfaceSource,Wt as resolveTexture3D,ts as resolveVector3,Mt as resolveVideoTimestamp,ya as rotationOf4,I as sameEffectAxis,K as sameEffectColor,$e as sampleRamp,ls as sampleTree,sa as segmentsOf,U as setTheme,Rr as settles,Kr as settling,rt as shaderContractOf,ia as shadowCasts,ce as shadowOps,aa as shadowReceives,Ri as siblingIssue,Fr as size2DOps,Lr as sizeInputOps,as as slerpQuaternion,ke as sourceTimeAtClip,He as sourceTimeAtClipElapsed,Ar as space3dOps,$a as spanFrames,Ka as spansCovering,Ve as specOfEase,je as staticValue,Ms as stripShapeAlignmentKeys,Ae as strokeOps,Fs as structuralPathOf,Sr as textOps,Kt as texture3DSource,vr as toCommand,Hi as toPathString,Xi as toRenderIssue,Wa as totalFramesOf,Ca as trackFrameCount,Ea as transformBox3,ua as transformMatrix4,sr as transitionGainAt,or as transitionKey,rr as transitionSpans,hr as translation,wa as translation4,O as uniformRecordsEqual,Z as uniformValuesEqual,La as unionBox3,_i as untimed,Di as validateDocument,Mi as validateProjectDocument,Ds as validateShapeAlignmentProps,M as vector2Ops,rs as vector3Ops,Ii as vocabularyBreaks,Zt as warmCanvas3D,$ as withEffectOptions,Cs as withEllipseDescriptor,Ks as withLineDescriptor,Ji as withPathDescriptor,qi as withPlayedSounds,Is as withPolygonDescriptor,Ws as withPolygramDescriptor,Vs as withRectDescriptor,Gi as withRichTextDescriptor,uo as withTextDescriptor,Da as yieldToScheduler};
1
+ import{$ as $o,$a as Ri,$b as Wa,A as io,Aa as ci,Ab as ma,Ac as pn,B as ao,Ba as gi,Bb as ca,Bc as mn,C as no,Ca as li,Cb as ga,Cc as cn,D as fo,Da as xi,Db as la,Dc as gn,E as ho,Ea as ui,Eb as xa,Ec as ln,F as po,Fa as wi,Fb as ua,Fc as w,G as mo,Ga as yi,Gb as wa,Gc as xn,H as co,Ha as _i,Hb as ya,Hc as y,I as go,Ia as Ai,Ib as _a,Ic as _,J as Fo,Ja as Fi,Jb as Aa,Jc as f,K as Lo,Ka as Li,Kb as Fa,Kc as un,L as Po,La as Pi,Lb as La,Lc as wn,M as Eo,Ma as Ei,Mb as Pa,Mc as yn,N as No,Na as Ni,Nb as Ea,Nc as _n,O as So,Oa as Si,Ob as Na,Oc as Ln,P as To,Pa as Ti,Pb as Sa,Pc as Pn,Q as bo,Qa as bi,Qb as Ta,Qc as En,R as Do,Ra as Di,Rb as x,Rc as Nn,S as Mo,Sa as Mi,Sb as u,T as Uo,Ta as Ui,Tb as ba,U as vo,Ua as vi,Ub as Da,V as Vo,Va as Vi,Vb as Ma,W as Co,Wa as Ci,Wb as Ua,X as Io,Xa as Ii,Xb as va,Y as Wo,Ya as d,Yb as Va,Z as Ko,Za as Wi,Zb as Ca,_ as Ro,_a as Ki,_b as Ia,a as Ze,aa as jo,ab as $i,ac as Ka,b as ke,ba as Yo,bb as ji,bc as Ra,c as Oe,ca as qo,cb as Yi,cc as $a,d as tr,da as zo,db as qi,dc as ja,e as er,ea as Bo,eb as zi,ec as Ya,f as rr,fa as Go,fb as Bi,fc as qa,g as sr,ga as Ho,gb as Gi,gc as za,h as or,ha as Jo,hb as Hi,hc as Ba,i as ir,ia as Qo,ib as Ji,ic as Ga,j as br,ja as Xo,jb as Qi,jc as Ha,k as Dr,ka as Zo,kb as Xi,kc as Ja,l as Mr,la as ko,lb as Zi,lc as Qa,m as Ur,ma as Oo,mb as ki,mc as Xa,n as gs,na as ti,nb as Oi,nc as Za,o as ls,oa as ei,ob as ta,oc as ka,p as xs,pa as ri,pb as ea,pc as Oa,q as us,qa as si,qb as ra,qc as tn,r as Ls,ra as oi,rb as sa,rc as en,s as Zs,sa as ii,sb as oa,sc as rn,t as ks,ta as ai,tb as ia,tc as sn,u as Os,ua as ni,ub as aa,uc as on,v as to,va as di,vb as na,vc as an,w as eo,wa as fi,wb as da,wc as nn,x as ro,xa as hi,xb as fa,xc as dn,y as so,ya as pi,yb as ha,yc as fn,z as oo,za as mi,zb as pa,zc as hn}from"./chunks/chunk-FPYU47XX.js";import{$ as St,$a as Te,$c as cs,A as et,Aa as kt,Ab as fr,Ac as Zr,Ad as Bs,B as rt,Ba as Ot,Bb as hr,Bd as Gs,C as st,Ca as te,Cb as pr,Cc as kr,Cd as Hs,D as ot,Da as ee,Db as mr,Dc as o,E as it,Ea as re,Eb as cr,Ec as Or,Ed as Js,Fa as se,Fb as gr,Fc as ts,G as at,Gb as lr,Gc as es,H as nt,Ha as oe,Hb as xr,Hc as rs,Hd as Qs,I as dt,Ia as ie,Ib as ur,Ic as ss,Id as Xs,J as ft,Jb as wr,Jc as os,K as ht,Ka as ae,Kb as yr,Kc as is,L as pt,La as me,Lb as _r,Lc as as,M as mt,Ma as ce,Mc as ns,N as ct,Na as ge,Nc as ds,O as gt,Oa as le,Ob as Ar,Oc as fs,P as lt,Pa as xe,Pb as Fr,Q as xt,Qa as ue,Qb as Lr,R as ut,Ra as we,Rb as Pr,S as wt,Sa as ye,Sb as Er,T as yt,Ta as _e,Tb as Nr,Tc as hs,U as _t,Ua as Ae,Ub as Sr,V as At,Va as Fe,Vb as Tr,W as Ft,Wa as Le,X as Lt,Xa as Pe,Y as Pt,Ya as Ee,Z as Et,Za as Ne,Zb as g,Zc as ps,_ as Nt,_a as Se,_c as ms,a as F,aa as Tt,ab as be,ad as ws,b as L,ba as bt,bb as De,bd as ys,c as P,ca as Dt,cb as Me,cd as _s,d as S,da as Mt,db as Ue,dd as As,e as T,ed as Fs,f as b,fa as Ut,fb as ve,fc as vr,fd as Ps,g as C,ga as vt,gb as Ve,gc as Vr,gd as Es,h as I,ha as Vt,hb as Ce,hc as Cr,hd as Ns,i as W,ia as Ct,ib as Ie,ic as Ir,id as Ss,j as K,ja as It,jb as We,jc as Wr,jd as Ts,je as lo,k as R,ka as Wt,kb as Ke,kc as Kr,kd as bs,ke as xo,l as $,la as Kt,lb as Re,lc as Rr,ld as Ds,le as uo,m as j,ma as Rt,mb as $e,mc as $r,md as Ms,n as Y,na as $t,nb as je,nc as jr,nd as Us,o as q,ob as Ye,oc as Yr,od as vs,p as z,pa as jt,pb as qe,pc as qr,pd as Vs,q as B,qa as Yt,qb as ze,qc as zr,qd as Cs,r as G,ra as qt,rb as Be,rc as Br,rd as Is,s as H,sa as zt,sb as Ge,sc as Gr,sd as Ws,t as J,ta as Bt,tb as He,tc as Hr,td as Ks,u as Q,ua as Gt,ub as Je,uc as Jr,ud as Rs,ue as wo,v as X,va as Ht,vb as Qe,vc as Qr,vd as $s,ve as yo,w as Z,wa as Jt,wb as Xe,wc as l,wd as js,we as _o,x as k,xa as Qt,xb as ar,xd as Ys,xe as Ao,y as O,ya as Xt,yb as nr,yd as qs,z as tt,za as Zt,zb as dr,zc as Xr,zd as zs}from"./chunks/chunk-XCGYJHZR.js";import{g as An,h as Fn}from"./chunks/chunk-GEJEQQER.js";import{b as E,c as N,d as D,e as M,f as U,g as v,h as V,i as ne,j as de,k as fe,l as he,m as pe}from"./chunks/chunk-5TDMGUXQ.js";var p={width:1920,height:1080},m=60,bn={viewport:p,fps:m},A={image:{},video:{},audio:{},font:{}},h=class{platform;viewport;fps;constructor(t,e={}){this.platform=t,this._registry=new d({nodes:e.nodes,shaders:e.shaders,lerps:e.lerps,dynamicNodes:e.dynamicNodes,strict:e.strict}),this.viewport=e.viewport??p,this.fps=e.fps??m,this._manifest=e.manifest??A,this._exporter=t.createExporter()}get manifest(){return this._manifest}get exporter(){return this._exporter}setManifest(t){this._manifest=t;for(let e of this._manifestListeners)e(t)}open(t){return new f(this,t)}knows(t){return this._registry.hasNode(t)}get registry(){return this._registry}async registerNode(t,e){return typeof t=="string"?this._registry.addNodeFromSource(t,e):(this._registry.addNode(t,e),t)}registerShader(t,e,r){return this._registry.addShader(t,e,r)}dispose(){this._manifestListeners.clear(),this.platform.dispose?.()}_registry;_manifest;_exporter;_manifestListeners=new Set;_onManifestChange(t){return this._manifestListeners.add(t),()=>this._manifestListeners.delete(t)}};var i=class{get schedulesAudio(){return!0}setMuted(t){}setVolume(t){}dispose(){this.stop()}};var a=class{catalog;viewport;constructor(t,e){this.catalog=t,this.viewport=e}setCatalog(t){this.catalog=t}inFlightLoads=new Map;cachedAssets=new Set;isLoaded(t){return this.cachedAssets.has(t)}async loadAsset(t,e){let r=this.inFlightLoads.get(t);if(r)return r;if(this.cachedAssets.has(t))return;let s=this.runLoad(t,e);this.inFlightLoads.set(t,s);try{await s}finally{this.inFlightLoads.delete(t)}}async runLoad(t,e){let r=!0;switch(e.type){case"image":await this.loadImage(t);break;case"video":await this.loadVideo(t,e.startFrame,e.endFrame,e.trimStart,e.trimEnd);break;case"font":{let{fontFamily:s,fontWeight:c}=this.parseFontKey(t);if(r=await this.loadFont(t,s,c),!r&&this.getDecodePolicy()==="exact")throw new o("font",s,`The manifest has no font entry for "${s}", so this frame would be shaped against the fallback face and differ from the one drawn once it is described. Add the family to the manifest's font record.`);break}case"audio":break;case"loader":throw new Error("Loader records must not be routed through StorageAdapter.loadAsset");default:{let s=e;throw new Error(`Unsupported asset type: ${s.type}`)}}r&&this.cachedAssets.add(t)}parseFontKey(t){let[e,r]=t.split("@"),s=r?parseInt(r,10):400;return{fontFamily:e||t,fontWeight:isNaN(s)?400:s}}async warmPendingVideo(){return!1}setDecodePolicy(t){}getDecodePolicy(){return"interactive"}hasPendingDecodes(){return!1}async warmPendingDecodes(){return this.warmPendingVideo()}hasPendingUpgrades(){return!1}async warmPendingUpgrades(){return!1}setPlaying(t){}dispose(){this.inFlightLoads.clear(),this.cachedAssets.clear()}};export{z as ASCII_CHARSETS,ji as AUDIO_ROOT_ID,lo as AUTOFIT_PROBE_SIZE,Pt as AdjustmentChain,Nt as Adjustments,ei as AmbientLight3D,ai as AreaLight3D,u as AssetDeclaration,x as AssetManager,o as AssetNotLoadedError,Ja as AssetTimeline,bo as AudioBus,Je as AudioEffectChain,ar as AudioEffectRegistry,Qe as AudioEffects,i as AudioSink,G as BLEND_MODES_LIST,ho as BooleanGroup,Co as Box3D,Xr as COMMAND_META,mo as Camera,ni as Camera3D,Ls as Canvas2D,hi as Canvas3D,Qs as CanvasRenderContext2D,zo as Capsule3D,Yo as Circle3D,hs as Clip,ja as ClipInstance,qa as ClipStore,Bi as ClipTimeline,Ro as Cone3D,Qr as ContextMap,Ko as Cylinder3D,le as DEFAULT_CAP_SCALE,Pe as DEFAULT_EASE,m as DEFAULT_FPS,bn as DEFAULT_OUTPUT,Ya as DEFAULT_PRECOMP_BUDGET_MS,p as DEFAULT_VIEWPORT,Ei as DOCUMENT_FORMAT_VERSION,Si as DOCUMENT_MIGRATIONS,jt as DRAWABLE_KINDS,_o as DataToken,Eo as DefaultTextStyle,si as DirectionalLight3D,Ni as DocumentTooNewError,R as EFFECT_OPTION_KEYS,A as EMPTY_MANIFEST,ne as EMPTY_PATH_DATA,Nr as EMPTY_TEXT_STYLE,dt as EffectChain,ft as Effects,ks as Ellipse,h as Engine,fi as Environment3D,Gs as ExpressionError,Go as Extrude3D,lt as FillChain,xt as Fills,di as Fog3D,ta as Geo,vt as Graphics2D,qt as Graphics3D,vo as Group3D,ri as HemisphereLight3D,ao as Hexagon,is as IDENTITY_QUATERNION,Qo as Instances3D,Ho as Lathe3D,Zo as Line3D,Dr as MAX_SHADER_PROPERTIES,Mr as MAX_SHADER_SOURCE,wt as MINOR_WIDTH_RATIO,Sa as MUTABLE_MATERIAL_KEYS,w as ManifestAssetCatalog,po as MaskGroup,ea as Mat,Vo as Mesh3D,Oo as Model3D,ti as ModelView3D,Ns as NODE_META,xr as NO_PROJECTION_3D,kr as Node,ps as Node2D,Es as Node3D,ws as NodeAudio,H as NodeBlendModes,Xs as NullRenderContext,Lo as NumberNode,no as Octagon,co as OrbitCamera,de as PATH_UNIT_EXTENT,fe as PATH_UNIT_HALF,ro as Path,Ut as PathBuilder,eo as PathShape,io as Pentagon,Wo as Plane3D,xn as Playback,ln as PlaybackController,oi as PointLight3D,Xo as Points3D,Os as Polygon,to as Polygram,Bo as Polyhedron3D,g as PropSlot,No as Provider,li as ROOT_NODE_ID,Ce as RampChain,En as Random,Zs as Rect,d as Registry,ki as RenderBackendError,zt as RenderContext3D,Po as RichText,oo as RightTriangle,qo as Ring3D,go as RotatedBox,Ba as SETTLE_PASSES,bs as SHAPE_ALIGNMENT_KEYS,Ta as STRUCTURAL_MATERIAL_KEYS,Gt as Scene3D,Pn as SeedGenerator,Ao as SeedToken,f as Session,tr as Sound,To as SoundNode,Io as Sphere3D,ii as SpotLight3D,ko as Sprite3D,fo as Star,za as StateEvaluator,_ as SteppedClock,a as StorageAdapter,te as TEXTURE_KEYS,Er as TEXT_SHAPING_KEYS,Pr as TEXT_STYLE_KEYS,ra as Tex,Fo as Text,wo as TextStyleToken,So as ThemeProvider,yo as ThemeToken,y as Ticker,$o as Torus3D,jo as TorusKnot3D,so as Triangle,Jo as Tube3D,he as UNIT_PATH_BOX,Do as Video,Et as VideoAdjustmentChain,St as VideoAdjustments,et as WGSL_CONTRACT,Ma as __resetSchedulerForTests,bt as alignmentOps,us as applyEditorStates,ga as applyMatrix4,mr as applyToPoint,Pi as asProjectDocument,vi as assertValidDocument,Ui as assertValidProjectDocument,nr as audioEffectsOps,Be as audioParamOps,ct as backdropEffects,ys as busPathOf,_s as busPathTo,ir as busStopKey,gr as cameraMatrix,oe as canLerpFill,Ht as canvas3DResourceKey,kt as canvas3DResourceLoader,Qi as caretCount,cn as caretOffsetAt,gn as caretRangeQuads,Fa as centeredBox3,en as childPlanePointAt,Fe as clamp,Le as clamp01,zi as clipDocument,Oe as clipDurationOf,Ua as clipFrameToTime,Ze as clipTimeAtSource,va as clipTimeToFrame,pn as collectBoxes,Xa as collectBoxes3D,Y as colorOps,Br as commandParallel,zr as commandSequence,Ai as commandSpan,la as compose4,Rs as containsClip,$s as containsOps,S as cornerRadiusOps,T as cornerStyleOps,Pa as corners3,Ha as createAssetTimelineProfile,Jr as createContext,Ln as createRef,Ue as curveEase,De as curveSegmentT,be as curveSegments,da as cylinderRadii,st as describeEffect,Bs as distanceToSegment,Fi as documentDuration,Ti as documentFormatVersion,Yr as driveCommand,Ne as easeIn,Te as easeInOut,ve as easeOfSpec,Se as easeOut,ot as effectDescriptors,it as effectSurface,ui as effectiveSpan,yi as effectiveSpanIn,wi as effectiveSpans,er as effectsKey,pt as effectsOps,Fn as enterBudget,ze as equalsParam,os as euler3Ops,ha as evaluateParametric,oa as evaluateRoundedBox,Hs as expressionOps,wr as facesAway,ae as fillOps,Ft as filterSurface,As as findBusById,ms as findNode2D,Or as flowOps,re as forEachTexture3D,gt as foregroundShaderEffects,cs as frameIn,Va as frameSpecAtTime,Ra as frameTime,_n as generateList,Na as geometryBounds3D,J as getBlendModeHash,Zr as getCommandMeta,Ss as getNodeDescriptor,l as getPropSlot,Tr as getPropertyMeta,v as getTypographyPreset,on as handleValueAt,Ot as hasCanvas3DBackend,_t as hasFilter,ur as hasProjection3D,gi as hasTimeline,We as hold,fr as identity,pa as identity4,Dt as insetsOps,Ge as integrateSpeedToClipTime,cr as invert,ca as invert4,ci as isAudioDocument,mt as isBackdropEffect,$r as isCommand,mi as isCompositionDocument,Ct as isDataTexture3D,Me as isEaseCurve,Oi as isFatalRenderIssue,br as isKnownShaderProperty,Mo as isOrbitCamera3D,yt as isPixelFilter,Li as isProjectDocument,dr as isProjective,Ke as isRamp,Nn as isSteppable,pi as isStillDocument,xe as isStrokeMarker,It as isSurfaceTexture3D,ee as isTextureLike,P as isUniformCorners,Qa as isViewport3D,tt as isWgslShader,j as lerpColor,b as lerpCornerScalarStyle,L as lerpCorners,at as lerpEffect,ss as lerpEuler3,ie as lerpFill,At as lerpFilter,Lt as lerpFilterArray,_r as lerpLookAt,E as lerpNumber,qe as lerpParam,N as lerpPerspective,k as lerpUniformRecord,X as lerpUniformValue,D as lerpVector2,es as lerpVector3,Ee as linear,xa as lookAtRotation4,Rt as looksLikeAssetPath,qr as loopCommand,Vr as loopPasses,Wr as loopPhase,Cr as loopRepeats,Ir as loopSpan,Yi as loweredAudioDocument,jr as makeCommand,bi as migrateDocument,Js as migrateNodeProps,Vi as missingNodeOf,pr as multiply,ma as multiply4,zs as nearPolyline,An as niceStep,dn as nodeAt,an as nodeBox,nn as nodeBoxAt,sn as nodeHandlesAt,lr as nodeLocalMatrix,gs as nodePath,yr as nodeProjectedMatrix,xi as nodeSpan,mn as nodeTextLayout,Wi as nodeTypeIsA,ns as normalizeQuaternion,Ur as normalizeShaderPack,Q as normalizeUniforms,ba as now,Aa as orthographic4,Ye as paramKey,Ki as parentIssue,tn as parentPlanePointAt,Ps as parentSpaceOf,wn as parseCSV,Jt as parseCanvas3DResourceKey,V as parseColor,yn as parseData,pe as pathOps,_a as perspective4,hn as pickNode,ka as pickNode3D,Ia as placeTracks,$i as placementIssues,qs as pointInPolygon,js as polygonVertices,Ys as polygramVertices,Hr as prepareNumericCellTween,Gr as prepareNumericTween,xs as primeMotionTree,Za as projectNode3D,fn as projectNode3DAt,ds as quaternionFromEuler,fs as quaternionOps,Ie as ramp,Xt as registerCanvas3DResourceLoader,Qt as registerCanvas3DWarmup,Ci as registryVocabulary,Zi as renderIssueKey,Oa as renderMatrix,Ga as renderSettled,rn as reparentPlacementAt,xo as requireFontFamily,B as resolveAsciiCharset,Xe as resolveAudioEffects,fa as resolveBevel3D,Uo as resolveCameraPlacement,Tt as resolveChainAdjustments,ht as resolveChainEffects,ut as resolveChainFill,F as resolveCorners,C as resolveEffectAxis,W as resolveEffectColor,se as resolveFill,$t as resolveFill3D,Yt as resolveMaterialShorthand3D,q as resolveMotionBlurAlignment,vs as resolvePivotPosition,un as resolveProjectDocument,Re as resolveRamp,nt as resolveShaderProperties,me as resolveShadow,na as resolveShadowOptions3D,Bt as resolveShadows3D,Us as resolveShapeAlignment,Ts as resolveShapePivot,_e as resolveStroke,ge as resolveStrokeAlign,ue as resolveStrokeCap,we as resolveStrokeEnd,ye as resolveStrokeJoin,Vt as resolveSurfaceSource,Wt as resolveTexture3D,ts as resolveVector3,Mt as resolveVideoTimestamp,ya as rotationOf4,I as sameEffectAxis,K as sameEffectColor,$e as sampleRamp,ls as sampleTree,sa as segmentsOf,U as setTheme,Rr as settles,Kr as settling,rt as shaderContractOf,ia as shadowCasts,ce as shadowOps,aa as shadowReceives,Ri as siblingIssue,Fr as size2DOps,Lr as sizeInputOps,as as slerpQuaternion,ke as sourceTimeAtClip,He as sourceTimeAtClipElapsed,Ar as space3dOps,$a as spanFrames,Ka as spansCovering,Ve as specOfEase,je as staticValue,Ms as stripShapeAlignmentKeys,Ae as strokeOps,Fs as structuralPathOf,Sr as textOps,Kt as texture3DSource,vr as toCommand,Hi as toPathString,Xi as toRenderIssue,Wa as totalFramesOf,Ca as trackFrameCount,Ea as transformBox3,ua as transformMatrix4,sr as transitionGainAt,or as transitionKey,rr as transitionSpans,hr as translation,wa as translation4,O as uniformRecordsEqual,Z as uniformValuesEqual,La as unionBox3,_i as untimed,Di as validateDocument,Mi as validateProjectDocument,Ds as validateShapeAlignmentProps,M as vector2Ops,rs as vector3Ops,Ii as vocabularyBreaks,Zt as warmCanvas3D,$ as withEffectOptions,Cs as withEllipseDescriptor,Ks as withLineDescriptor,Ji as withPathDescriptor,qi as withPlayedSounds,Is as withPolygonDescriptor,Ws as withPolygramDescriptor,Vs as withRectDescriptor,Gi as withRichTextDescriptor,uo as withTextDescriptor,Da as yieldToScheduler};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@motionscript/core",
3
- "version": "0.1.1-alpha.3",
3
+ "version": "0.1.1-alpha.5",
4
4
  "exports": {
5
5
  ".": "dist/browser/index.js",
6
6
  "./experimental": "dist/browser/experimental.js",
@@ -1,2 +1,2 @@
1
- import{$ as Fo,$a as vt,A as oo,Ac as Ht,B as to,Ba as at,C as ro,Ca as it,D as no,Da as pt,E as so,Ea as ct,F as ao,G as po,H as co,Ha as lt,I as lo,Ia as mt,J as xo,Ja as ft,K as ho,Ka as ut,Kc as Kt,L as Do,La as dt,Lc as Qt,M as go,Ma as xt,Mc as Ut,N as Po,Na as ht,Nc as Wt,O as Oo,Oc as Jt,P as To,Pa as Dt,Pc as Xt,Q as yo,Qa as gt,Qc as Yt,R as Co,Ra as Pt,T as vo,U as Ro,Ua as Ot,V as wo,Va as St,W as Eo,X as Mo,Y as No,Ya as Tt,Z as Io,Za as yt,_ as Vo,_a as Ct,_b as kt,aa as ko,ab as bt,ba as Lo,ca as Bo,d as xe,da as jo,ea as zo,fa as Go,ga as _o,ha as qo,hb as At,ia as Ho,j as Pe,ja as Ko,ka as Qo,la as Uo,m as Oe,ma as Wo,oa as Jo,ob as Rt,pa as Xo,pb as wt,qa as Yo,qb as Et,qc as Lt,r as je,ra as Zo,rb as Mt,rc as Bt,s as Ue,sa as $o,sb as Nt,sc as jt,t as We,ta as et,tb as It,tc as zt,u as Je,ua as ot,ub as Vt,uc as Gt,v as Xe,va as tt,vc as _t,w as Ye,wa as rt,x as Ze,xa as st,y as $e,yb as Ft,z as eo,zc as qt}from"./chunks/chunk-TL432UO5.js";import{$ as q,$a as le,$c as Be,Ac as Re,Bd as ze,C as V,Cd as Ge,D as F,Ec as we,Ed as _e,Ee as uo,Fa as $,Fc as Ee,Fe as So,Gc as Me,Ge as bo,H as k,I as L,Ic as Ne,J as B,Ka as ee,Kd as qe,La as te,Lc as Ie,Ld as u,Ma as re,Mc as Ve,Nc as Fe,Ob as he,Q as j,Qb as De,Re as Ao,Sd as He,Ta as ne,Tc as ke,Td as Ke,Ua as se,Ub as ge,Va as ae,Vd as g,We as nt,Y as z,Ya as ie,Yd as S,Z as G,Za as pe,_,_a as ce,_c as Le,a as A,ba as H,ca as K,d as w,e as E,ee as Qe,fa as Q,ga as U,ha as W,ib as me,ie as io,jb as fe,kb as ue,mc as Se,n as I,na as D,nc as Te,pc as ye,qc as Ce,ra as J,rc as ve,sa as X,ta as Y,te as mo,ua as Z,uc as be,vb as de,vc as Ae,ye as fo}from"./chunks/chunk-BPA7KSK2.js";import"./chunks/chunk-GEJEQQER.js";import{a as b,b as R,d as M,h as N,m as oe}from"./chunks/chunk-5TDMGUXQ.js";var v={};b(v,{BAR:()=>y,STROKE_UNIT:()=>d,bar:()=>P,commands:()=>$t,dashes:()=>C,lines:()=>sr,material:()=>er,state:()=>Zt});var Zt={fill:u.fill,stroke:u.stroke},$t={fillTo:g.fillTo,strokeTo:g.strokeTo},d=.001;function T(e){if(e===void 0||e.type!=="solid"||e.blend!==void 0)return null;let t=e.color;return{color:t,alpha:(t[3]??1)*(e.opacity??1)}}function er(e,t={}){let{type:o="basic",opacity:r,...n}=t,s=r??1;if(e.length===0)return{type:o,...n,visible:!1};let a=e.length===1?T(e[0]):null;if(a!==null){let[c,l,p]=a.color;return{type:o,color:[c,l,p,1],opacity:a.alpha*s,...n}}let i=D(e);return{type:o,...i.color!==void 0?{color:i.color}:{},...i.map!==void 0?{map:i.map}:{},...r!==void 0?{opacity:r}:{},...n}}var y={type:"box",width:1,height:1,depth:1};function or(e,t,o){if(e<=-.9999)return{x:0,y:1,z:0,w:0};let r=-o,n=t,s=1+e,a=Math.hypot(r,n,s);return{x:0,y:r/a,z:n/a,w:s/a}}function P(e,t,o,r=0){let n=t[0]-e[0],s=t[1]-e[1],a=t[2]-e[2],i=Math.hypot(n,s,a)||1e-9;return{position:[(e[0]+t[0])/2,(e[1]+t[1])/2,(e[2]+t[2])/2],quaternion:or(n/i,s/i,a/i),scale:[i+r*2,o,o]}}function tr(e){if(e===void 0||e.length===0)return null;let t=e.map(r=>Math.max(0,r)*d),o=t.length%2===1?[...t,...t]:t;return o.reduce((r,n)=>r+n,0)>1e-9?o:null}function C(e,t,o=0){let r=t.reduce((c,l)=>c+l,0),n=[];if(r<=0||e<=0)return n;let s=-((o%r+r)%r),a=0,i=e-1e-9;for(;s<i;){let c=t[a%t.length];if(a%2===0&&c>0){let l=Math.max(0,s),p=Math.min(e,s+c);p-l>1e-9&&n.push([l,p])}s+=c,a++}return n}function rr(e,t,o){let r=e.weight*d,n=e.cap==="square"?r/2:0,s=tr(e.dash),a=e.dashOffset*d,i=[];for(let[c,l]of t){let p=o?[c[0]+o[0],c[1]+o[1],c[2]+o[2]]:c,m=o?[l[0]+o[0],l[1]+o[1],l[2]+o[2]]:l,x=Math.hypot(m[0]-p[0],m[1]-p[1],m[2]-p[2]);if(x<=1e-9)continue;if(s===null){i.push(P(p,m,r,n));continue}let O=h=>{let f=h/x;return[p[0]+(m[0]-p[0])*f,p[1]+(m[1]-p[1])*f,p[2]+(m[2]-p[2])*f]};for(let[h,f]of C(x,s,a))i.push(P(O(h),O(f),r,n))}return i}function nr(e,t){let o=e.fill.map(T).find(i=>i!==null)??null;if(o===null||o.alpha<=0)return null;let[r,n,s]=o.color,a=o.alpha<1||t;return{type:"basic",color:[r,n,s,1],opacity:o.alpha,...a?{transparent:!0,depthWrite:!1}:{},...t?{depthTest:!1}:{}}}function sr(e,t,o,r={}){let n=r.through??!1;for(let s of t){if(!(s.weight>0))continue;let a=nr(s,n);if(a===null)continue;let i=rr(s,o,r.lift);i.length!==0&&e.instances(y,a,i,r.transform?{transform:r.transform}:void 0)}return e}export{z as AdjustmentChain,_ as Adjustments,io as Aim,Jo as AmbientLight3D,et as AreaLight3D,yo as AudioBus,de as AudioEffects,so as BooleanGroup,Eo as Box3D,po as Camera,ot as Camera3D,je as Canvas2D,st as Canvas3D,jo as Capsule3D,Lo as Circle3D,ke as Clip,Vo as Cone3D,Ae as ContextMap,Io as Cylinder3D,xt as DOCUMENT_FORMAT_VERSION,go as DefaultTextStyle,Yo as DirectionalLight3D,ht as DocumentTooNewError,L as EffectChain,B as Effects,We as Ellipse,rt as Environment3D,ze as ExpressionError,Go as Extrude3D,j as Fills,He as Flow,tt as Fog3D,Rt as Geo,U as Graphics2D,J as Graphics3D,Ro as Group3D,Xo as HemisphereLight3D,to as Hexagon,Ho as Instances3D,_o as Lathe3D,Qo as Line3D,ao as MaskGroup,wt as Mat,Ao as Material,wo as Mesh3D,Wo as Model3D,ho as NumberNode,ro as Octagon,co as OrbitCamera,S as Paint,v as Paint3D,Ze as Path,Q as PathBuilder,Ye as PathShape,oo as Pentagon,No as Plane3D,Zo as PointLight3D,Ko as Points3D,Je as Polygon,Xe as Polygram,zo as Polyhedron3D,Po as Provider,it as ROOT_NODE_ID,Yt as Random,Ue as Rect,Tt as Registry,X as RenderContext3D,Do as RichText,eo as RightTriangle,Bo as Ring3D,lo as RotatedBox,Z as Scene3D,Xt as SeedGenerator,Qe as Shapes,xe as Sound,To as SoundNode,Mo as Sphere3D,$o as SpotLight3D,Uo as Sprite3D,no as Star,Et as Tex,xo as Text,mo as TextLayout,Oo as ThemeProvider,Fo as Torus3D,ko as TorusKnot3D,$e as Triangle,qo as Tube3D,uo as Typeface,u as Types,Co as Video,G as VideoAdjustmentChain,q as VideoAdjustments,nt as View3D,H as alignmentOps,dt as asProjectDocument,Ot as assertValidDocument,Bt as childPlanePointAt,ae as clamp,Ht as collectBoxes,I as colorOps,ve as commandParallel,Ce as commandSequence,mt as commandSpan,Ke as commandsFor,qe as component2d,bo as component3d,So as componentAudio,w as cornerRadiusOps,E as cornerStyleOps,be as createContext,Jt as createRef,V as describeEffect,ft as documentDuration,Dt as documentFormatVersion,pe as easeIn,le as easeInOut,ce as easeOut,F as effectDescriptors,ct as effectiveSpan,Ft as evaluateParametric,Nt as evaluateRoundedBox,Ge as expressionOps,ee as fillOps,Le as findNode2D,we as flowOps,Be as frameIn,Wt as generateList,Re as getCommandMeta,Gt as handleValueAt,at as hasTimeline,fe as hold,K as insetsOps,Se as isCommand,Pe as isKnownShaderProperty,ut as isProjectDocument,ue as isRamp,Ne as lerpEuler3,R as lerpNumber,M as lerpVector2,Me as lerpVector3,ie as linear,ye as loopCommand,Te as makeCommand,gt as migrateDocument,_e as migrateNodeProps,St as missingNodeOf,_t as nodeBox,zt as nodeHandlesAt,pt as nodeSpan,yt as nodeTypeIsA,Ve as normalizeQuaternion,Oe as normalizeShaderPack,Ct as parentIssue,Lt as parentPlanePointAt,Qt as parseCSV,N as parseColor,Ut as parseData,oe as pathOps,qt as pickNode,kt as placeTracks,bt as placementIssues,fo as provides,Fe as quaternionFromEuler,me as ramp,jt as reparentPlacementAt,vo as resolveCameraPlacement,A as resolveCorners,$ as resolveFill,D as resolveFill3D,Kt as resolveProjectDocument,k as resolveShaderProperties,te as resolveShadow,Y as resolveShadows3D,ne as resolveStroke,W as resolveSurfaceSource,Ee as resolveVector3,Mt as segmentsOf,It as shadowCasts,re as shadowOps,Vt as shadowReceives,vt as siblingIssue,De as sizeInputOps,Ie as slerpQuaternion,he as space3dOps,se as strokeOps,ge as textOps,At as toPathString,lt as untimed,Pt as validateDocument};
1
+ import{$ as Fo,$a as vt,A as oo,Ac as Ht,B as to,Ba as at,C as ro,Ca as it,D as no,Da as pt,E as so,Ea as ct,F as ao,G as po,H as co,Ha as lt,I as lo,Ia as mt,J as xo,Ja as ft,K as ho,Ka as ut,Kc as Kt,L as Do,La as dt,Lc as Qt,M as go,Ma as xt,Mc as Ut,N as Po,Na as ht,Nc as Wt,O as Oo,Oc as Jt,P as To,Pa as Dt,Pc as Xt,Q as yo,Qa as gt,Qc as Yt,R as Co,Ra as Pt,T as vo,U as Ro,Ua as Ot,V as wo,Va as St,W as Eo,X as Mo,Y as No,Ya as Tt,Z as Io,Za as yt,_ as Vo,_a as Ct,_b as kt,aa as ko,ab as bt,ba as Lo,ca as Bo,d as xe,da as jo,ea as zo,fa as Go,ga as _o,ha as qo,hb as At,ia as Ho,j as Pe,ja as Ko,ka as Qo,la as Uo,m as Oe,ma as Wo,oa as Jo,ob as Rt,pa as Xo,pb as wt,qa as Yo,qb as Et,qc as Lt,r as je,ra as Zo,rb as Mt,rc as Bt,s as Ue,sa as $o,sb as Nt,sc as jt,t as We,ta as et,tb as It,tc as zt,u as Je,ua as ot,ub as Vt,uc as Gt,v as Xe,va as tt,vc as _t,w as Ye,wa as rt,x as Ze,xa as st,y as $e,yb as Ft,z as eo,zc as qt}from"./chunks/chunk-FPYU47XX.js";import{$ as q,$a as le,$c as Be,Ac as Re,Bd as ze,C as V,Cd as Ge,D as F,Ec as we,Ed as _e,Ee as uo,Fa as $,Fc as Ee,Fe as So,Gc as Me,Ge as bo,H as k,I as L,Ic as Ne,J as B,Ka as ee,Kd as qe,La as te,Lc as Ie,Ld as u,Ma as re,Mc as Ve,Nc as Fe,Ob as he,Q as j,Qb as De,Re as Ao,Sd as He,Ta as ne,Tc as ke,Td as Ke,Ua as se,Ub as ge,Va as ae,Vd as g,We as nt,Y as z,Ya as ie,Yd as S,Z as G,Za as pe,_,_a as ce,_c as Le,a as A,ba as H,ca as K,d as w,e as E,ee as Qe,fa as Q,ga as U,ha as W,ib as me,ie as io,jb as fe,kb as ue,mc as Se,n as I,na as D,nc as Te,pc as ye,qc as Ce,ra as J,rc as ve,sa as X,ta as Y,te as mo,ua as Z,uc as be,vb as de,vc as Ae,ye as fo}from"./chunks/chunk-XCGYJHZR.js";import"./chunks/chunk-GEJEQQER.js";import{a as b,b as R,d as M,h as N,m as oe}from"./chunks/chunk-5TDMGUXQ.js";var v={};b(v,{BAR:()=>y,STROKE_UNIT:()=>d,bar:()=>P,commands:()=>$t,dashes:()=>C,lines:()=>sr,material:()=>er,state:()=>Zt});var Zt={fill:u.fill,stroke:u.stroke},$t={fillTo:g.fillTo,strokeTo:g.strokeTo},d=.001;function T(e){if(e===void 0||e.type!=="solid"||e.blend!==void 0)return null;let t=e.color;return{color:t,alpha:(t[3]??1)*(e.opacity??1)}}function er(e,t={}){let{type:o="basic",opacity:r,...n}=t,s=r??1;if(e.length===0)return{type:o,...n,visible:!1};let a=e.length===1?T(e[0]):null;if(a!==null){let[c,l,p]=a.color;return{type:o,color:[c,l,p,1],opacity:a.alpha*s,...n}}let i=D(e);return{type:o,...i.color!==void 0?{color:i.color}:{},...i.map!==void 0?{map:i.map}:{},...r!==void 0?{opacity:r}:{},...n}}var y={type:"box",width:1,height:1,depth:1};function or(e,t,o){if(e<=-.9999)return{x:0,y:1,z:0,w:0};let r=-o,n=t,s=1+e,a=Math.hypot(r,n,s);return{x:0,y:r/a,z:n/a,w:s/a}}function P(e,t,o,r=0){let n=t[0]-e[0],s=t[1]-e[1],a=t[2]-e[2],i=Math.hypot(n,s,a)||1e-9;return{position:[(e[0]+t[0])/2,(e[1]+t[1])/2,(e[2]+t[2])/2],quaternion:or(n/i,s/i,a/i),scale:[i+r*2,o,o]}}function tr(e){if(e===void 0||e.length===0)return null;let t=e.map(r=>Math.max(0,r)*d),o=t.length%2===1?[...t,...t]:t;return o.reduce((r,n)=>r+n,0)>1e-9?o:null}function C(e,t,o=0){let r=t.reduce((c,l)=>c+l,0),n=[];if(r<=0||e<=0)return n;let s=-((o%r+r)%r),a=0,i=e-1e-9;for(;s<i;){let c=t[a%t.length];if(a%2===0&&c>0){let l=Math.max(0,s),p=Math.min(e,s+c);p-l>1e-9&&n.push([l,p])}s+=c,a++}return n}function rr(e,t,o){let r=e.weight*d,n=e.cap==="square"?r/2:0,s=tr(e.dash),a=e.dashOffset*d,i=[];for(let[c,l]of t){let p=o?[c[0]+o[0],c[1]+o[1],c[2]+o[2]]:c,m=o?[l[0]+o[0],l[1]+o[1],l[2]+o[2]]:l,x=Math.hypot(m[0]-p[0],m[1]-p[1],m[2]-p[2]);if(x<=1e-9)continue;if(s===null){i.push(P(p,m,r,n));continue}let O=h=>{let f=h/x;return[p[0]+(m[0]-p[0])*f,p[1]+(m[1]-p[1])*f,p[2]+(m[2]-p[2])*f]};for(let[h,f]of C(x,s,a))i.push(P(O(h),O(f),r,n))}return i}function nr(e,t){let o=e.fill.map(T).find(i=>i!==null)??null;if(o===null||o.alpha<=0)return null;let[r,n,s]=o.color,a=o.alpha<1||t;return{type:"basic",color:[r,n,s,1],opacity:o.alpha,...a?{transparent:!0,depthWrite:!1}:{},...t?{depthTest:!1}:{}}}function sr(e,t,o,r={}){let n=r.through??!1;for(let s of t){if(!(s.weight>0))continue;let a=nr(s,n);if(a===null)continue;let i=rr(s,o,r.lift);i.length!==0&&e.instances(y,a,i,r.transform?{transform:r.transform}:void 0)}return e}export{z as AdjustmentChain,_ as Adjustments,io as Aim,Jo as AmbientLight3D,et as AreaLight3D,yo as AudioBus,de as AudioEffects,so as BooleanGroup,Eo as Box3D,po as Camera,ot as Camera3D,je as Canvas2D,st as Canvas3D,jo as Capsule3D,Lo as Circle3D,ke as Clip,Vo as Cone3D,Ae as ContextMap,Io as Cylinder3D,xt as DOCUMENT_FORMAT_VERSION,go as DefaultTextStyle,Yo as DirectionalLight3D,ht as DocumentTooNewError,L as EffectChain,B as Effects,We as Ellipse,rt as Environment3D,ze as ExpressionError,Go as Extrude3D,j as Fills,He as Flow,tt as Fog3D,Rt as Geo,U as Graphics2D,J as Graphics3D,Ro as Group3D,Xo as HemisphereLight3D,to as Hexagon,Ho as Instances3D,_o as Lathe3D,Qo as Line3D,ao as MaskGroup,wt as Mat,Ao as Material,wo as Mesh3D,Wo as Model3D,ho as NumberNode,ro as Octagon,co as OrbitCamera,S as Paint,v as Paint3D,Ze as Path,Q as PathBuilder,Ye as PathShape,oo as Pentagon,No as Plane3D,Zo as PointLight3D,Ko as Points3D,Je as Polygon,Xe as Polygram,zo as Polyhedron3D,Po as Provider,it as ROOT_NODE_ID,Yt as Random,Ue as Rect,Tt as Registry,X as RenderContext3D,Do as RichText,eo as RightTriangle,Bo as Ring3D,lo as RotatedBox,Z as Scene3D,Xt as SeedGenerator,Qe as Shapes,xe as Sound,To as SoundNode,Mo as Sphere3D,$o as SpotLight3D,Uo as Sprite3D,no as Star,Et as Tex,xo as Text,mo as TextLayout,Oo as ThemeProvider,Fo as Torus3D,ko as TorusKnot3D,$e as Triangle,qo as Tube3D,uo as Typeface,u as Types,Co as Video,G as VideoAdjustmentChain,q as VideoAdjustments,nt as View3D,H as alignmentOps,dt as asProjectDocument,Ot as assertValidDocument,Bt as childPlanePointAt,ae as clamp,Ht as collectBoxes,I as colorOps,ve as commandParallel,Ce as commandSequence,mt as commandSpan,Ke as commandsFor,qe as component2d,bo as component3d,So as componentAudio,w as cornerRadiusOps,E as cornerStyleOps,be as createContext,Jt as createRef,V as describeEffect,ft as documentDuration,Dt as documentFormatVersion,pe as easeIn,le as easeInOut,ce as easeOut,F as effectDescriptors,ct as effectiveSpan,Ft as evaluateParametric,Nt as evaluateRoundedBox,Ge as expressionOps,ee as fillOps,Le as findNode2D,we as flowOps,Be as frameIn,Wt as generateList,Re as getCommandMeta,Gt as handleValueAt,at as hasTimeline,fe as hold,K as insetsOps,Se as isCommand,Pe as isKnownShaderProperty,ut as isProjectDocument,ue as isRamp,Ne as lerpEuler3,R as lerpNumber,M as lerpVector2,Me as lerpVector3,ie as linear,ye as loopCommand,Te as makeCommand,gt as migrateDocument,_e as migrateNodeProps,St as missingNodeOf,_t as nodeBox,zt as nodeHandlesAt,pt as nodeSpan,yt as nodeTypeIsA,Ve as normalizeQuaternion,Oe as normalizeShaderPack,Ct as parentIssue,Lt as parentPlanePointAt,Qt as parseCSV,N as parseColor,Ut as parseData,oe as pathOps,qt as pickNode,kt as placeTracks,bt as placementIssues,fo as provides,Fe as quaternionFromEuler,me as ramp,jt as reparentPlacementAt,vo as resolveCameraPlacement,A as resolveCorners,$ as resolveFill,D as resolveFill3D,Kt as resolveProjectDocument,k as resolveShaderProperties,te as resolveShadow,Y as resolveShadows3D,ne as resolveStroke,W as resolveSurfaceSource,Ee as resolveVector3,Mt as segmentsOf,It as shadowCasts,re as shadowOps,Vt as shadowReceives,vt as siblingIssue,De as sizeInputOps,Ie as slerpQuaternion,he as space3dOps,se as strokeOps,ge as textOps,At as toPathString,lt as untimed,Pt as validateDocument};
2
2
  //# sourceMappingURL=sdk.js.map
@@ -20,7 +20,7 @@ export interface TextureOptions3D {
20
20
  center?: Vector2 | readonly [number, number];
21
21
  magFilter?: TextureFilter3D;
22
22
  minFilter?: TextureFilter3D;
23
- /** Sharpness at grazing angles. Clamped to the GPU's maximum. */
23
+ /** Sharpness at grazing angles: 1 is off, and anything above is rounded up to 4, 8 or 16 (the most WebGPU allows). Needs linear filters. */
24
24
  anisotropy?: number;
25
25
  flipY?: boolean;
26
26
  colorSpace?: TextureColorSpace3D;
@@ -1 +1 @@
1
- {"version":3,"file":"texture.d.ts","sourceRoot":"","sources":["../../src/render3d/texture.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AAE3D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,8B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MAAM,UAAU,kBAAkB,CAAC,KAAa;IAC5C,OAAO,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC;WACrB,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC;WACrB,0DAA0D,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAClF,CAAC","sourcesContent":["import type { Vector2 } from \"@/attributes/layout/vector2\";\n// Type-only, like `Color`: `render3d` is pure data and never reaches into the render or node layers at runtime (see SurfaceSource3D).\nimport type { Graphics2D } from \"@/render/graphics2d\";\nimport type { Node } from \"@/components/trees/node/node\";\nimport type { Node2D } from \"@/components/trees/2d/node2d\";\n\n/** How sampling behaves outside the 0–1 UV range. */\nexport type TextureWrap3D = \"clamp\" | \"repeat\" | \"mirror\";\n\n/** How texels are blended when the texture is scaled. */\nexport type TextureFilter3D = \"nearest\" | \"linear\";\n\n/** Colour space of the texture's data: `\"srgb\"` for colours an eye would see (albedo/`map`, `emissiveMap`), linearized before lighting; `\"linear\"` for data maps (`normalMap`, `roughnessMap`, `metalnessMap`, `aoMap`, `displacementMap`), which linearizing would corrupt. Each slot defaults correctly. */\nexport type TextureColorSpace3D = \"srgb\" | \"linear\";\n\n/** Sampler state shared by every texture source. */\nexport interface TextureOptions3D {\n wrapS?: TextureWrap3D;\n wrapT?: TextureWrap3D;\n /** UV scale. `[2, 2]` tiles twice on each axis (needs a `repeat` wrap). */\n repeat?: Vector2 | readonly [number, number];\n offset?: Vector2 | readonly [number, number];\n /** UV rotation in **degrees**, about {@link center}. */\n rotation?: number;\n center?: Vector2 | readonly [number, number];\n magFilter?: TextureFilter3D;\n minFilter?: TextureFilter3D;\n /** Sharpness at grazing angles. Clamped to the GPU's maximum. */\n anisotropy?: number;\n flipY?: boolean;\n colorSpace?: TextureColorSpace3D;\n}\n\n/** A texture from the project's asset manifest. `src` is found by the asset-tracking pass and requested through the ordinary image pipeline (as a 2D image fill), so pixels are resident before the frame draws. */\nexport interface ImageTexture3D extends TextureOptions3D {\n src: string;\n}\n\n/** Raw RGBA8888 bytes: the escape hatch for procedurally generated pixels (ramps, noise, LUTs, data as colour). */\nexport interface DataTexture3D extends TextureOptions3D {\n data: ArrayLike<number>;\n width: number;\n height: number;\n /** Bump to force a re-upload after mutating `data` in place (invisible to identity comparison). See {@link BufferGeometry3D.revision}. */\n revision?: number;\n}\n\n/**\n * A texture whose pixels are Motion Script's own 2D output, rasterized offscreen: puts a chart, readout or laid-out UI\n * onto 3D geometry. `source` is a value, a built {@link Graphics2D} or a `Node2D` subtree, supplied directly with no\n * indirection or tree placement.\n *\n * g3.plane({ map: Tex.surface(scopeGraphics, 1024, 640) })\n *\n * A `Node2D` source is adopted for binding by whatever paints the scene (asset catalog, inherited context, clock, so a\n * webfont shapes and an `<Image>` loads); it is never laid out or painted by the scene tree, only measured against\n * `width` x `height` and drawn into the buffer.\n *\n * **Hoist the source.** Building it inside the scene builder allocates a new subtree every frame (re-binding,\n * re-laying-out, defeating the texture cache, leaking). A hoisted source is a stable identity, so the renderer keys\n * the GPU texture off the source object (a `WeakMap`) and a source that goes out of scope becomes collectable.\n */\nexport interface SurfaceTexture3D extends TextureOptions3D {\n /** A built `Graphics2D`, or a `Node2D` subtree (typed structurally, see {@link SurfaceSource3D}). */\n source: SurfaceSource3D;\n /** Buffer width in pixels. This *is* the texture's resolution. */\n width: number;\n height: number;\n /**\n * Declares the source's pixels unchanging, so the buffer is rasterized once and reused. Set by `resolveFill3D` for a\n * fill chain; an author's own source is live by default, so an animated `Graphics2D` or prop-driven subtree works\n * with no bookkeeping. Needs {@link identity} to be cacheable.\n *\n * @internal\n */\n static?: boolean;\n /**\n * Cache identity for a synthesized source. An author's source is identified by the object itself (right for a hoisted\n * one); a source built for a fill is fresh every frame, so the value it was derived from supplies one.\n *\n * @internal\n */\n identity?: string;\n /** Ceiling on the buffer's device-pixel ratio, default 1 (the buffer is exactly `width` x `height`). A surface is sampled at whatever size the geometry occupies, so `width`/`height` is the real control; raise this only for a surface viewed close up that reads soft. */\n maxPixelRatio?: number;\n}\n\n/** What a {@link SurfaceTexture3D} paints from: a built {@link Graphics2D} or a {@link Node2D} subtree. Both imports are type-only: `render3d` is pure data, and a value import of `Node2D` would close a real cycle. Narrow with {@link resolveSurfaceSource}. */\nexport type SurfaceSource3D = Graphics2D | Node;\n\n// Declared against the dimension-agnostic base because that is what a built node is typed as, so\n// `Tex.surface(new Rect({ ... }), ...)` type-checks without a cast. It must be 2D in fact; `resolveSurfaceSource`\n// narrows, and a `Node3D` fails at render time.\n\n/** A {@link SurfaceSource3D} narrowed to the arm its renderer should take. */\nexport type ResolvedSurfaceSource =\n | { kind: \"graphics\"; graphics: Graphics2D }\n | { kind: \"node\"; node: Node2D };\n\n/** Narrows a surface source to the arm that draws it: a `Graphics2D` is replayed into a render context, a `Node2D` is laid out against the buffer and rendered. Structural, not `instanceof` (value imports would close the cycle): `Graphics2D` exposes `ops()` and a `Node2D` doesn't. */\nexport function resolveSurfaceSource(source: SurfaceSource3D): ResolvedSurfaceSource {\n return typeof (source as Graphics2D).ops === \"function\"\n ? { kind: \"graphics\", graphics: source as Graphics2D }\n : { kind: \"node\", node: source as Node2D };\n}\n\n/** A texture reference; a bare string is sugar for `{ src }` (`map: \"/wood.png\"`). */\nexport type Texture3D = string | ImageTexture3D | DataTexture3D | SurfaceTexture3D;\n\nexport function isDataTexture3D(texture: Texture3D): texture is DataTexture3D {\n return typeof texture !== \"string\" && \"data\" in texture;\n}\n\nexport function isSurfaceTexture3D(texture: Texture3D): texture is SurfaceTexture3D {\n return typeof texture !== \"string\" && \"source\" in texture;\n}\n\nexport function resolveTexture3D(texture: Texture3D): ImageTexture3D | DataTexture3D | SurfaceTexture3D {\n return typeof texture === \"string\" ? { src: texture } : texture;\n}\n\n/** The asset `src` a texture reads from, or `null` for a data or surface texture; the asset-tracking pass uses it, and `null` means \"nothing to request\". */\nexport function texture3DSource(texture: Texture3D): string | null {\n if (typeof texture === \"string\") return texture;\n if (isDataTexture3D(texture) || isSurfaceTexture3D(texture)) return null;\n return texture.src;\n}\n\n/** True for a string that names an asset rather than a colour: a leading `/` or `.` is a path, otherwise the extension decides. A bare name like `\"wood\"` is a colour, as the manifest couldn't resolve it either. */\nexport function looksLikeAssetPath(value: string): boolean {\n return value.startsWith(\"/\")\n || value.startsWith(\".\")\n || /\\.(png|jpe?g|webp|avif|svg|ktx2?|hdr|exr|mp4|webm|mov)$/i.test(value);\n}\n"]}
1
+ {"version":3,"file":"texture.js","sourceRoot":"","sources":["../../src/render3d/texture.ts"],"names":[],"mappings":"AAmGA,4RAA4R;AAC5R,MAAM,UAAU,oBAAoB,CAAC,MAAuB;IACxD,OAAO,OAAQ,MAAqB,CAAC,GAAG,KAAK,UAAU;QACnD,CAAC,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAoB,EAAE;QACtD,CAAC,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAgB,EAAE,CAAC;AACnD,CAAC;AAKD,MAAM,UAAU,eAAe,CAAC,OAAkB;IAC9C,OAAO,OAAO,OAAO,KAAK,QAAQ,IAAI,MAAM,IAAI,OAAO,CAAC;AAC5D,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,OAAkB;IACjD,OAAO,OAAO,OAAO,KAAK,QAAQ,IAAI,QAAQ,IAAI,OAAO,CAAC;AAC9D,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,OAAkB;IAC/C,OAAO,OAAO,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC;AACpE,CAAC;AAED,6JAA6J;AAC7J,MAAM,UAAU,eAAe,CAAC,OAAkB;IAC9C,IAAI,OAAO,OAAO,KAAK,QAAQ;QAAE,OAAO,OAAO,CAAC;IAChD,IAAI,eAAe,CAAC,OAAO,CAAC,IAAI,kBAAkB,CAAC,OAAO,CAAC;QAAE,OAAO,IAAI,CAAC;IACzE,OAAO,OAAO,CAAC,GAAG,CAAC;AACvB,CAAC;AAED,sNAAsN;AACtN,MAAM,UAAU,kBAAkB,CAAC,KAAa;IAC5C,OAAO,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC;WACrB,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC;WACrB,0DAA0D,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAClF,CAAC","sourcesContent":["import type { Vector2 } from \"@/attributes/layout/vector2\";\n// Type-only, like `Color`: `render3d` is pure data and never reaches into the render or node layers at runtime (see SurfaceSource3D).\nimport type { Graphics2D } from \"@/render/graphics2d\";\nimport type { Node } from \"@/components/trees/node/node\";\nimport type { Node2D } from \"@/components/trees/2d/node2d\";\n\n/** How sampling behaves outside the 0–1 UV range. */\nexport type TextureWrap3D = \"clamp\" | \"repeat\" | \"mirror\";\n\n/** How texels are blended when the texture is scaled. */\nexport type TextureFilter3D = \"nearest\" | \"linear\";\n\n/** Colour space of the texture's data: `\"srgb\"` for colours an eye would see (albedo/`map`, `emissiveMap`), linearized before lighting; `\"linear\"` for data maps (`normalMap`, `roughnessMap`, `metalnessMap`, `aoMap`, `displacementMap`), which linearizing would corrupt. Each slot defaults correctly. */\nexport type TextureColorSpace3D = \"srgb\" | \"linear\";\n\n/** Sampler state shared by every texture source. */\nexport interface TextureOptions3D {\n wrapS?: TextureWrap3D;\n wrapT?: TextureWrap3D;\n /** UV scale. `[2, 2]` tiles twice on each axis (needs a `repeat` wrap). */\n repeat?: Vector2 | readonly [number, number];\n offset?: Vector2 | readonly [number, number];\n /** UV rotation in **degrees**, about {@link center}. */\n rotation?: number;\n center?: Vector2 | readonly [number, number];\n magFilter?: TextureFilter3D;\n minFilter?: TextureFilter3D;\n /** Sharpness at grazing angles: 1 is off, and anything above is rounded up to 4, 8 or 16 (the most WebGPU allows). Needs linear filters. */\n anisotropy?: number;\n flipY?: boolean;\n colorSpace?: TextureColorSpace3D;\n}\n\n/** A texture from the project's asset manifest. `src` is found by the asset-tracking pass and requested through the ordinary image pipeline (as a 2D image fill), so pixels are resident before the frame draws. */\nexport interface ImageTexture3D extends TextureOptions3D {\n src: string;\n}\n\n/** Raw RGBA8888 bytes: the escape hatch for procedurally generated pixels (ramps, noise, LUTs, data as colour). */\nexport interface DataTexture3D extends TextureOptions3D {\n data: ArrayLike<number>;\n width: number;\n height: number;\n /** Bump to force a re-upload after mutating `data` in place (invisible to identity comparison). See {@link BufferGeometry3D.revision}. */\n revision?: number;\n}\n\n/**\n * A texture whose pixels are Motion Script's own 2D output, rasterized offscreen: puts a chart, readout or laid-out UI\n * onto 3D geometry. `source` is a value, a built {@link Graphics2D} or a `Node2D` subtree, supplied directly with no\n * indirection or tree placement.\n *\n * g3.plane({ map: Tex.surface(scopeGraphics, 1024, 640) })\n *\n * A `Node2D` source is adopted for binding by whatever paints the scene (asset catalog, inherited context, clock, so a\n * webfont shapes and an `<Image>` loads); it is never laid out or painted by the scene tree, only measured against\n * `width` x `height` and drawn into the buffer.\n *\n * **Hoist the source.** Building it inside the scene builder allocates a new subtree every frame (re-binding,\n * re-laying-out, defeating the texture cache, leaking). A hoisted source is a stable identity, so the renderer keys\n * the GPU texture off the source object (a `WeakMap`) and a source that goes out of scope becomes collectable.\n */\nexport interface SurfaceTexture3D extends TextureOptions3D {\n /** A built `Graphics2D`, or a `Node2D` subtree (typed structurally, see {@link SurfaceSource3D}). */\n source: SurfaceSource3D;\n /** Buffer width in pixels. This *is* the texture's resolution. */\n width: number;\n height: number;\n /**\n * Declares the source's pixels unchanging, so the buffer is rasterized once and reused. Set by `resolveFill3D` for a\n * fill chain; an author's own source is live by default, so an animated `Graphics2D` or prop-driven subtree works\n * with no bookkeeping. Needs {@link identity} to be cacheable.\n *\n * @internal\n */\n static?: boolean;\n /**\n * Cache identity for a synthesized source. An author's source is identified by the object itself (right for a hoisted\n * one); a source built for a fill is fresh every frame, so the value it was derived from supplies one.\n *\n * @internal\n */\n identity?: string;\n /** Ceiling on the buffer's device-pixel ratio, default 1 (the buffer is exactly `width` x `height`). A surface is sampled at whatever size the geometry occupies, so `width`/`height` is the real control; raise this only for a surface viewed close up that reads soft. */\n maxPixelRatio?: number;\n}\n\n/** What a {@link SurfaceTexture3D} paints from: a built {@link Graphics2D} or a {@link Node2D} subtree. Both imports are type-only: `render3d` is pure data, and a value import of `Node2D` would close a real cycle. Narrow with {@link resolveSurfaceSource}. */\nexport type SurfaceSource3D = Graphics2D | Node;\n\n// Declared against the dimension-agnostic base because that is what a built node is typed as, so\n// `Tex.surface(new Rect({ ... }), ...)` type-checks without a cast. It must be 2D in fact; `resolveSurfaceSource`\n// narrows, and a `Node3D` fails at render time.\n\n/** A {@link SurfaceSource3D} narrowed to the arm its renderer should take. */\nexport type ResolvedSurfaceSource =\n | { kind: \"graphics\"; graphics: Graphics2D }\n | { kind: \"node\"; node: Node2D };\n\n/** Narrows a surface source to the arm that draws it: a `Graphics2D` is replayed into a render context, a `Node2D` is laid out against the buffer and rendered. Structural, not `instanceof` (value imports would close the cycle): `Graphics2D` exposes `ops()` and a `Node2D` doesn't. */\nexport function resolveSurfaceSource(source: SurfaceSource3D): ResolvedSurfaceSource {\n return typeof (source as Graphics2D).ops === \"function\"\n ? { kind: \"graphics\", graphics: source as Graphics2D }\n : { kind: \"node\", node: source as Node2D };\n}\n\n/** A texture reference; a bare string is sugar for `{ src }` (`map: \"/wood.png\"`). */\nexport type Texture3D = string | ImageTexture3D | DataTexture3D | SurfaceTexture3D;\n\nexport function isDataTexture3D(texture: Texture3D): texture is DataTexture3D {\n return typeof texture !== \"string\" && \"data\" in texture;\n}\n\nexport function isSurfaceTexture3D(texture: Texture3D): texture is SurfaceTexture3D {\n return typeof texture !== \"string\" && \"source\" in texture;\n}\n\nexport function resolveTexture3D(texture: Texture3D): ImageTexture3D | DataTexture3D | SurfaceTexture3D {\n return typeof texture === \"string\" ? { src: texture } : texture;\n}\n\n/** The asset `src` a texture reads from, or `null` for a data or surface texture; the asset-tracking pass uses it, and `null` means \"nothing to request\". */\nexport function texture3DSource(texture: Texture3D): string | null {\n if (typeof texture === \"string\") return texture;\n if (isDataTexture3D(texture) || isSurfaceTexture3D(texture)) return null;\n return texture.src;\n}\n\n/** True for a string that names an asset rather than a colour: a leading `/` or `.` is a path, otherwise the extension decides. A bare name like `\"wood\"` is a colour, as the manifest couldn't resolve it either. */\nexport function looksLikeAssetPath(value: string): boolean {\n return value.startsWith(\"/\")\n || value.startsWith(\".\")\n || /\\.(png|jpe?g|webp|avif|svg|ktx2?|hdr|exr|mp4|webm|mov)$/i.test(value);\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@motionscript/core",
3
- "version": "0.1.1-alpha.4",
3
+ "version": "0.1.1-alpha.5",
4
4
  "type": "module",
5
5
  "description": "Engine-agnostic animation library for Motion Script: scenes, nodes, props, tweens and layout.",
6
6
  "repository": {