#include <SkUnitMappers.h>
Inherits SkUnitMapper.
Public Member Functions | |
SkCosineMapper () | |
virtual uint16_t | mapUnit16 (uint16_t x) |
Protected Member Functions | |
SkCosineMapper (SkFlattenableReadBuffer &) | |
virtual Factory | getFactory () |
This returns cos(x), to simulate lighting a sphere, where 0 maps to the center of the sphere, and 1 maps to the edge.
Definition at line 47 of file SkUnitMappers.h.
SkCosineMapper::SkCosineMapper | ( | ) | [inline] |
Definition at line 49 of file SkUnitMappers.h.
SkCosineMapper::SkCosineMapper | ( | SkFlattenableReadBuffer & | ) | [protected] |
virtual Factory SkCosineMapper::getFactory | ( | ) | [protected, virtual] |
Implement this to return a factory function pointer that can be called to recreate your class given a buffer (previously written to by your override of flatten().
Implements SkFlattenable.
virtual uint16_t SkCosineMapper::mapUnit16 | ( | uint16_t | x | ) | [virtual] |
Given a value in [0..0xFFFF], return a value in the same range.
Implements SkUnitMapper.