Blender V2.61 - r43446
|
#include "BLI_math.h"
#include "DNA_meshdata_types.h"
#include "DNA_scene_types.h"
#include "DNA_object_types.h"
#include "BLI_utildefines.h"
#include "BLI_string.h"
#include "BKE_DerivedMesh.h"
#include "BKE_object.h"
#include "BKE_deform.h"
#include "BKE_scene.h"
#include "depsgraph_private.h"
#include "MEM_guardedalloc.h"
#include "RE_shader_ext.h"
#include "MOD_modifiertypes.h"
#include "MOD_util.h"
Go to the source code of this file.
Functions | |
static void | initData (ModifierData *md) |
static void | copyData (ModifierData *md, ModifierData *target) |
static int | dependsOnTime (ModifierData *UNUSED(md)) |
static void | foreachObjectLink (ModifierData *md, Object *ob, ObjectWalkFunc walk, void *userData) |
static void | foreachIDLink (ModifierData *md, Object *ob, IDWalkFunc walk, void *userData) |
static void | foreachTexLink (ModifierData *md, Object *ob, TexWalkFunc walk, void *userData) |
static void | updateDepgraph (ModifierData *md, DagForest *forest, Scene *UNUSED(scene), Object *UNUSED(ob), DagNode *obNode) |
static CustomDataMask | requiredDataMask (Object *UNUSED(ob), ModifierData *md) |
static void | waveModifier_do (WaveModifierData *md, Scene *scene, Object *ob, DerivedMesh *dm, float(*vertexCos)[3], int numVerts) |
static void | deformVerts (ModifierData *md, Object *ob, DerivedMesh *derivedData, float(*vertexCos)[3], int numVerts, int UNUSED(useRenderParams), int UNUSED(isFinalCalc)) |
static void | deformVertsEM (ModifierData *md, Object *ob, struct EditMesh *editData, DerivedMesh *derivedData, float(*vertexCos)[3], int numVerts) |
Variables | |
ModifierTypeInfo | modifierType_Wave |
Definition in file MOD_wave.c.
static void copyData | ( | ModifierData * | md, |
ModifierData * | target | ||
) | [static] |
Definition at line 80 of file MOD_wave.c.
References BLI_strncpy(), WaveModifierData::damp, WaveModifierData::defgrp_name, WaveModifierData::falloff, WaveModifierData::flag, WaveModifierData::height, WaveModifierData::lifetime, WaveModifierData::map_object, WaveModifierData::narrow, WaveModifierData::objectcenter, WaveModifierData::speed, WaveModifierData::startx, WaveModifierData::starty, WaveModifierData::texmapping, WaveModifierData::texture, WaveModifierData::timeoffs, and WaveModifierData::width.
static void deformVerts | ( | ModifierData * | md, |
Object * | ob, | ||
DerivedMesh * | derivedData, | ||
float(*) | vertexCos[3], | ||
int | numVerts, | ||
int | UNUSEDuseRenderParams, | ||
int | UNUSEDisFinalCalc | ||
) | [static] |
Definition at line 326 of file MOD_wave.c.
References WaveModifierData::defgrp_name, WaveModifierData::flag, get_cddm(), get_dm(), MOD_WAVE_NORM, NULL, DerivedMesh::release, ModifierData::scene, WaveModifierData::texture, and waveModifier_do().
static void deformVertsEM | ( | ModifierData * | md, |
Object * | ob, | ||
struct EditMesh * | editData, | ||
DerivedMesh * | derivedData, | ||
float(*) | vertexCos[3], | ||
int | numVerts | ||
) | [static] |
Definition at line 347 of file MOD_wave.c.
References WaveModifierData::defgrp_name, WaveModifierData::flag, get_cddm(), get_dm(), MOD_WAVE_NORM, NULL, DerivedMesh::release, ModifierData::scene, WaveModifierData::texture, and waveModifier_do().
static int dependsOnTime | ( | ModifierData * | UNUSEDmd | ) | [static] |
Definition at line 103 of file MOD_wave.c.
static void foreachIDLink | ( | ModifierData * | md, |
Object * | ob, | ||
IDWalkFunc | walk, | ||
void * | userData | ||
) | [static] |
Definition at line 118 of file MOD_wave.c.
References foreachObjectLink(), and WaveModifierData::texture.
static void foreachObjectLink | ( | ModifierData * | md, |
Object * | ob, | ||
ObjectWalkFunc | walk, | ||
void * | userData | ||
) | [static] |
Definition at line 108 of file MOD_wave.c.
References WaveModifierData::map_object, and WaveModifierData::objectcenter.
Referenced by foreachIDLink().
static void foreachTexLink | ( | ModifierData * | md, |
Object * | ob, | ||
TexWalkFunc | walk, | ||
void * | userData | ||
) | [static] |
Definition at line 128 of file MOD_wave.c.
static void initData | ( | ModifierData * | md | ) | [static] |
Definition at line 59 of file MOD_wave.c.
References WaveModifierData::damp, WaveModifierData::defgrp_name, WaveModifierData::falloff, WaveModifierData::flag, WaveModifierData::height, WaveModifierData::lifetime, WaveModifierData::map_object, MOD_DISP_MAP_LOCAL, MOD_WAVE_CYCL, MOD_WAVE_NORM_X, MOD_WAVE_NORM_Y, MOD_WAVE_NORM_Z, MOD_WAVE_X, MOD_WAVE_Y, WaveModifierData::narrow, NULL, WaveModifierData::objectcenter, WaveModifierData::speed, WaveModifierData::texmapping, WaveModifierData::texture, and WaveModifierData::width.
static CustomDataMask requiredDataMask | ( | Object * | UNUSEDob, |
ModifierData * | md | ||
) | [static] |
Definition at line 156 of file MOD_wave.c.
References CD_MASK_MDEFORMVERT, CD_MASK_MTFACE, WaveModifierData::defgrp_name, MOD_DISP_MAP_UV, WaveModifierData::texmapping, and WaveModifierData::texture.
static void updateDepgraph | ( | ModifierData * | md, |
DagForest * | forest, | ||
Scene * | UNUSEDscene, | ||
Object * | UNUSEDob, | ||
DagNode * | obNode | ||
) | [static] |
Definition at line 134 of file MOD_wave.c.
References dag_add_relation(), dag_get_node(), DAG_RL_OB_DATA, WaveModifierData::map_object, and WaveModifierData::objectcenter.
static void waveModifier_do | ( | WaveModifierData * | md, |
Scene * | scene, | ||
Object * | ob, | ||
DerivedMesh * | dm, | ||
float(*) | vertexCos[3], | ||
int | numVerts | ||
) | [static] |
Definition at line 173 of file MOD_wave.c.
References BKE_curframe(), CLAMP(), co, WaveModifierData::damp, WaveModifierData::defgrp_name, defvert_find_weight(), KDL::exp(), expf, fabsf, WaveModifierData::falloff, WaveModifierData::flag, fmodf, get_texture_coords(), get_texture_value(), DerivedMesh::getVertArray, WaveModifierData::height, i, Object::imat, invert_m4_m4(), WaveModifierData::lifetime, MEM_freeN(), MEM_mallocN(), MOD_WAVE_CYCL, MOD_WAVE_NORM, MOD_WAVE_NORM_X, MOD_WAVE_NORM_Y, MOD_WAVE_NORM_Z, MOD_WAVE_X, MOD_WAVE_Y, modifier_get_vgroup(), mult_m4_m4m4(), WaveModifierData::narrow, TexResult::nor, NULL, OB_MESH, WaveModifierData::objectcenter, Object::obmat, WaveModifierData::speed, sqrtf, WaveModifierData::startx, WaveModifierData::starty, WaveModifierData::texture, WaveModifierData::timeoffs, TexResult::tin, Object::type, and WaveModifierData::width.
Referenced by deformVerts(), and deformVertsEM().
{ "Wave", "WaveModifierData", sizeof(WaveModifierData), eModifierTypeType_OnlyDeform, eModifierTypeFlag_AcceptsCVs | eModifierTypeFlag_SupportsEditmode, copyData, deformVerts, NULL, deformVertsEM, NULL, NULL, NULL, initData, requiredDataMask, NULL, NULL, updateDepgraph, dependsOnTime, NULL, foreachObjectLink, foreachIDLink, foreachTexLink, }
Definition at line 366 of file MOD_wave.c.