Blender V2.61 - r43446
|
#include "DNA_meshdata_types.h"
#include "DNA_object_types.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "BLI_string.h"
#include "BKE_deform.h"
#include "BKE_DerivedMesh.h"
#include "BKE_modifier.h"
#include "depsgraph_private.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 | isDisabled (ModifierData *md, int UNUSED(useRenderParams)) |
static CustomDataMask | requiredDataMask (Object *UNUSED(ob), ModifierData *md) |
static void | foreachObjectLink (ModifierData *md, Object *ob, void(*walk)(void *userData, Object *ob, Object **obpoin), void *userData) |
static void | updateDepgraph (ModifierData *md, DagForest *forest, struct Scene *UNUSED(scene), Object *UNUSED(ob), DagNode *obNode) |
static void | sphere_do (CastModifierData *cmd, Object *ob, DerivedMesh *dm, float(*vertexCos)[3], int numVerts) |
static void | cuboid_do (CastModifierData *cmd, 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_Cast |
Definition in file MOD_cast.c.
static void copyData | ( | ModifierData * | md, |
ModifierData * | target | ||
) | [static] |
Definition at line 68 of file MOD_cast.c.
References BLI_strncpy(), CastModifierData::defgrp_name, CastModifierData::fac, CastModifierData::flag, CastModifierData::object, CastModifierData::radius, CastModifierData::size, and CastModifierData::type.
static void cuboid_do | ( | CastModifierData * | cmd, |
Object * | ob, | ||
DerivedMesh * | dm, | ||
float(*) | vertexCos[3], | ||
int | numVerts | ||
) | [static] |
Definition at line 298 of file MOD_cast.c.
References add_v3_v3(), copy_v3_v3(), simple_enum_gen::d, CastModifierData::defgrp_name, DO_MINMAX, MDeformVert::dw, fabs(), fabsf, CastModifierData::fac, CastModifierData::flag, i, Object::imat, INIT_MINMAX, invert_m4_m4(), max, min, MOD_CAST_SIZE_FROM_RADIUS, MOD_CAST_USE_OB_TRANSFORM, MOD_CAST_X, MOD_CAST_Y, MOD_CAST_Z, modifier_get_vgroup(), mul_m4_v3(), mul_v3_m4v3(), mult_m4_m4m4(), NULL, CastModifierData::object, Object::obmat, CastModifierData::radius, CastModifierData::size, sub_v3_v3(), sub_v3_v3v3(), MDeformVert::totweight, and MDeformWeight::weight.
Referenced by deformVerts(), and deformVertsEM().
static void deformVerts | ( | ModifierData * | md, |
Object * | ob, | ||
DerivedMesh * | derivedData, | ||
float(*) | vertexCos[3], | ||
int | numVerts, | ||
int | UNUSEDuseRenderParams, | ||
int | UNUSEDisFinalCalc | ||
) | [static] |
Definition at line 565 of file MOD_cast.c.
References cuboid_do(), get_dm(), MOD_CAST_TYPE_CUBOID, NULL, DerivedMesh::release, sphere_do(), and CastModifierData::type.
static void deformVertsEM | ( | ModifierData * | md, |
Object * | ob, | ||
struct EditMesh * | editData, | ||
DerivedMesh * | derivedData, | ||
float(*) | vertexCos[3], | ||
int | numVerts | ||
) | [static] |
Definition at line 587 of file MOD_cast.c.
References cuboid_do(), get_dm(), MOD_CAST_TYPE_CUBOID, NULL, DerivedMesh::release, sphere_do(), and CastModifierData::type.
static void foreachObjectLink | ( | ModifierData * | md, |
Object * | ob, | ||
void(*)(void *userData, Object *ob, Object **obpoin) | walk, | ||
void * | userData | ||
) | [static] |
Definition at line 105 of file MOD_cast.c.
References CastModifierData::object.
static void initData | ( | ModifierData * | md | ) | [static] |
Definition at line 53 of file MOD_cast.c.
References CastModifierData::defgrp_name, CastModifierData::fac, CastModifierData::flag, MOD_CAST_SIZE_FROM_RADIUS, MOD_CAST_TYPE_SPHERE, MOD_CAST_X, MOD_CAST_Y, MOD_CAST_Z, NULL, CastModifierData::object, CastModifierData::radius, CastModifierData::size, and CastModifierData::type.
static int isDisabled | ( | ModifierData * | md, |
int | UNUSEDuseRenderParams | ||
) | [static] |
Definition at line 82 of file MOD_cast.c.
References CastModifierData::fac, CastModifierData::flag, MOD_CAST_X, MOD_CAST_Y, and MOD_CAST_Z.
static CustomDataMask requiredDataMask | ( | Object * | UNUSEDob, |
ModifierData * | md | ||
) | [static] |
Definition at line 94 of file MOD_cast.c.
References CD_MASK_MDEFORMVERT, and CastModifierData::defgrp_name.
static void sphere_do | ( | CastModifierData * | cmd, |
Object * | ob, | ||
DerivedMesh * | dm, | ||
float(*) | vertexCos[3], | ||
int | numVerts | ||
) | [static] |
Definition at line 130 of file MOD_cast.c.
References add_v3_v3(), copy_v3_v3(), CastModifierData::defgrp_name, defvert_find_weight(), CastModifierData::fac, CastModifierData::flag, i, Object::imat, invert_m4_m4(), len(), len_v3(), len_v3v3(), MOD_CAST_SIZE_FROM_RADIUS, MOD_CAST_TYPE_CYLINDER, MOD_CAST_USE_OB_TRANSFORM, MOD_CAST_X, MOD_CAST_Y, MOD_CAST_Z, modifier_get_vgroup(), mul_m4_v3(), mul_v3_m4v3(), mult_m4_m4m4(), normalize_v3(), NULL, CastModifierData::object, Object::obmat, CastModifierData::radius, CastModifierData::size, sub_v3_v3(), DerivedMesh::type, and CastModifierData::type.
Referenced by deformVerts(), and deformVertsEM().
static void updateDepgraph | ( | ModifierData * | md, |
DagForest * | forest, | ||
struct Scene * | UNUSEDscene, | ||
Object * | UNUSEDob, | ||
DagNode * | obNode | ||
) | [static] |
Definition at line 115 of file MOD_cast.c.
References dag_add_relation(), dag_get_node(), DAG_RL_OB_DATA, and CastModifierData::object.
{ "Cast", "CastModifierData", sizeof(CastModifierData), eModifierTypeType_OnlyDeform, eModifierTypeFlag_AcceptsCVs | eModifierTypeFlag_SupportsEditmode, copyData, deformVerts, NULL, deformVertsEM, NULL, NULL, NULL, initData, requiredDataMask, NULL, isDisabled, updateDepgraph, NULL, NULL, foreachObjectLink, NULL, NULL, }
Definition at line 605 of file MOD_cast.c.