// Init initializes the width property with the provided element for animation. func (h *Height) Init(elem govfx.Elemental) { h.elem = elem if h.Easer == nil { h.Easer = govfx.GetEasing(h.Easing) } if ws, _, ok := elem.ReadInt("width", ""); ok { h.current = float64(ws) } }
// Init initializes the width property with the provided element for animation. func (w *Width) Init(elem govfx.Elemental) { w.elem = elem if w.Easer == nil { w.Easer = govfx.GetEasing(w.Easing) } if ws, _, ok := elem.ReadInt("width", ""); ok { w.current = float64(ws) } }
// Blend adjust the property details to match appropriate state. func (t *Color) Blend(interpolation float64) { easing := govfx.GetEasing(t.Easing) t.color = Colors.Blend(easing, t.color, interpolation) }
// Update updates the property details. func (t *Color) Update(delta float64, timeline float64) { easing := govfx.GetEasing(t.Easing) t.color = Colors.Interpolate(easing, t.base, t.color, delta, timeline) }