Commit Graph

87354 Commits

Author SHA1 Message Date
Clément Foucault 0b88cd5032 DRW: Change function orders to improve CPU cache efficiency
These changes seems to impact cache efficiency as it uses shgroup just
after creating a DRWCall before shgroup.
2019-05-08 17:52:48 +02:00
Clément Foucault 6df7946f73 Object Overlay: Add dupli fast path 2019-05-08 17:52:48 +02:00
Clément Foucault 9bfdc4826a Wireframe: Create dupli fast path using DRW_duplidata_get 2019-05-08 17:52:48 +02:00
Clément Foucault b6b3a57c22 DRW: Add DRW_duplidata_get to create fast path for duplis
This is in order to create less shading group when using duplis.

Data for dupli objects keep in draw manager state until the source object
changes so retrieval is fast.

Note that this system could be extended to all meshes.
2019-05-08 17:52:48 +02:00
Clément Foucault 1ae2385106 GPUViewport: Fix possible hash colision with enabled engines
Also fix engine data validation that was not previously not working.
2019-05-08 17:49:28 +02:00
Clément Foucault ac2e23c739 DRW: Remove uneeded calls to drw_viewport_engine_data_ensure when iterating
This remove a bit of overhead specially in scene with lots of objects.
2019-05-08 17:49:28 +02:00
Clément Foucault 820a64b9e5 DRW: Replace BLI_mempool by BLI_memblock
This remove a avoid the big overhead present in BLI_mempool when it is
cleared.
2019-05-08 17:49:28 +02:00
Clément Foucault 9fea65a93d DRW: Speedup: Don't call GPU_shader_uniform_vector if not needed
This seems to remove a bit of overhead of going into the function even if
the uniform is not needed.
2019-05-08 17:49:28 +02:00
Clément Foucault 45caba3733 BLI_memblock: New memory allocator
This is really close to BLI_mempool but uses an array to keep track of the
chunks of memory. There is no tagging necessary to clear the whole
structure so reuse is fast.

Naturally supports iteration but does not support freeing.
2019-05-08 17:49:27 +02:00
Jeroen Bakker f273141556 Fix T64302: objects disappearing when disabling overlays
Only happened for Cycles, after recent changes.

Differential Revision: https://developer.blender.org/D4826
2019-05-08 16:55:43 +02:00
Brecht Van Lommel 5aaa00ed55 Revert "UI: Dynamic region size for file browser options"
This breaks the user interface of exporters, so revert for now until there
is a solution for this.

This reverts commit ee0d8426ab.
2019-05-08 16:55:43 +02:00
Alexander Gavrilov 58bfe93db6 Spline IK: fix a scaling hiccup as bones roll off the end of the curve. 2019-05-08 17:17:15 +03:00
Bastien Montagne 44d4fdec7e Fix T64266: Incorrect modifier object target after making duplicates real for instanced collections.
Not sure why newid was set in evaluated object instead of orig one,
makes no sense to me, since we want to operate remapping of ID pointers
on orig data? Looks like that was something overseen when that code was
ported to new COW system.
2019-05-08 15:54:39 +02:00
Jacques Lucke 3b9813fe50 UI: Move scrollbars to the right in animation editors
The text, that was in the scrollbars, stays on the left.

Reviewers: brecht, billreynish

Differential Revision: https://developer.blender.org/D4821
2019-05-08 15:16:05 +02:00
William Reynish adea6146f6 UI: Make File Browser bookmarks panels unparented again
Also open Recents again by default
2019-05-08 15:07:07 +02:00
William Reynish 503ced78f3 Keymap: Make Clip Editor Graph view consistent with regular Graph Editor
Still missing a context menu here for now though
2019-05-08 14:54:05 +02:00
Sergey Sharybin 4a98e33785 Fix heap buffer overflow in tabs to spaces
Need to count string terminator.
2019-05-08 14:37:05 +02:00
Jacques Lucke c79fc710b3 Keymap: Special keymap for clip editor scrubbing area
Reviewers: sergey

Differential Revision: https://developer.blender.org/D4825
2019-05-08 14:10:09 +02:00
Howard Trickey 6950faa24e Normals Menu: fix Average to be able to specify type.
Also removed some rogue debugging printfs from normal selection code.
2019-05-08 07:44:15 -04:00
William Reynish ebf924e0b7 Keymap: Drag in empty area to box select in animation editors
This is a patch for the default keymap in Blender.
It relates to the Dopesheet, Timeline, Graph Editor, NLA and Sequencer
Currently, in these editors, dragging outside of your selections does nothing.

This patch makes it so dragging outside the selection does a box select operation.
It is consistent with how the Node Editor works, as well as the 3D View, if you use the gizmo overlays.

Differential Revision: https://developer.blender.org/D4799

Reviewers: campbellbarton
2019-05-08 13:11:04 +02:00
Bastien Montagne 0d43d0bcab CMake: Add support of Ninja's pools to ease building on limited amount of RAM.
Many modern computers support a lot of threads (parrallel building
jobs), but are somewhat restricted in memory, when some building jobs
can require several GB each.

Ninja builder has pools, which extend the usual `-j X` make
parallelizing option, by allowing to specify different numbers of
parallel jobs for different targets.

This commit defines three pools, one for linking, one for usual compile,
and one for compiling some 'heavy' cpp libs, when a single file can
require GB of RAM in full debug builds.

Simply enabling WITH_NINJA_POOL_JOBS will try to set default sensible
values for those three pools based on your machine specifications, you
can then tweak further the values of NINJA_MAX_NUM_PARALLEL_ settings,
if you like.

On my system (8 cores, 16GB RAM), it allows to build a full debug with
all ASAN options build with roughly 7GB of RAM used at most, pretty much
as quickly as without that option (which would require up to 11GB of
available RAM at some points).

Review task: D4780.
2019-05-08 11:54:17 +02:00
Alexander Gavrilov 27b9a0cd67 Copy Scale: support raising the copied scale to an arbitrary power.
Since scale is multiplicative, the appropriate way to partially copy
it is to use power. However, the influence slider of constraints uses
linear interpolation. Thus, there is no way to correctly split scale
via constraints without adding this feature.

In addition, this allows inverting scale by using negative powers,
fulfilling the function of Copy Rotation's Invert checkboxes.
2019-05-08 12:17:00 +03:00
Sybren A. Stüvel 08012ebeec Disable Constraint and Keep Transform
A 'Disable and Keep Transform' button for constraints was added. This
allows animators to disable a constraint without moving the constrained
object/bone, making it easier to toggle constriants on and off without
any visual consequence. Typical usage would be a character picking up an
object (enable 'Copy Transform' constraint) and placing it somewhere
else (disable the constraint).

Note that there could still be movement when there are muliple
constraints active. For example, when using this constraint stack

- #1: Copy Transform from Empty.001
- #2: Copy Rotation from Empty.002

and disabling constraint #2, constraint #1 is still active and will
still modify the visual transform of the object. According to our
in-house animators, this is expected behaviour.

Reviewers: campbellbarton, dfelinto, sergey

Reviewed By: campbellbarton

Subscribers: brecht

Tags: #animation

Differential Revision: https://developer.blender.org/D4677
2019-05-08 10:57:17 +02:00
Sergey Sharybin 951396a9bd Fix T64274: Crash with more than 1 subdivision with the Multiresolution Modifier
Update more relevant fields in the sculpt session. Really becoming annoying, but
was also annoying in the old code as well.
2019-05-08 10:42:21 +02:00
Jacques Lucke 8287f31876 Fix T64298: Overlapping scrubbing area in clip editors dopesheet 2019-05-08 10:29:17 +02:00
William Reynish 01555d29fa UI: Remove Filters toggle in the Clip Editor Graph view
This was trying to emulate the 2.79 Graph Editor.

The toggle took up more room that the filter toggle it revealed, and it made the header buttons jump around

Better to just have the filter toggles showing immediately.
2019-05-08 09:10:29 +02:00
Campbell Barton 370345573e Cleanup: tabs to spaces for generated theme
Update along with generation utility.
2019-05-08 17:06:35 +10:00
Campbell Barton 700c69ad08 Fix T64283: Gizmo doesn't update after click-extrude 2019-05-08 15:14:23 +10:00
Campbell Barton f8def6db50 Cleanup: unused var, doxy syntax for math_matrix.c 2019-05-08 09:33:06 +10:00
William Reynish 3dc9da3a74 Fix: default keymap entry for Sequencer context menu
Own mistake in previous commit
2019-05-07 21:17:11 +02:00
William Reynish d4ea2df603 UI: Add copy/paste icons to Sequencer context menu 2019-05-07 21:12:22 +02:00
William Reynish bea5d9db84 UI: Add initial context menu to Sequencer
Add to both Blender and Industry Compat keymap
2019-05-07 21:07:52 +02:00
William Reynish 9b4a57f74c UI: Add copy/paste icons to Graph and Dopesheet editor context menus
Consistent with others
2019-05-07 20:52:41 +02:00
William Reynish 0c0254018c UI: Add initial context menu to NLA
Adding to both default and Industry Compat keymap
2019-05-07 20:49:53 +02:00
Alexander Gavrilov 37eb109014 Spline IK: support using both original scaling and volume preservation.
Add a new option that makes the Spline IK solver apply volume
preservation on top of the original scaling, considering the
pre-IK scale of the bone as the goal volume to be preserved.

This basically works similar to the Stretch To constraint, and
allows easily rigging a stretchy chain that uniformly follows
its parent's scaling.

Since the Stretch To behavior is more familiar, the new option
is on by default for newly created Spline IK constraints.
2019-05-07 19:54:36 +03:00
William Reynish b1a7711718 UI: Remove redundant titles in animation filter popover
It's clear what these do without and takes up much less space
2019-05-07 18:09:15 +02:00
Sebastian Parborg 50889ba6ef Implement Push/Relax from rest pose.
Perviously it was only possible to interpolate from the breakdown poses.
Now you can Push/Relax in regard to the rest pose as well.

For this only one keyframe is needed while the old modes needs two.
2019-05-07 17:37:05 +02:00
Brecht Van Lommel f08ee1fc40 Tests: add Cycles image texture colorspace tests 2019-05-07 17:26:27 +02:00
Brecht Van Lommel 109ef278cc Fix deadlock in recent Cycles colorspace changes
This code is not used yet so didn't affect anyone.
2019-05-07 17:26:27 +02:00
Sergey Sharybin 0d29a4fa7a Fix compilation error 2019-05-07 17:23:50 +02:00
Sergey Sharybin a488a21f4f Fix T64257: Scrubbing in the Clip Editor Graph Editor doesn't work
While intent of such action is not very clear, there is no real
reason to forbid it.
2019-05-07 17:08:06 +02:00
William Reynish 9c41ff4d46 Industry Compat keymap: Support for dragging markers in marker region
Now that there is a dedicated scrubbing area, the markers area can be used again for manipulating markers on drag.
2019-05-07 16:16:45 +02:00
William Reynish 2eb217b155 Keymap: Use right-click for context menus in the animation editors
- This only applies to left click select. Right click select and the legacy keymap are unaffected
  - You can still set the playhead from anywhere, using Shift-RMB, just like how you set the cursor in the 3D View
2019-05-07 16:12:17 +02:00
Pablo Vazquez c04e4b1974 UI: Rename "Scrubbing Region" to "Scrubbing/Markers Region".
Share theme setting since they serve similar purposes by sitting on top/bottom
of the animation/vse editors.

Reviewers: billreynish
2019-05-07 16:00:10 +02:00
Pablo Vazquez 76c6f38ae4 UI: Use scrubbing theme setting for markers background.
The hard-coded transparency of just 16 made it hard to see the markers
when the background was busy with keyframes (or strips in VSE).

The rename of the setting is in the following commit.

Reviewers: billreynish
2019-05-07 15:59:57 +02:00
Howard Trickey cbcc2c22d9 Fix Bevel T64107 - width/depth value wrong for vertex only.
Code fix from George Vogiatzis (Gvgeo), via D4811.
Needed to initalize vert_axis.
2019-05-07 09:28:34 -04:00
Jacques Lucke f2b7582b27 UI: Animation editor scrubbing area
The main reason for this change is to allow setting the
active frame with the left mouse button, while still being
able to select e.g. keyframes with the same mouse button.

The solution is to introduce a new scrubbing region with
a specialized keymap. There are a couple of related todos,
that will be handled in separate commits.
Those are listed in D4654.

This solves T63193.

Differential Revision: https://developer.blender.org/D4654

Reviewers: brecht, billreynish
2019-05-07 15:09:14 +02:00
Howard Trickey e4669199bf Normals menu for face strength improved.
Now cascading menus in Mesh > Normals set and select face
strength with explicit choices of Weak / Medium / Strong.
2019-05-07 08:45:01 -04:00
Alexander Gavrilov c041e10c9a Depsgraph: provide more granularity to PoseBone property links.
Most properties aren't altered by the evaluation of the bone,
and can be read immediately from its input operation. B-Bone
properties can be evaluated at the last possible moment.

This provides more freedom in using drivers to connect bone
properties: for example, it is now possible to read raw local
transform values via drivers from a bone that depends on the
reader bone via constraints.
2019-05-07 15:00:38 +03:00
William Reynish 5968826562 Industry Compat Keymap: Allow panning and zooming while using the Knife tool
Previously you could only orbit.

Apparently the order of the keys in the modal keymap makes a big difference.

Thanks to users Znio.G and Oskar on Devtalk who provided this solution.
2019-05-07 13:52:31 +02:00