Sergey Sharybin
42fde5d32b
Fix memory leak when duplicating particles
2018-06-26 11:31:28 +02:00
Dalai Felinto
d6ac293bd4
Cleanup: comment
2018-06-26 11:07:29 +02:00
Sergey Sharybin
cfb50463be
Free crash when freeing object caches from duplicator
2018-06-26 10:53:05 +02:00
Sergey Sharybin
540b99bd28
Cycles: Free evaluated meshed when we are done with object
2018-06-25 17:28:46 +02:00
Brecht Van Lommel
c2110213ca
Physics: update softbody and dynamic paint to get colliders from depsgraph.
...
Because looping over the scene is unsafe and slow.
2018-06-25 17:15:07 +02:00
Brecht Van Lommel
2c9b32949b
Cleanup: refactor depsgraph physics API functions.
2018-06-25 17:15:07 +02:00
Bastien Montagne
eefe878660
Fix T55360: marker-based Camera switch focal length bug.
...
Scene was missing DEG tag update when its camera was changed based on
active 'camera marker'.
2018-06-25 16:21:24 +02:00
Brecht Van Lommel
38d6e82d1a
Fix use of non-evaluated collision and effector objects.
...
Only enabled objects in the view layer should be used, while temporarily
hidden objects should still have an effect.
2018-06-25 14:11:55 +02:00
Brecht Van Lommel
817bf582c2
Cleanup: rename object base flags to be more clear.
2018-06-25 14:09:17 +02:00
Brecht Van Lommel
a99dcab148
Depsgraph: cache collision relations, for performance and stability.
...
Same reasoning as effector relations in earlier commit.
2018-06-25 13:35:41 +02:00
Bastien Montagne
5b3ff9f7d8
Cleanup: Move colorband handling from DM to mesh_runtime universe.
2018-06-25 13:04:24 +02:00
Campbell Barton
29c1069244
Cleanup: code style
2018-06-25 12:06:51 +02:00
Sybren A. Stüvel
c448c0a67f
RigidBody: Replaced 'if' with 'switch'
2018-06-25 11:24:55 +02:00
Sybren A. Stüvel
eb56ca3119
Rigid body: compute looptris on original mesh instead of CoW copy
2018-06-25 11:20:06 +02:00
Dalai Felinto
1099ac1ed9
Silence warning for release builds
2018-06-25 11:02:19 +02:00
Campbell Barton
a5b7f1ef53
UI: internal changes to user-menu storage
...
- Use per context menu lists to support menu editing.
- Support for different kinds of menu items since this may be needed
in the future. Only use operator types for now.
2018-06-24 20:06:30 +02:00
Clément Foucault
6454319033
Lamps: Make default size more usable
...
This way the area light shapes are more visible (and usable) by default.
Changes were discussed with @venomgfx
2018-06-24 15:03:10 +02:00
Campbell Barton
85c1e61375
UI: Add user defined context menu
...
- Add/Remove from RMB context menu.
- Stored in user preferences.
- Access from Q key.
See T55027.
2018-06-23 20:52:47 +02:00
Campbell Barton
2d7606daa5
Missed last commit
2018-06-22 19:25:38 +02:00
Brecht Van Lommel
cc4dc2dce2
Depsgraph: cache effector relations, for performance and stability.
...
To find all effectors in the scene, we need to loop over all objects.
Doing this during depsgraph evaluation caused crashes because not all
objects are guaranteed to be evaluated yet.
To fix this, we now cache the relations as part of the dependency graph
build. As a bonus this also makes evaluation faster for big scenes,
since looping over all objects for each particle system is slow.
Fixes T55156.
2018-06-22 17:57:22 +02:00
Bastien Montagne
122e0105e2
Port DM_debug stuf to BKE_mesh_runtime.
2018-06-22 17:55:48 +02:00
Bastien Montagne
bf0dc7ee19
Cleanup: use standard BKE_object_free_derived_caches in BKE_mesh_to_curve.
...
...Instead of doing own dirty/risky version of the same thing!
2018-06-22 16:59:38 +02:00
Bastien Montagne
b1e86ff385
Cleanup: misc DrivedMesh stuff.
2018-06-22 16:59:38 +02:00
Sergey Sharybin
888fb065a4
Modifiers: Remove remaining parts of md->scene
2018-06-22 15:12:03 +02:00
Sergey Sharybin
7a4b784909
Subsurf: Move away from using scene from modifier data
2018-06-22 15:12:03 +02:00
Sergey Sharybin
fffe34531d
Cloth: Move away from scene stored in cloth modifier data
2018-06-22 15:12:03 +02:00
Sergey Sharybin
c2fa82e7a4
Multires: Move away from using scene from modifier data
2018-06-22 15:12:03 +02:00
Jeroen Bakker
dfca352294
StudioLight: Better API
...
In stead of a single refresh function that re-init the whole system. The
API now supports adding and removing. Which will be much faster and less
flickering of missing icons when adding/removing lights
2018-06-22 14:49:49 +02:00
Sergey Sharybin
f4d6e66b25
Merge branch 'master' into blender2.8
2018-06-22 14:42:25 +02:00
Sergey Sharybin
6cd0484de8
CMake: Make language explicit for per-file strict flags removal
2018-06-22 14:40:00 +02:00
Bastien Montagne
646412004b
Merge branch 'master' into blender2.8
...
Conflicts:
source/blender/makesrna/intern/rna_image.c
source/blender/makesrna/intern/rna_object.c
source/blender/makesrna/intern/rna_object_force.c
source/blender/makesrna/intern/rna_screen.c
source/blender/makesrna/intern/rna_sculpt_paint.c
source/blender/makesrna/intern/rna_space.c
source/blender/python/bmesh/bmesh_py_types.c
source/blender/python/generic/bpy_internal_import.h
source/blender/python/intern/bpy_rna_anim.c
source/blender/python/intern/gpu_offscreen.c
2018-06-22 12:46:16 +02:00
Jeroen Bakker
b6b7c83dd8
StudioLight: Only apply windowing when SH level is 2
...
It does not make much sense for the other levels
2018-06-22 12:37:03 +02:00
Jeroen Bakker
e402c36388
Studiolight: Spherical Harmonics Windowing
...
Apply Windowing on the Spherical Harmonics result. This would lead to
better results.
2018-06-22 12:31:19 +02:00
Bastien Montagne
101fd7ec06
Tweak new BKE_id_is_in_global_main to accept NULL pointer (and consider them as valid).
2018-06-22 12:26:45 +02:00
Sergey Sharybin
bcdec63570
Fix harmless use of unintialized memory
...
Still nbice to avoid such access to keep valgrind output more sane.
2018-06-22 12:08:18 +02:00
Sergey Sharybin
e6e2e9c246
Cleanup, spelling
2018-06-22 12:08:18 +02:00
Bastien Montagne
1870a1adc7
BKE_library: Add func to check an ID is actually in G_MAIN database.
2018-06-22 11:37:08 +02:00
Campbell Barton
2e80279a75
Fix T55547: "Fit camera to selected" fails
2018-06-22 07:55:49 +02:00
Bastien Montagne
31d916210c
Cleanup: remove DM from 'join as shape' operator.
...
Also deduplicated the 'mesh as shapekey' code, we had kind of two funcs
doing the same thing here...
2018-06-21 18:26:12 +02:00
Sergey Sharybin
6427141f7b
Modifiers: Stop using md->scene in isDisabled() callback
...
This is first commit in series of changes to get rid of md->scene.
2018-06-21 18:04:05 +02:00
Brecht Van Lommel
991d4f1c6b
Fix incorrect use of G.is_rendering for particles in some places.
2018-06-21 17:08:42 +02:00
Bastien Montagne
b80cce2053
Cleanup: names: data transfer/mesh remap: dm -> me/mesh.
...
That area is now officially purged from the Devil.. errr... DerivedMesh!
2018-06-21 15:33:10 +02:00
Bastien Montagne
ef90a8e12c
Cleanup: data transfer: get rid of dual destination mesh.
...
Not needed anymore, we only actually need to know wether it's orig mesh
or eval one in a few places...
2018-06-21 15:33:10 +02:00
Bastien Montagne
1859215576
Cleanup: some potentially critical changes in data transfer.
...
Removing that stuff should be valid with new depsgraph/modifiers stack
evaluation system... BUT it might not be, so rather have those in
separate own well-isolated commit.
2018-06-21 15:33:10 +02:00
Bastien Montagne
fffff5a993
Cleanup: nuke DM out of data transfer code.
...
This was actually rather hairy, this code is huge and complicated, easy
to make mistakes...
Good thing is, it will allow for significant simplification and more
(name) cleanup in following commits ;)
2018-06-21 15:33:10 +02:00
Brecht Van Lommel
8534ce9384
Revert "Objects: when active object gets hidden, make it inactive."
...
This reverts commit fec97ec949 , it's useful to be able to edit object
properties for hidden objects. The issue with mode locking that this
was meant to solve will be handled in another way.
2018-06-21 15:04:33 +02:00
Jeroen Bakker
00d52376f7
CodeStyle: Comments
2018-06-21 09:22:34 +02:00
Jeroen Bakker
e60d4d6a0c
Code cleanup: Added newline
2018-06-21 09:05:31 +02:00
Jeroen Bakker
54c4a107b1
Missed warning is previous commit
2018-06-21 09:04:03 +02:00
Jeroen Bakker
032c741214
Studiolight: Calculation of irradiance buffer
...
The calculation of the irradiance buffer was slow. Now it is only
calculated when it is being used (background_alpha > 0.0)
this solves the freeze when switching to LookDev mode.
Also changed the default calculation to use the Spherical Harmonics
calculation. This is able to generate the irradiance buffer fast, but is
less accurate. As the irradiance buffer is only used for visual
guidance speed is more important than accuracy.
Added compile directive to switch between the implementations.
(see STUDIOLIGHT_IRRADIANCE_METHOD)
Disabled caching the irradiance buffer when
STUDIOLIGHT_IRRADIANCE_METHOD_SPHERICAL_HARMONICS is used as it is not
needed.
2018-06-21 09:02:12 +02:00