Blender V2.61 - r43446
Classes | Defines | Typedefs | Functions | Variables

fmodifier.c File Reference

#include <math.h>
#include <stdio.h>
#include <stddef.h>
#include <string.h>
#include <float.h>
#include "MEM_guardedalloc.h"
#include "DNA_anim_types.h"
#include "BLI_blenlib.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "BKE_fcurve.h"
#include "BKE_idprop.h"

Go to the source code of this file.

Classes

struct  tFCMED_Cycles

Defines

#define SMALL   -1.0e-10
#define SELECT   1

Typedefs

typedef struct tFCMED_Cycles tFCMED_Cycles

Functions

static void fcm_generator_free (FModifier *fcm)
static void fcm_generator_copy (FModifier *fcm, FModifier *src)
static void fcm_generator_new_data (void *mdata)
static void fcm_generator_verify (FModifier *fcm)
static void fcm_generator_evaluate (FCurve *UNUSED(fcu), FModifier *fcm, float *cvalue, float evaltime)
static void fcm_fn_generator_new_data (void *mdata)
static double sinc (double x)
static void fcm_fn_generator_evaluate (FCurve *UNUSED(fcu), FModifier *fcm, float *cvalue, float evaltime)
static void fcm_envelope_free (FModifier *fcm)
static void fcm_envelope_copy (FModifier *fcm, FModifier *src)
static void fcm_envelope_new_data (void *mdata)
static void fcm_envelope_verify (FModifier *fcm)
static void fcm_envelope_evaluate (FCurve *UNUSED(fcu), FModifier *fcm, float *cvalue, float evaltime)
static void fcm_cycles_new_data (void *mdata)
static float fcm_cycles_time (FCurve *fcu, FModifier *fcm, float UNUSED(cvalue), float evaltime)
static void fcm_cycles_evaluate (FCurve *UNUSED(fcu), FModifier *fcm, float *cvalue, float UNUSED(evaltime))
static void fcm_noise_new_data (void *mdata)
static void fcm_noise_evaluate (FCurve *UNUSED(fcu), FModifier *fcm, float *cvalue, float evaltime)
static void fcm_python_free (FModifier *fcm)
static void fcm_python_new_data (void *mdata)
static void fcm_python_copy (FModifier *fcm, FModifier *src)
static void fcm_python_evaluate (FCurve *UNUSED(fcu), FModifier *UNUSED(fcm), float *UNUSED(cvalue), float UNUSED(evaltime))
static float fcm_limits_time (FCurve *UNUSED(fcu), FModifier *fcm, float UNUSED(cvalue), float evaltime)
static void fcm_limits_evaluate (FCurve *UNUSED(fcu), FModifier *fcm, float *cvalue, float UNUSED(evaltime))
static void fcm_stepped_new_data (void *mdata)
static float fcm_stepped_time (FCurve *UNUSED(fcu), FModifier *fcm, float UNUSED(cvalue), float evaltime)
static void fmods_init_typeinfo (void)
FModifierTypeInfoget_fmodifier_typeinfo (int type)
FModifierTypeInfofmodifier_get_typeinfo (FModifier *fcm)
FModifieradd_fmodifier (ListBase *modifiers, int type)
FModifiercopy_fmodifier (FModifier *src)
void copy_fmodifiers (ListBase *dst, ListBase *src)
int remove_fmodifier (ListBase *modifiers, FModifier *fcm)
void free_fmodifiers (ListBase *modifiers)
FModifierfind_active_fmodifier (ListBase *modifiers)
void set_active_fmodifier (ListBase *modifiers, FModifier *fcm)
short list_has_suitable_fmodifier (ListBase *modifiers, int mtype, short acttype)
static float eval_fmodifier_influence (FModifier *fcm, float evaltime)
float evaluate_time_fmodifiers (ListBase *modifiers, FCurve *fcu, float cvalue, float evaltime)
void evaluate_value_fmodifiers (ListBase *modifiers, FCurve *fcu, float *cvalue, float evaltime)
void fcurve_bake_modifiers (FCurve *fcu, int start, int end)

Variables

static FModifierTypeInfo FMI_GENERATOR
static FModifierTypeInfo FMI_FN_GENERATOR
static FModifierTypeInfo FMI_ENVELOPE
static FModifierTypeInfo FMI_CYCLES
static FModifierTypeInfo FMI_NOISE
static FModifierTypeInfo FMI_PYTHON
static FModifierTypeInfo FMI_LIMITS
static FModifierTypeInfo FMI_STEPPED
static FModifierTypeInfofmodifiersTypeInfo [FMODIFIER_NUM_TYPES]
static short FMI_INIT = 1

Detailed Description

Definition in file fmodifier.c.


Define Documentation

#define SELECT   1

Definition at line 51 of file fmodifier.c.

#define SMALL   -1.0e-10

Definition at line 50 of file fmodifier.c.


Typedef Documentation

typedef struct tFCMED_Cycles tFCMED_Cycles

Function Documentation

FModifier* add_fmodifier ( ListBase modifiers,
int  type 
) [read]
FModifier* copy_fmodifier ( FModifier src) [read]
void copy_fmodifiers ( ListBase dst,
ListBase src 
)
static float eval_fmodifier_influence ( FModifier fcm,
float  evaltime 
) [static]
float evaluate_time_fmodifiers ( ListBase modifiers,
FCurve fcu,
float  cvalue,
float  evaltime 
)
void evaluate_value_fmodifiers ( ListBase modifiers,
FCurve fcu,
float *  cvalue,
float  evaltime 
)
static void fcm_cycles_evaluate ( FCurve UNUSEDfcu,
FModifier fcm,
float *  cvalue,
float   UNUSEDevaltime 
) [static]

Definition at line 671 of file fmodifier.c.

References tFCMED_Cycles::cycyofs, FModifier::edata, if(), MEM_freeN(), and NULL.

static void fcm_cycles_new_data ( void *  mdata) [static]
static float fcm_cycles_time ( FCurve fcu,
FModifier fcm,
float   UNUSEDcvalue,
float  evaltime 
) [static]
static void fcm_envelope_copy ( FModifier fcm,
FModifier src 
) [static]

Definition at line 410 of file fmodifier.c.

References FModifier::data, FMod_Envelope::data, and MEM_dupallocN().

static void fcm_envelope_evaluate ( FCurve UNUSEDfcu,
FModifier fcm,
float *  cvalue,
float  evaltime 
) [static]
static void fcm_envelope_free ( FModifier fcm) [static]

Definition at line 401 of file fmodifier.c.

References FModifier::data, FMod_Envelope::data, if(), and MEM_freeN().

static void fcm_envelope_new_data ( void *  mdata) [static]

Definition at line 420 of file fmodifier.c.

References FMod_Envelope::max, and FMod_Envelope::min.

static void fcm_envelope_verify ( FModifier fcm) [static]

Definition at line 429 of file fmodifier.c.

References FModifier::data, FMod_Envelope::data, and if().

static void fcm_fn_generator_evaluate ( FCurve UNUSEDfcu,
FModifier fcm,
float *  cvalue,
float  evaltime 
) [static]
static void fcm_fn_generator_new_data ( void *  mdata) [static]
static void fcm_generator_copy ( FModifier fcm,
FModifier src 
) [static]

Definition at line 114 of file fmodifier.c.

References FMod_Generator::coefficients, FModifier::data, and MEM_dupallocN().

static void fcm_generator_evaluate ( FCurve UNUSEDfcu,
FModifier fcm,
float *  cvalue,
float  evaltime 
) [static]
static void fcm_generator_free ( FModifier fcm) [static]

Definition at line 105 of file fmodifier.c.

References FMod_Generator::coefficients, FModifier::data, data, if(), and MEM_freeN().

static void fcm_generator_new_data ( void *  mdata) [static]
static void fcm_generator_verify ( FModifier fcm) [static]
static void fcm_limits_evaluate ( FCurve UNUSEDfcu,
FModifier fcm,
float *  cvalue,
float   UNUSEDevaltime 
) [static]
static float fcm_limits_time ( FCurve UNUSEDfcu,
FModifier fcm,
float   UNUSEDcvalue,
float  evaltime 
) [static]
static void fcm_noise_evaluate ( FCurve UNUSEDfcu,
FModifier fcm,
float *  cvalue,
float  evaltime 
) [static]
static void fcm_noise_new_data ( void *  mdata) [static]
static void fcm_python_copy ( FModifier fcm,
FModifier src 
) [static]

Definition at line 799 of file fmodifier.c.

References FModifier::data, IDP_CopyProperty(), and FMod_Python::prop.

static void fcm_python_evaluate ( FCurve UNUSEDfcu,
FModifier UNUSEDfcm,
float *  UNUSEDcvalue,
float   UNUSEDevaltime 
) [static]

Definition at line 807 of file fmodifier.c.

static void fcm_python_free ( FModifier fcm) [static]

Definition at line 781 of file fmodifier.c.

References FModifier::data, data, IDP_FreeProperty(), MEM_freeN(), and FMod_Python::prop.

static void fcm_python_new_data ( void *  mdata) [static]

Definition at line 790 of file fmodifier.c.

References data, IDP_GROUP, MEM_callocN(), FMod_Python::prop, and IDProperty::type.

static void fcm_stepped_new_data ( void *  mdata) [static]

Definition at line 878 of file fmodifier.c.

References data, and FMod_Stepped::step_size.

static float fcm_stepped_time ( FCurve UNUSEDfcu,
FModifier fcm,
float   UNUSEDcvalue,
float  evaltime 
) [static]
void fcurve_bake_modifiers ( FCurve fcu,
int  start,
int  end 
)
FModifier* find_active_fmodifier ( ListBase modifiers) [read]
FModifierTypeInfo* fmodifier_get_typeinfo ( FModifier fcm)
static void fmods_init_typeinfo ( void  ) [static]
void free_fmodifiers ( ListBase modifiers)
FModifierTypeInfo* get_fmodifier_typeinfo ( int  type)
short list_has_suitable_fmodifier ( ListBase modifiers,
int  mtype,
short  acttype 
)
int remove_fmodifier ( ListBase modifiers,
FModifier fcm 
)
void set_active_fmodifier ( ListBase modifiers,
FModifier fcm 
)
static double sinc ( double  x) [static]

Definition at line 302 of file fmodifier.c.

References fabs(), M_PI, and sin().

Referenced by fcm_fn_generator_evaluate().


Variable Documentation

Initial value:

Definition at line 384 of file fmodifier.c.

Referenced by fmods_init_typeinfo().

short FMI_INIT = 1 [static]

Definition at line 936 of file fmodifier.c.

Initial value:

Definition at line 861 of file fmodifier.c.

Referenced by fmods_init_typeinfo().

Initial value:

Definition at line 744 of file fmodifier.c.

Referenced by fmods_init_typeinfo().

Initial value:

Definition at line 914 of file fmodifier.c.

Referenced by fmods_init_typeinfo().

FModifierTypeInfo* fmodifiersTypeInfo[FMODIFIER_NUM_TYPES] [static]

Definition at line 935 of file fmodifier.c.