diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-04-06 13:07:27 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-04-16 20:55:33 +0300 |
commit | 34ab90f546f097cada951b2c9ca22bf271996980 (patch) | |
tree | ebcdb3d37120ac1d8fb16462b9104badd1800329 /source/blender/editors/space_view3d/view3d_iterators.c | |
parent | 0c495005dd83913864acb510c1d4194a2275dbb0 (diff) |
Depsgraph: remove EvaluationContext, pass Depsgraph instead.
The depsgraph was always created within a fixed evaluation context. Passing
both risks the depsgraph and evaluation context not matching, and it
complicates the Python API where we'd have to expose both which is not so
easy to understand.
This also removes the global evaluation context in main, which assumed there
to be a single active scene and view layer.
Differential Revision: https://developer.blender.org/D3152
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_iterators.c')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_iterators.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/editors/space_view3d/view3d_iterators.c b/source/blender/editors/space_view3d/view3d_iterators.c index 4f80270e1e7..35127c7c8c6 100644 --- a/source/blender/editors/space_view3d/view3d_iterators.c +++ b/source/blender/editors/space_view3d/view3d_iterators.c @@ -107,14 +107,14 @@ static void meshobject_foreachScreenVert__mapFunc(void *userData, int index, con } void meshobject_foreachScreenVert( - const EvaluationContext *eval_ctx, ViewContext *vc, + ViewContext *vc, void (*func)(void *userData, MVert *eve, const float screen_co[2], int index), void *userData, eV3DProjTest clip_flag) { foreachScreenObjectVert_userData data; DerivedMesh *dm; - dm = mesh_get_derived_deform(eval_ctx, vc->scene, vc->obact, CD_MASK_BAREMESH); + dm = mesh_get_derived_deform(vc->depsgraph, vc->scene, vc->obact, CD_MASK_BAREMESH); ED_view3d_check_mats_rv3d(vc->rv3d); @@ -150,14 +150,14 @@ static void mesh_foreachScreenVert__mapFunc(void *userData, int index, const flo } void mesh_foreachScreenVert( - const EvaluationContext *eval_ctx, ViewContext *vc, + ViewContext *vc, void (*func)(void *userData, BMVert *eve, const float screen_co[2], int index), void *userData, eV3DProjTest clip_flag) { foreachScreenVert_userData data; DerivedMesh *dm; - dm = editbmesh_get_derived_cage(eval_ctx, vc->scene, vc->obedit, vc->em, CD_MASK_BAREMESH); + dm = editbmesh_get_derived_cage(vc->depsgraph, vc->scene, vc->obedit, vc->em, CD_MASK_BAREMESH); ED_view3d_check_mats_rv3d(vc->rv3d); @@ -206,14 +206,14 @@ static void mesh_foreachScreenEdge__mapFunc(void *userData, int index, const flo } void mesh_foreachScreenEdge( - const EvaluationContext *eval_ctx, ViewContext *vc, + ViewContext *vc, void (*func)(void *userData, BMEdge *eed, const float screen_co_a[2], const float screen_co_b[2], int index), void *userData, eV3DProjTest clip_flag) { foreachScreenEdge_userData data; DerivedMesh *dm; - dm = editbmesh_get_derived_cage(eval_ctx, vc->scene, vc->obedit, vc->em, CD_MASK_BAREMESH); + dm = editbmesh_get_derived_cage(vc->depsgraph, vc->scene, vc->obedit, vc->em, CD_MASK_BAREMESH); ED_view3d_check_mats_rv3d(vc->rv3d); @@ -254,14 +254,14 @@ static void mesh_foreachScreenFace__mapFunc(void *userData, int index, const flo } void mesh_foreachScreenFace( - const EvaluationContext *eval_ctx, ViewContext *vc, + ViewContext *vc, void (*func)(void *userData, BMFace *efa, const float screen_co_b[2], int index), void *userData, const eV3DProjTest clip_flag) { foreachScreenFace_userData data; DerivedMesh *dm; - dm = editbmesh_get_derived_cage(eval_ctx, vc->scene, vc->obedit, vc->em, CD_MASK_BAREMESH); + dm = editbmesh_get_derived_cage(vc->depsgraph, vc->scene, vc->obedit, vc->em, CD_MASK_BAREMESH); ED_view3d_check_mats_rv3d(vc->rv3d); |