- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Namespace List
- Namespace Members

# FCDAnimationCurveTools Namespace Reference

Contains tools to merge, collapse and otherwise modify animation curve. More...

## Functions
FCOLLADA_EXPORT FCDAnimationMultiCurve * | MergeCurves (const FCDAnimationCurveConstList &toMerge, const FloatList &defaultValues)
| Merges multiple single-dimensional animation curves into one multi-dimensional animation curve.
FCDAnimationMultiCurve * | MergeCurves (const FCDAnimationCurveList &toMerge, const FloatList &defaultValues)
| See above.
FCOLLADA_EXPORT FCDAnimationCurve * | Collapse (const FCDAnimationMultiCurve *curve, FCDCollapsingFunction collapse=NULL)
| Collapses a multi-dimensional curve into a one-dimensional curve.
float | TakeFirst (float *values, uint32 count)
| Retrieves the first floating-point value of a list of floating-point values.
float | Average (float *values, uint32 count)
| Retrieves the average value of a list of floating-point values.

## Detailed Description

Contains tools to merge, collapse and otherwise modify animation curve.

## Function Documentation

float FCDAnimationCurveTools::Average | ( | float * | values,
|  | uint32 | count
| ) |

  | Retrieves the average value of a list of floating-point values. This is a typical conversion function. Parameters:
  | values | The list of floating-point values.
  | count | The number of values within the given list.

FCOLLADA_EXPORT FCDAnimationCurve* FCDAnimationCurveTools::Collapse | ( | const FCDAnimationMultiCurve * | curve,
|  | FCDCollapsingFunction | collapse = `NULL`
| ) |

  | Collapses a multi-dimensional curve into a one-dimensional curve. See also: Average TakeFirst Parameters:
  | curve | The multi-dimensional curve to collapse.
  | collapse | The function to use to collapse multiple floating-point values into one. Set this to NULL to use the default collapsing function, which averages all the values.

FCOLLADA_EXPORT FCDAnimationMultiCurve* FCDAnimationCurveTools::MergeCurves | ( | const FCDAnimationCurveConstList & | toMerge,
|  | const FloatList & | defaultValues
| ) |

  | Merges multiple single-dimensional animation curves into one multi-dimensional animation curve. For each NULL element found within the 'toMerge' list, the corresponding default value is used. If there are not enough default values provided, zero is assumed. The number of dimensions for the output animation curve is taken as the size of the 'toMerge' list. Parameters:
  | toMerge | The list of single-dimensional animation curves to merge. This list may contain NULL elements, as explained above.
  | defaultValues | The list of default values to use when a NULL element is encountered. Default values should be provided even for the elements that are not NULL.

float FCDAnimationCurveTools::TakeFirst | ( | float * | values,
|  | uint32 | count
| ) |

  | Retrieves the first floating-point value of a list of floating-point values. This is a typical conversion function. Parameters:
  | values | The list of floating-point values.
  | count | The number of values within the given list.