Skia
2D Graphics Library
SkCubicMap Class Reference

Fast evaluation of a cubic ease-in / ease-out curve. More...

#include <SkCubicMap.h>

Public Member Functions

 SkCubicMap (SkPoint p1, SkPoint p2)
 
float computeYFromX (float x) const
 
SkPoint computeFromT (float t) const
 

Static Public Member Functions

static bool IsLinear (SkPoint p1, SkPoint p2)
 

Detailed Description

Fast evaluation of a cubic ease-in / ease-out curve.

This is defined as a parametric cubic curve inside the unit square.

pt[0] is implicitly { 0, 0 } pt[3] is implicitly { 1, 1 } pts[1,2].X are inside the unit [0..1]

Constructor & Destructor Documentation

◆ SkCubicMap()

SkCubicMap::SkCubicMap ( SkPoint  p1,
SkPoint  p2 
)

Member Function Documentation

◆ computeFromT()

SkPoint SkCubicMap::computeFromT ( float  t) const

◆ computeYFromX()

float SkCubicMap::computeYFromX ( float  x) const

◆ IsLinear()

static bool SkCubicMap::IsLinear ( SkPoint  p1,
SkPoint  p2 
)
inlinestatic

The documentation for this class was generated from the following file: