Commit Graph

77357 Commits

Author SHA1 Message Date
Clément Foucault
a3773dcc4f Fix memleak with GPUhairs. 2018-06-07 18:43:10 +02:00
Bastien Montagne
80dcb2ced8 Cleanup: typo, and 0 -> false for booleans. 2018-06-07 18:36:16 +02:00
Clément Foucault
00233f5f78 Wireframe: Fix edges or non manifold meshes not showing.
This will show the associated edges to the vertices but that's the only
workaround I can think of right now.
2018-06-07 18:01:36 +02:00
Clément Foucault
f9ca750bdf Wireframe: Change / Optimize the limited wireframe visibility option.
This make the limited wireframe not a performance problem anymore.

However, this does change the number of edges displayed as the threshold
is now computed per vertex instead of per edges.

For this reason we extended (internaly) the range of the slider so that the
users can hide more edge.
2018-06-07 18:01:36 +02:00
Campbell Barton
3823287179 Merge branch 'master' into blender2.8 2018-06-07 17:08:55 +02:00
Campbell Barton
d274c64d22 WM: add support for drag events
This allows for a single key to be mapped to both release and drag,
useful for pie menus to share a key with a different action.
2018-06-07 17:06:01 +02:00
Campbell Barton
8dc33a81b0 Merge branch 'master' into blender2.8 2018-06-07 16:53:31 +02:00
Campbell Barton
df4525d1d9 Fix key repeat events resetting the click timer 2018-06-07 16:52:40 +02:00
Campbell Barton
f0815b1322 Merge branch 'master' into blender2.8 2018-06-07 16:45:34 +02:00
Campbell Barton
863e395ad8 Cleanup: trailing space for windowmanager 2018-06-07 16:43:52 +02:00
Sergey Sharybin
fcc5d7c29e Draw: Fix crash when tryign to get procedural textures with modifier disabled
Maybe disabled modifier check should be done higher in the call hierarchy.
2018-06-07 16:40:15 +02:00
Campbell Barton
64e0ab6a00 Merge branch 'master' into blender2.8 2018-06-07 16:32:40 +02:00
Sergey Sharybin
86aaa3efba Fix T55126: COW problem: there is an active object even if unselectable 2018-06-07 16:31:10 +02:00
Campbell Barton
e19686a35a WM: check for release instead of not pressed
Makes reasoning about events more predictable.
2018-06-07 16:19:59 +02:00
Bastien Montagne
819ad49d29 Cleanup: typo. 2018-06-07 16:02:55 +02:00
Bastien Montagne
1e4722eeab Merge branch 'master' into blender2.8
Conflicts:
	source/blender/editors/transform/transform_generics.c
2018-06-07 15:41:57 +02:00
Bastien Montagne
8a2db3ed21 Fix crash due to missing init of new bAnimContext bmain member in transform code.
From own previous G.main-busting commit.
2018-06-07 15:38:31 +02:00
Campbell Barton
d9d3e7778c Fix sculpt mode undo (COW update needed) 2018-06-07 15:15:54 +02:00
Campbell Barton
a3f520170c Merge branch 'master' into blender2.8 2018-06-07 14:58:57 +02:00
Campbell Barton
6242940639 Fix double free in dyntopo-sculpt mode undo 2018-06-07 14:54:09 +02:00
Clément Foucault
a16d835f7b Wireframe: Frustum cull them. 2018-06-07 14:50:01 +02:00
Sergey Sharybin
8366c3ecd8 Depsgraph: Ensure collections are up to date after modifications
Before that copied collection in copy-on-write were running out
of sync with original ones. This was causing crash with the
following scenario:

- Delete some objects from scene
- Add particle system to an object
- Change particle mode to Hair

Thanks Dalai for debug session! Pair programming ftw!
2018-06-07 14:41:29 +02:00
Sergey Sharybin
30ec94561c Depsgraph: Use more proper relations for scene relation 2018-06-07 14:41:29 +02:00
Campbell Barton
da8d33e2e3 Merge branch 'master' into blender2.8 2018-06-07 13:41:32 +02:00
Campbell Barton
5330f1c5d1 Fix sculpt assert on initialization 2018-06-07 13:39:49 +02:00
Clément Foucault
c63f804222 Armature: Fix flickering outline on planar custom bones. 2018-06-07 13:38:17 +02:00
Bastien Montagne
508e34d0bf Merge branch 'master' into blender2.8
Conflicts:
	source/blender/editors/animation/anim_deps.c
	source/blender/editors/animation/keyframing.c
	source/blender/editors/animation/keyingsets.c
	source/blender/editors/armature/pose_edit.c
	source/blender/editors/armature/pose_transform.c
	source/blender/editors/gpencil/gpencil_convert.c
	source/blender/editors/include/ED_anim_api.h
	source/blender/editors/include/ED_keyframing.h
	source/blender/editors/interface/interface_anim.c
	source/blender/editors/space_action/action_edit.c
	source/blender/editors/space_graph/graph_edit.c
	source/blender/editors/space_outliner/outliner_draw.c
	source/blender/editors/transform/transform_conversions.c
	source/blender/makesrna/intern/rna_armature.c
	source/blender/makesrna/intern/rna_pose.c
	source/blender/python/intern/bpy_rna_anim.c
	source/blenderplayer/bad_level_call_stubs/stubs.c
	source/gameengine/Converter/KX_BlenderSceneConverter.cpp
2018-06-07 13:04:16 +02:00
Clément Foucault
4e014727f6 Armature: Fix missing loose edges on custom bone shapes. 2018-06-07 12:58:23 +02:00
Dalai Felinto
3126f85d26 Fix T55062: Depsgraph: Crash with COW with EEVEE viewport
We now remove the shader for every update.

So at the moment the whole point of UBO (Uniform Buffer Objects) is that they
are more efficient than individual uniforms.

Next steps is a harmless refactor to stopping UBO from referring to original
data in the UBO, and simply copying it.

It would also be interesting to make the final shader more granular as far as
the library and required functions are concerned. Even if this doesn't impact
performance, it should give us smaller easy to debug shaders
(a simple shader now has > 5k lines!).

If performance for animated values is measureable slower after this commit we
can port the shader creation CPU side to the depsgraph - localizing the tree,
hashing, lookup, ...

Additionally we can stick to update the UBO when the material changes but not
its topology. This is very trick because of localized trees. So we will only
re-visit this if profiling hints at any benefit from it.
2018-06-07 12:56:34 +02:00
Bastien Montagne
b3a7a75a26 Cleanup: remove moar G.main usages.
Notes:
* Really need to address RNA setters case, end up adding way too much
G.main here these days... :/
* Added Main pointer into bAnimContext, helps a lot in anim code ;)
2018-06-07 12:48:29 +02:00
Sybren A. Stüvel
d1474371fa Fixed deadlock on viewlayer update when there are drivers
When calling the bpy.ops.poselib.apply_pose() operator from Python, Blender
would deadlock when the rig has drivers.

Similar BPy_{BEGIN,END}_ALLOW_THREADS calls were already in place in the
rna_Scene_update_tagged() function.
2018-06-07 12:37:55 +02:00
Pablo Vazquez
a867e63dd6 Rename "Viewport Display SSAO" sub-panel name to Screen Space Ambient Occlusion
Since it is already a sub-panel of Viewport Display anyway
2018-06-07 12:08:40 +02:00
Clément Foucault
cdbda1c3d8 GPUPass: Refactor gpupass caching system to allow fast gpumaterial creation.
This is part of the work needed to refactor the material parameters update.

Now the gpupass cache is polled before adding the gpumaterial to the
deferred compilation queue.

We store gpupasses in a single linked list grouped based on their hashes.
This is not the most efficient way but it can be improved upon later.
2018-06-07 12:02:42 +02:00
Sergey Sharybin
366ac88d68 Merge branch 'master' into blender2.8 2018-06-07 12:01:09 +02:00
Sergey Sharybin
16017178b2 Revert "Cycles: Cleanup: Don't use return on function returning void"
Not sure why exactly it is called a cleanup, the code was much more clear
and robust against possible missing return statements which are MANDATORY.

Missing return statement will:

- Cause two different BVH traversals to be run.

  Not is happening currently, but if more BVH layouts are added, it will
  become a problem.

- It is already causing assert() statements to fail, since functions are
  no longer returning when they are supposed to.

If there is any measurable reason to keep this change, let me know.
Otherwise just stick to reliable/tested/robust code.

This reverts commit ba65f7093b39a8e5f1fb869cbc347fb810a05ab9.
2018-06-07 11:57:57 +02:00
Sergey Sharybin
a54235e0c6 Particle mode: Support children drawing
The issue is that children drawing is done by object mode,
which operates with data from evaluated context. But that
data needs edit mode's cache to be properly updated first.
2018-06-07 11:31:56 +02:00
Sergey Sharybin
613faa0987 Draw: Don't take cache existence into account for draw type 2018-06-07 11:31:56 +02:00
Sergey Sharybin
72cfd5134b Draw: Use proper continue when psys is disabled 2018-06-07 11:31:56 +02:00
Sergey Sharybin
1aa89d9a1c Particle edit: Simplify code by benefiting from single edit context
Makes ADD brush to work.

At some point children particles draw got broken, children are not
visible for until first stroke is done. Still looking into it.
2018-06-07 11:31:56 +02:00
Bastien Montagne
df0253be33 Merge branch 'master' into blender2.8
Conflicts:
	source/blender/collada/ArmatureExporter.cpp
	source/blender/collada/ArmatureExporter.h
	source/blender/collada/DocumentExporter.cpp
	source/blender/collada/DocumentExporter.h
	source/blender/collada/SceneExporter.cpp
	source/blender/collada/SceneExporter.h
	source/blender/collada/collada.cpp
	source/blender/collada/collada.h
	source/blender/editors/armature/armature_edit.c
	source/blender/editors/armature/pose_transform.c
	source/blender/editors/include/ED_armature.h
	source/blender/editors/include/ED_object.h
	source/blender/editors/include/ED_screen.h
	source/blender/editors/io/io_collada.c
	source/blender/editors/object/object_transform.c
	source/blender/editors/screen/screen_edit.c
	source/blender/editors/screen/screen_ops.c
	source/blender/windowmanager/intern/wm.c
	source/blender/windowmanager/intern/wm_files.c
	source/blender/windowmanager/intern/wm_window.c
	source/blenderplayer/bad_level_call_stubs/stubs.c
2018-06-07 11:23:26 +02:00
Bastien Montagne
54f9cd5283 Cleanup: Nuke moar G.main usages... 2018-06-07 11:11:46 +02:00
Bastien Montagne
e27759152a Minor comment on possible TODO while validating paint ops for CoW... 2018-06-07 10:59:21 +02:00
Sybren A. Stüvel
e43065596b Alembic export: CoW/Depsgraph fixes 2018-06-07 10:48:52 +02:00
Sybren A. Stüvel
d88314ee5b Alembic export: port DerivedMesh → Mesh 2018-06-07 10:48:52 +02:00
Sybren A. Stüvel
5b0f96f97c Alembic import: port DerivedMesh → Mesh 2018-06-07 10:48:52 +02:00
Jeroen Bakker
f447411a82 Bone selection: user control contrast
Experiment: let the user be in control of the alpha channel as some rigs
are hard too see during bone selection. Especially rigs that were
designed for 2.79 wireframe mode.
2018-06-07 09:26:06 +02:00
Jeroen Bakker
7fb216d800 Workbench: respect the duplication visibility flag 2018-06-07 09:26:06 +02:00
Campbell Barton
2d2f23de10 Fix T55348: Renaming a marker can't cancel
Regression in a14005c070a1f
2018-06-07 08:54:47 +02:00
Campbell Barton
a60d4f33c6 Merge branch 'master' into blender2.8 2018-06-07 08:15:11 +02:00
Campbell Barton
409cfba1a3 Python API: Initial 'imbuf' API
Support only basic operations new/load/write & resize.

Add now so we can extend as needed & more easily accept patches.
2018-06-07 08:00:13 +02:00