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:
authorCampbell Barton <ideasman42@gmail.com>2013-05-08 17:00:52 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-05-08 17:00:52 +0400
commit562ed2b42e7ad8298bd5f041124ed2208c3a7a7c (patch)
treec006fdb389d4596ffa6eddb6ac0ffc670cb192bf /source/blender/editors/space_view3d/view3d_project.c
parenta4634bfe6725be8c1d56588d2f1660ee08cb11ad (diff)
add in asserts when rv3d->viewmatob, rv3d->persmatob are not initialized.
This is often hard to spot since in many cases it works correctly even when not initialized but may still fail in other situations.
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_project.c')
-rw-r--r--source/blender/editors/space_view3d/view3d_project.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/space_view3d/view3d_project.c b/source/blender/editors/space_view3d/view3d_project.c
index 4be4328d6c3..b9d24b248da 100644
--- a/source/blender/editors/space_view3d/view3d_project.c
+++ b/source/blender/editors/space_view3d/view3d_project.c
@@ -237,6 +237,7 @@ eV3DProjStatus ED_view3d_project_short_global(const ARegion *ar, const float co[
eV3DProjStatus ED_view3d_project_short_object(const ARegion *ar, const float co[3], short r_co[2], const eV3DProjTest flag)
{
RegionView3D *rv3d = ar->regiondata;
+ ED_view3d_check_mats_rv3d(rv3d);
return ED_view3d_project_short_ex(ar, rv3d->persmatob, true, co, r_co, flag);
}
@@ -250,6 +251,7 @@ eV3DProjStatus ED_view3d_project_int_global(const ARegion *ar, const float co[3]
eV3DProjStatus ED_view3d_project_int_object(const ARegion *ar, const float co[3], int r_co[2], const eV3DProjTest flag)
{
RegionView3D *rv3d = ar->regiondata;
+ ED_view3d_check_mats_rv3d(rv3d);
return ED_view3d_project_int_ex(ar, rv3d->persmatob, true, co, r_co, flag);
}
@@ -263,6 +265,7 @@ eV3DProjStatus ED_view3d_project_float_global(const ARegion *ar, const float co[
eV3DProjStatus ED_view3d_project_float_object(const ARegion *ar, const float co[3], float r_co[2], const eV3DProjTest flag)
{
RegionView3D *rv3d = ar->regiondata;
+ ED_view3d_check_mats_rv3d(rv3d);
return ED_view3d_project_float_ex(ar, rv3d->persmatob, true, co, r_co, flag);
}