mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-03-20 00:24:59 +08:00
CurveInput is an abstract base class so future curve representations (bezier, LUT-based, analytical functions) can be added without breaking downstream nodes that type-check against CurveInput. MonotoneCubicCurve is the concrete implementation that: - Mirrors frontend createMonotoneInterpolator (curveUtils.ts) exactly - Pre-computes slopes as numpy arrays at construction time - Provides vectorised interp_array() using numpy for batch evaluation - interp() for single-value evaluation - to_lut() for generating lookup tables CurveEditor node wraps raw widget points in MonotoneCubicCurve.
13 lines
289 B
Python
13 lines
289 B
Python
from .basic_types import ImageInput, AudioInput, MaskInput, LatentInput, CurveInput, MonotoneCubicCurve
|
|
from .video_types import VideoInput
|
|
|
|
__all__ = [
|
|
"ImageInput",
|
|
"AudioInput",
|
|
"VideoInput",
|
|
"MaskInput",
|
|
"LatentInput",
|
|
"CurveInput",
|
|
"MonotoneCubicCurve",
|
|
]
|