Opal::UI::CurveEditor
Inherits Opal::UI::Control < Opal::UI::InputHookable < Opal::UI::Element < Opal::UI::Themable < Reference < Object
Interactive Bézier Curve & Easing Editor. Features 2x4 sub-pixel Unicode Braille plotting, draggable P1/P2 control handles, CSS cubic-bezier output, standard presets, and real-time physics easing preview.
Constants
PRESETS = {"linear" => {0.0, 0.0, 1.0, 1.0}, "ease" => {0.25, 0.1, 0.25, 1.0}, "ease_in" => {0.42, 0.0, 1.0, 1.0}, "ease_out" => {0.0, 0.0, 0.58, 1.0}, "ease_in_out" => {0.42, 0.0, 0.58, 1.0}, "ease_in_back" => {0.36, 0.0, 0.66, -0.56}, "ease_out_back" => {0.34, 1.56, 0.64, 1.0}}
Presets
Constructors
Instance methods
anim_progress
Sourceborder_color
Sourceborder_color=(border_color : Color)
SourceSolves for y given x in [0.0..1.0] using bisection (approximate inversion for animation easing)
grid_color
Sourcegrid_color=(grid_color : Color)
SourceDefault key event handler. Override in subclasses if not using @default_input_proc.
Default mouse event handler. Override in subclasses if not using @default_input_proc.
handle_p1_color
Sourcehandle_p1_color=(handle_p1_color : Color)
Sourcehandle_p2_color
Sourcehandle_p2_color=(handle_p2_color : Color)
Sourceheight
Sourcelast_h
Sourcelast_w
Sourcelast_x
Sourcelast_y
Sourcep1_x
Sourcep1_y
Sourcep2_x
Sourcep2_y
Sourcerender(buffer : Buffer) : Nil
SourceEvaluates cubic Bézier parametric coordinate (bx, by) at parameter t in [0.0..1.0]
show_ball_track
Sourcewidth
Source