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:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2019-09-17 14:37:43 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2019-09-17 14:43:00 +0300
commitc25f5a375e6c7469ee55a300a92eac362a46f697 (patch)
treeac9fb58549a9949516cf989a39da96dc28a8d480
parent8f662e84e0b49a581f9330bf1c560e62485b3f6a (diff)
Fix T61313: gravity not displayed correct when changing unit scale
Display of velocity and acceleration units should be affected by unit scale. Arguably the behavior of the physics simulation should be for gravity to remain constant, but such design changes are outside the scope of bug fixing. At least the UI should correctly reflect what the physics simulation will do.
-rw-r--r--source/blender/blenkernel/intern/scene.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c
index faf3d12fdad..4f855bd7d98 100644
--- a/source/blender/blenkernel/intern/scene.c
+++ b/source/blender/blenkernel/intern/scene.c
@@ -1674,6 +1674,8 @@ double BKE_scene_unit_scale(const UnitSettings *unit, const int unit_type, doubl
switch (unit_type) {
case B_UNIT_LENGTH:
+ case B_UNIT_VELOCITY:
+ case B_UNIT_ACCELERATION:
return value * (double)unit->scale_length;
case B_UNIT_AREA:
case B_UNIT_POWER: