Commit Graph

60085 Commits

Author SHA1 Message Date
Sergey Sharybin
ca2484e090 Depsgraph: Remove function bindings with collections
Use single function to evaluate all the collections for the given view layer.

This way we avoid need to get scene ID sub-data. Similar to pchan index, this
allows us to avoid build-time scene expansion, which also simplifies update of
the scene datablock.

Well, sort of. There is still work to be done to get rid of build-time scene
datablock expansion, which includes:

- Need to pass view layer by index.

  Annoying part would be to get actual view layer for that index. In practice
  doing list lookup might not be such a bad idea, since such lookup will not
  happen very often, and it is unlikely to have more than handful of view
  layer anyway.

  Other idea could be to use view layer from evaluation context.
  Or maybe from depsgraph, which is supposed to be in the context. Can have
  some assert statements to make sure everything is good.

- Need to get id of base binding for flags flush.

  We can replace that with index-based lookup from an array created by view
  layer evaluation.

Reviewers: dfelinto

Differential Revision: https://developer.blender.org/D3141
2018-04-12 11:05:18 +02:00
Bastien Montagne
c1680902ac Fix again 'auto override' system.
Got lost in big undo refactor.

Note that this is probably (maybe) not how we want to have it in the
end, things like EditMode undo should probably not trigger this check?
2018-04-11 15:23:54 +02:00
Sybren A. Stüvel
9ec26c415a Merge branch 'master' into blender2.8 2018-04-11 15:07:03 +02:00
Sybren A. Stüvel
8aa6e4d50b Changed assertion of '..' in file browser entries
The previous assert assumed '..' is always there, which isn't necessarily
true (for example when in the root of an Asset Engine repository).

The new code asserts that if '..' is present it should be the first entry
(rather than forcing the first entry to be '..').
2018-04-11 15:06:42 +02:00
Philipp Oeser
5a3c146652 fix T54549: Vector Transform node in wrong nodeclass
the Vector Transform node was added to the "Vector" category in
nodeitems_builtins.py
but was using the "NODE_CLASS_CONVERTOR" internally (thus using e.g. the
'wrong' theme color)

thanx @dingto for review

Differential Revision: https://developer.blender.org/D3138
2018-04-11 14:14:31 +02:00
Campbell Barton
ce3adc090d Merge branch 'master' into blender2.8 2018-04-11 09:41:49 +02:00
Sybren A. Stüvel
a3a76bc0fe Explicitly specify which tag to use 2018-04-11 09:34:29 +02:00
Campbell Barton
c963488b5e Pose Mode: pass object to mode enter/exit
Also add lower level mode exit function
2018-04-11 09:21:01 +02:00
Campbell Barton
debe3011f6 Merge branch 'master' into blender2.8 2018-04-11 09:02:32 +02:00
Campbell Barton
32339a56f1 Cleanup: minor changes to pose-mode switching API
Prepare for multi-object pose mode
2018-04-11 08:53:59 +02:00
Campbell Barton
1b78f05b1c Merge branch 'master' into blender2.8 2018-04-10 20:17:56 +02:00
Campbell Barton
f55adabb3e Cleanup: remove unused flag 2018-04-10 20:13:31 +02:00
Clément Foucault
d7aa51a50c DRW: Deferred Shader Compilation: Don't recreate ogl context.
Only recreate ogl context if we cannot reuse the one of the previous thread.

Adding lots of shaders were recreating as many ogl context which was very
slow.
2018-04-10 19:30:23 +02:00
Sybren A. Stüvel
1bc8ebaa26 Formatting 2018-04-10 18:27:49 +02:00
Sybren A. Stüvel
48dc5c14d4 Fix crashing of EEVEE/Clay engines when importing an Alembic file
The dependency graph still isn't updated properly, so animated meshes don't
move in EEVEE/Clay, but at least Blender doesn't crash.
2018-04-10 18:24:24 +02:00
Clément Foucault
3dce5b2ef9 UI: Fix some drawing order issues. 2018-04-10 17:42:45 +02:00
Clément Foucault
04e363376b WM: Fix a crash (assert) when creating a new window.
This happened when creating a window with the cursor over the timeline area.
I still don't know exactly what happened but for a reason batches were not
reset in this case.
2018-04-10 17:42:45 +02:00
Clément Foucault
3cfca15b50 DRW: Hair: Use GWN_PRIM_LINE_STRIPS instead of LINES
This means fewer indices to store. That being said, it seems to be a little
slower because of the restart index. But that's in the case we would be
vertex bound, which is mostly never going to happen.
2018-04-10 17:42:45 +02:00
Clément Foucault
21a57ec29e BLF: Style: Fix bad casts.
This could have caused overflow issue.
2018-04-10 17:42:45 +02:00
Campbell Barton
8d1c21998a Merge branch 'master' into blender2.8 2018-04-10 16:15:30 +02:00
Campbell Barton
549d4a55ab Fix transform nearest axis check
Was mixing up global/local coords
2018-04-10 16:14:29 +02:00
Germano
71980945bc Draw Manager: Fix lazy compilation on certain hardware.
Before, the drawing functions sometimes froze with `AMD Radeon HD 7570M`.
2018-04-10 11:03:15 -03:00
Sergey Sharybin
6962119e7f Merge branch 'master' into blender2.8 2018-04-10 12:00:10 +02:00
Sergey Sharybin
5c3857b305 Depsgraph: Build relations for objects linked via pchan constraints
This is similar to previous fix for missing ID nodes, just the original
fix missed this part of change because it looked like it is already
happening.
2018-04-10 11:57:20 +02:00
Clément Foucault
a74e782f5b BLF: Fix broken shadows on certain hardware.
This was due to uninitialized texture space.
2018-04-10 10:26:09 +02:00
Bastien Montagne
814f143acf Fix T54423: Messages from RNA_property_editable_info() were not translatable. 2018-04-10 10:24:02 +02:00
Sergey Sharybin
bd76c88754 Depsgraph: Flush debug prints
Makes it more reliable to see what was updating last when
crash happens.
2018-04-10 09:54:27 +02:00
Mai Lavelle
c0ac908fe8 Fix crash when no object is active
Could happen when deleting the active object or opening an old file
2018-04-09 22:03:33 -04:00
Mai Lavelle
16b795cb95 Fix crash in graph editor id remapping
Dopsheet pointer isn't set...?
2018-04-09 21:40:52 -04:00
Julian Eisel
77e9193c23 Fix invalid context when refreshing popups
Patch D2759 by @raa, with minor edits by me.
2018-04-09 19:31:39 +02:00
Germano
8d9a5d5062 UI: Fix widget shader on certain compiler.
There was a crash with Intel(R) HD Graphics 4000.
2018-04-09 14:07:32 -03:00
Julian Eisel
7213553c84 UI: Clamp scrollbar offset to lower view boundaries
Fixes the "emtpy scrolling" glitch by clamping the scroller offset to
the boundary of the view when it's smaller than the previous.

Fixes T45197. Patch by @januz.

Differential Revision: D1580
2018-04-09 18:55:50 +02:00
Germano
4a656f5d16 GPU Shader: Cleanup: Remove unnecessary ";" 2018-04-09 13:45:57 -03:00
Germano
2a0dca4252 UI: Fix widget shader on certain compiler.
There was a crash with `Intel(R) HD Graphics 4000`.
Thanks to @fclem for the help and review.
2018-04-09 13:45:17 -03:00
Alexander Gavrilov
26a283deae Use the newer version of the bullet 6dof spring constraint for rigidbody.
The new constraint is slower and not backward compatible, but should
be better, especially in the damping side. The new constraint also
has a different valid range of the damping coefficient, and a limit
implementation that bounces instead of making the object stationary.

Reviewers: sergof

Differential Revision: https://developer.blender.org/D3125
2018-04-09 19:14:35 +03:00
Sybren A. Stüvel
c1a2f973da Merge branch 'master' into blender2.8 2018-04-09 15:44:28 +02:00
Sybren A. Stüvel
7e39d151d8 Added support for the WEBM/VP9 video codec
WEBM is the codec name, and VP9 is the encoder (the older encoder "VP8"
is less efficient than VP9).

WEBM/VP9 and h.264 both have options to control the file size versus
compression time (e.g. fast but big, or slow and small, for the same
output quality). Since WEBM/VP9 only has three choices, I've chosen to
map those to 3 of the 9 possible choices of h.264:

- BEST → SLOWER
- GOOD → MEDIUM
- REALTIME → SUPERFAST

The VERYSLOW and ULTRAFAST options give very little extra benefit.

Reviewed by: @Severin
2018-04-09 15:27:11 +02:00
Sybren A. Stüvel
39116a4340 Remove commented-out code 2018-04-09 15:26:12 +02:00
Brecht Van Lommel
d533b70b23 Fix build error with GCC, make depsgraph iterator compatible with C++. 2018-04-09 15:09:22 +02:00
Julian Eisel
867f96c234 Fix crash and invalid context when changing workspace
Caused by 1c24c04e60.
2018-04-09 13:19:19 +02:00
Campbell Barton
09ee3eb173 Merge branch 'master' into blender2.8 2018-04-09 12:44:25 +02:00
Campbell Barton
2872965652 Cleanup: avoid recalculating global center 2018-04-09 12:40:10 +02:00
Clément Foucault
3cb42e5917 GPU Codegen: Fix assert caused by GC of failled shaders. 2018-04-09 12:10:03 +02:00
Clément Foucault
020c4e19f2 BLF: Fix assert when drawing very small chars. 2018-04-09 12:10:03 +02:00
Brecht Van Lommel
209c5cebb0 Freestyle: use depsgraph to get geometry, instead of Blender Internal.
Some of the code is simpler because we use Blender's triangulation directly
instead of dealing with quads. Also some progress printing code was removed
because the depsgraph can not tell us the number of objects ahead of time.

Differential Revision: https://developer.blender.org/D3127
2018-04-09 11:21:14 +02:00
Clément Foucault
cf4041eb05 UI: Widgets: Fix text edit cursor not drawing.
Actually it was drawn before the widget. Flushing widget cache and
everything is fine again.
2018-04-08 18:54:34 +02:00
Clément Foucault
9960feb7e3 GPU Select: Remove warnings on Intel GPU.
- Disable scissor test for fast clear. This could lead to some issues but
   I cannot think of one and could not find one either.
 - Manually wait for queries to be available instead of making the driver
   wait and issue warnings.
2018-04-08 18:31:50 +02:00
Clément Foucault
fc6b69bedc UI: Perf: Use GWN_draw_primitive for drawing viewport textures. 2018-04-08 18:31:50 +02:00
Clément Foucault
0b06e73258 UI: Perf: Use GWN_draw_primitive for drawing triple buffers texture. 2018-04-08 18:31:50 +02:00
Clément Foucault
17aad5ad97 UI: Perf: View3D: Batch view infos BLF calls together. 2018-04-08 18:31:50 +02:00