A sequence of piecewise linear functions.
void mypaint_mapping_get_point(MyPaintMapping *self, int input, int index, float *x, float *y)
Get the x, y coordinates for a control point.
float mypaint_mapping_calculate_single_input(MyPaintMapping *self, float input)
Calculate the output for a single-input mapping.
void mypaint_mapping_free(MyPaintMapping *self)
Free an instance of MyPaintMapping.
void mypaint_mapping_set_point(MyPaintMapping *self, int input, int index, float x, float y)
Set the x, y coordinates for a control point.
int mypaint_mapping_get_inputs_used_n(MyPaintMapping *self)
Get the number of inputs that have control points.
gboolean mypaint_mapping_is_constant(MyPaintMapping *self)
Returns TRUE if none of the mappings are used.
float mypaint_mapping_calculate(MyPaintMapping *self, float *data)
Calculate the output of the mapping, given an input value for each mapping.
void mypaint_mapping_set_n(MyPaintMapping *self, int input, int n)
Set the number of control points used for the input.
void mypaint_mapping_set_base_value(MyPaintMapping *self, float value)
Set the base value of the mappings.
int mypaint_mapping_get_n(MyPaintMapping *self, int input)
Get the number of control points used for the input.
MyPaintMapping * mypaint_mapping_new(int inputs_)
Create new mappings for a set number of inputs.
float mypaint_mapping_get_base_value(MyPaintMapping *self)
Get the base value of the mappings.
gint gboolean
Definition: mypaint-glib-compat.h:25
#define G_END_DECLS
Definition: mypaint-glib-compat.h:14
#define G_BEGIN_DECLS
Definition: mypaint-glib-compat.h:13