MCPcopy
hub / github.com/midrender/revideo / interpolation

Function interpolation

packages/2d/src/lib/decorators/signal.ts:188–199  ·  view source on GitHub ↗
(
  value: InterpolationFunction<T>,
)

Source from the content-addressed store, hash-verified

186 * @param value - The interpolation function for the property.
187 */
188export function interpolation<T>(
189 value: InterpolationFunction<T>,
190): PropertyDecorator {
191 return (target: any, key) => {
192 const meta = getPropertyMeta<T>(target, key);
193 if (!meta) {
194 useLogger().error(`Missing property decorator for "${key.toString()}"`);
195 return;
196 }
197 meta.interpolationFunction = value;
198 };
199}
200
201/**
202 * Create a signal parser decorator.

Callers 3

LayoutClass · 0.90
TxtLeafClass · 0.90
canvasStyleSignalFunction · 0.90

Calls 4

useLoggerFunction · 0.90
getPropertyMetaFunction · 0.85
errorMethod · 0.45
toStringMethod · 0.45

Tested by

no test coverage detected