Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/physics')
-rw-r--r--source/blender/editors/physics/particle_edit.c14
-rw-r--r--source/blender/editors/physics/physics_fluid.c4
-rw-r--r--source/blender/editors/physics/rigidbody_constraint.c4
3 files changed, 11 insertions, 11 deletions
diff --git a/source/blender/editors/physics/particle_edit.c b/source/blender/editors/physics/particle_edit.c
index e93382435db..a46425a937e 100644
--- a/source/blender/editors/physics/particle_edit.c
+++ b/source/blender/editors/physics/particle_edit.c
@@ -4458,7 +4458,7 @@ static void get_PTCacheUndo(PTCacheEdit *edit, PTCacheUndo *undo)
void PE_undo_push(Scene *scene, SceneLayer *sl, const char *str)
{
- PTCacheEdit *edit= PE_get_current(scene, sl, OBACT_NEW(sl));
+ PTCacheEdit *edit= PE_get_current(scene, sl, OBACT(sl));
PTCacheUndo *undo;
int nr;
@@ -4500,7 +4500,7 @@ void PE_undo_push(Scene *scene, SceneLayer *sl, const char *str)
void PE_undo_step(Scene *scene, SceneLayer *sl, int step)
{
- PTCacheEdit *edit= PE_get_current(scene, sl, OBACT_NEW(sl));
+ PTCacheEdit *edit= PE_get_current(scene, sl, OBACT(sl));
if (!edit) return;
@@ -4531,12 +4531,12 @@ void PE_undo_step(Scene *scene, SceneLayer *sl, int step)
}
}
- DEG_id_tag_update(&OBACT_NEW(sl)->id, OB_RECALC_DATA);
+ DEG_id_tag_update(&OBACT(sl)->id, OB_RECALC_DATA);
}
bool PE_undo_is_valid(Scene *scene, SceneLayer *sl)
{
- PTCacheEdit *edit= PE_get_current(scene, sl, OBACT_NEW(sl));
+ PTCacheEdit *edit= PE_get_current(scene, sl, OBACT(sl));
if (edit) {
return (edit->undo.last != edit->undo.first);
@@ -4571,7 +4571,7 @@ void PE_redo(Scene *scene, SceneLayer *sl)
void PE_undo_number(Scene *scene, SceneLayer *sl, int nr)
{
- PTCacheEdit *edit= PE_get_current(scene, sl, OBACT_NEW(sl));
+ PTCacheEdit *edit= PE_get_current(scene, sl, OBACT(sl));
PTCacheUndo *undo;
int a=0;
@@ -4587,7 +4587,7 @@ void PE_undo_number(Scene *scene, SceneLayer *sl, int nr)
/* if active pointer, set it to 1 if true */
const char *PE_undo_get_name(Scene *scene, SceneLayer *sl, int nr, bool *r_active)
{
- PTCacheEdit *edit= PE_get_current(scene, sl, OBACT_NEW(sl));
+ PTCacheEdit *edit= PE_get_current(scene, sl, OBACT(sl));
PTCacheUndo *undo;
if (r_active) *r_active = false;
@@ -4608,7 +4608,7 @@ const char *PE_undo_get_name(Scene *scene, SceneLayer *sl, int nr, bool *r_activ
int PE_minmax(Scene *scene, SceneLayer *sl, float min[3], float max[3])
{
- Object *ob= OBACT_NEW(sl);
+ Object *ob= OBACT(sl);
PTCacheEdit *edit= PE_get_current(scene, sl, ob);
ParticleSystem *psys;
ParticleSystemModifierData *psmd = NULL;
diff --git a/source/blender/editors/physics/physics_fluid.c b/source/blender/editors/physics/physics_fluid.c
index 071dafe08bb..3c4aeaf145f 100644
--- a/source/blender/editors/physics/physics_fluid.c
+++ b/source/blender/editors/physics/physics_fluid.c
@@ -350,7 +350,7 @@ static void fluid_init_all_channels(bContext *C, Object *UNUSED(fsDomain), Fluid
channels->DomainTime = MEM_callocN(length * (CHANNEL_FLOAT+1) * sizeof(float), "channel DomainTime");
/* allocate fluid objects */
- for (base = FIRSTBASE_NEW(sl); base; base = base->next) {
+ for (base = FIRSTBASE(sl); base; base = base->next) {
Object *ob = base->object;
FluidsimModifierData *fluidmd = (FluidsimModifierData *)modifiers_findByType(ob, eModifierType_Fluidsim);
@@ -587,7 +587,7 @@ static int fluid_validate_scene(ReportList *reports, SceneLayer *sl, Object *fsD
int channelObjCount = 0;
int fluidInputCount = 0;
- for (base = FIRSTBASE_NEW(sl); base; base = base->next) {
+ for (base = FIRSTBASE(sl); base; base = base->next) {
Object *ob = base->object;
FluidsimModifierData *fluidmdtmp = (FluidsimModifierData *)modifiers_findByType(ob, eModifierType_Fluidsim);
diff --git a/source/blender/editors/physics/rigidbody_constraint.c b/source/blender/editors/physics/rigidbody_constraint.c
index 1c9b59268e4..13b2943b6e6 100644
--- a/source/blender/editors/physics/rigidbody_constraint.c
+++ b/source/blender/editors/physics/rigidbody_constraint.c
@@ -121,7 +121,7 @@ static int rigidbody_con_add_exec(bContext *C, wmOperator *op)
Scene *scene = CTX_data_scene(C);
SceneLayer *sl = CTX_data_scene_layer(C);
RigidBodyWorld *rbw = BKE_rigidbody_get_world(scene);
- Object *ob = OBACT_NEW(sl);
+ Object *ob = OBACT(sl);
int type = RNA_enum_get(op->ptr, "type");
bool changed;
@@ -170,7 +170,7 @@ static int rigidbody_con_remove_exec(bContext *C, wmOperator *op)
Main *bmain = CTX_data_main(C);
Scene *scene = CTX_data_scene(C);
SceneLayer *sl = CTX_data_scene_layer(C);
- Object *ob = OBACT_NEW(sl);
+ Object *ob = OBACT(sl);
/* apply to active object */
if (ELEM(NULL, ob, ob->rigidbody_constraint)) {