blender.git
2 years agoMerge branch 'master' into blender2.8
Brecht Van Lommel [Tue, 30 Oct 2018 13:13:47 +0000 (14:13 +0100)]
Merge branch 'master' into blender2.8

2 years agoGP: Back Stroke projection mode
Antonioya [Tue, 30 Oct 2018 11:59:36 +0000 (12:59 +0100)]
GP: Back Stroke projection mode

Back the old 2.7x  stroke mode when drawing. This mode try to project the new strokes over the previous strokes.

2 years agoGP: Cleanup unused
Antonioya [Tue, 30 Oct 2018 11:53:08 +0000 (12:53 +0100)]
GP: Cleanup unused

2 years agoGPU: Extend mac blitting workaround to AMD Radeon R9 familly
Clément Foucault [Tue, 30 Oct 2018 12:01:25 +0000 (13:01 +0100)]
GPU: Extend mac blitting workaround to AMD Radeon R9 familly

2 years agoFix build error on Windows 32bit, alignment was wrong.
Brecht Van Lommel [Tue, 30 Oct 2018 10:39:44 +0000 (11:39 +0100)]
Fix build error on Windows 32bit, alignment was wrong.

2 years agoAdd 'O' for Overrides to our key-coded ID UI-names generator.
Bastien Montagne [Tue, 30 Oct 2018 09:59:49 +0000 (10:59 +0100)]
Add 'O' for Overrides to our key-coded ID UI-names generator.

2 years agoAdd library-hint to datablock search menus.
Bastien Montagne [Tue, 30 Oct 2018 09:54:02 +0000 (10:54 +0100)]
Add library-hint to datablock search menus.

We had those for ID templates, but it's also tremendously useful for
regular ID pointers UI, since often you can get local and linked
data-block with same exact name...

Fetaure request from Spring team (and long due TODO...).

2 years agoGPU: Fix faulty mac gpu detection
Clément Foucault [Tue, 30 Oct 2018 10:02:49 +0000 (11:02 +0100)]
GPU: Fix faulty mac gpu detection

2 years agoPyAPI: Use 'None' arg to clear header text
Campbell Barton [Tue, 30 Oct 2018 05:16:41 +0000 (16:16 +1100)]
PyAPI: Use 'None' arg to clear header text

2 years agoPyAPI: Support for 'None' string args from Python
Campbell Barton [Tue, 30 Oct 2018 05:11:39 +0000 (16:11 +1100)]
PyAPI: Support for 'None' string args from Python

This is needed because some RNA functions differentiate a NULL 'char *'
argument from an empty string.

Previously a NULL argument could be passed when the C definition
defined the default as NULL and the argument wasn't passed
which is a fairly hidden way of handling things.

Now strings use `PROP_NEVER_NULL` by default
which can be cleared for function arguments that allow None -> NULL.

2 years agoMulti-Object EditMode: curve delete
Campbell Barton [Tue, 30 Oct 2018 03:10:36 +0000 (14:10 +1100)]
Multi-Object EditMode: curve delete

D3859 by @zazizizou

2 years agoSequencer: replace notifier /w message-bus
Campbell Barton [Tue, 30 Oct 2018 00:14:23 +0000 (11:14 +1100)]
Sequencer: replace notifier /w message-bus

2 years agoCleanup: keep RNA types sorted
Campbell Barton [Tue, 30 Oct 2018 00:06:19 +0000 (11:06 +1100)]
Cleanup: keep RNA types sorted

2 years agoFix memory leak in workspace menu
Campbell Barton [Mon, 29 Oct 2018 23:57:46 +0000 (10:57 +1100)]
Fix memory leak in workspace menu

2 years agoUI: add uiItemMenuFN which frees it's argument
Campbell Barton [Mon, 29 Oct 2018 23:46:29 +0000 (10:46 +1100)]
UI: add uiItemMenuFN which frees it's argument

2 years agoUI: add uiItemMenuFN which frees it's argument
Campbell Barton [Mon, 29 Oct 2018 23:46:29 +0000 (10:46 +1100)]
UI: add uiItemMenuFN which frees it's argument

2 years agoFix crash adding workspace
Campbell Barton [Mon, 29 Oct 2018 23:25:05 +0000 (10:25 +1100)]
Fix crash adding workspace

2 years agoUI: Support using Ctrl+Scrollwheel to cycle properties editor tabs
Julian Eisel [Mon, 29 Oct 2018 22:28:08 +0000 (23:28 +0100)]
UI: Support using Ctrl+Scrollwheel to cycle properties editor tabs

Small side effect is that area operators (toggle fullscreen/maximized, duplicate
area) are now displayed in RMB-menu. Makes sense anyway.

2 years agoUI: Move Properties editor context path into header
Julian Eisel [Mon, 29 Oct 2018 21:55:54 +0000 (22:55 +0100)]
UI: Move Properties editor context path into header

This will probably be a temporary solution to fill empty space, for until we
have a search button there. Hence, I made this optional using a compile flag.

2 years agoWM: correct description for header/status_text_set
Campbell Barton [Mon, 29 Oct 2018 21:55:36 +0000 (08:55 +1100)]
WM: correct description for header/status_text_set

Make text a required argument for both.

2 years ago3D View: use 1.0 opacity for wpaint shading
Campbell Barton [Mon, 29 Oct 2018 21:32:06 +0000 (08:32 +1100)]
3D View: use 1.0 opacity for wpaint shading

Now the colors are multiplied, faded color isn't useful to see weights.

Matches 2.7x behavior.

2 years agoEevee: Fix clearcoat materials not recieving AO
Clément Foucault [Mon, 29 Oct 2018 21:40:07 +0000 (22:40 +0100)]
Eevee: Fix clearcoat materials not recieving AO

2 years agoUI: Fix Studio Light panel in user preferencies
Clément Foucault [Mon, 29 Oct 2018 21:27:12 +0000 (22:27 +0100)]
UI: Fix Studio Light panel in user preferencies

2 years agoUI: Update Default Theme File After Recent Changes
Julian Eisel [Mon, 29 Oct 2018 20:47:27 +0000 (21:47 +0100)]
UI: Update Default Theme File After Recent Changes

2 years agoUI: Vertical Properties Editor Tabs
Julian Eisel [Mon, 29 Oct 2018 20:34:14 +0000 (21:34 +0100)]
UI: Vertical Properties Editor Tabs

Moves the Properties editor context switching to a vertical tabs region.

Design Task: T54951
Differential Revison: D3840

The tabs are regular widgets, unlike the 'old' toolshelf tabs. This means they
give mouse hover feedback, have tooltips, support the right-click menu, etc.
Also, when vertical screen space gets tight, the tabs can be scrolled, they
don't shrink like the toolshelf ones.
The tab region is slightly larger than the header. The tabs are scaled up
accordingly. This makes them nicely readable.

The header is quite empty now. As shown in T54951, we wanted to have a search
button there. This should be added next.

Implementation Notes:

* Added a new region type, RGN_TYPE_NAVIGATION.
* Having the tabs in a separate region allows scrolling of the tab-bar, unlike
  the toolshelf tabs. We might want to remove the scrollbars though.
* Added a new region flag RGN_FLAG_PREFSIZE_OR_HIDDEN, to ensure the tab region
  is either hidden or has a fixed size.
* Added some additional flags to support fine-tuning the layout in panel and
  layout code.
* Bumps subversion.

2 years agoUI: Support Displaying Enums as Tabs
Julian Eisel [Mon, 29 Oct 2018 20:20:58 +0000 (21:20 +0100)]
UI: Support Displaying Enums as Tabs

Adds `uiLayout.prop_tabs_enum(data, property, icon_only)` to BPY.

2 years agoDope Sheet: new option to display keyframe interpolation mode and extremes.
Alexander Gavrilov [Fri, 19 Oct 2018 15:55:19 +0000 (18:55 +0300)]
Dope Sheet: new option to display keyframe interpolation mode and extremes.

With the new automatic handle algorithm, it is possible to do a lot
of the animation via keyframes without touching the curves. It is
however necessary to change the keyframe interpolation and handle
types in certain cases. Currently the dopesheet/action editor
allows changing the types, but does not show them in any way.

To fix, add a new menu option to display this information. For handle
type, it is represented using the shape of the key icons: diamond for
Free, clipped diamond for Aligned, square for Vector, circle for Auto
Clamp, and cirle with dot for Automatic.

Non-bezier interpolation is a property of intervals between keys,
so it is marked by drawing lines, similar to holds. In this initial
version, only the fact of non-bezier interpolation is displayed,
without distinguishing types. For summaries, the line is drawn at
half alpha if not all curves in the group are non-bezier.

In addition, it is sometimes helpful to know the general direction
of change of the curve, and which keys are extremes. This commit
also adds an option to highlight extremes, based on comparing the
keyed values with adjacent keys. Half-intensity display is used
for overshot bezier extremes, or non-uniform summaries.

Reviewers: brecht, aligorith, billreynish

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

2 years agoUI: icon set updates Andrzej Ambroz, and various fixes.
William Reynish [Sun, 28 Oct 2018 16:51:40 +0000 (17:51 +0100)]
UI: icon set updates Andrzej Ambroz, and various fixes.

* Text editor word wrap, line numbers & syntax toggles now use consistent icons
  that don’t change when you enable or disable them.
* Replaced icon toggle buttons in the snapping popover with normal checkboxes
  and descriptive text labels. This makes it clearer which item is the main
  radio button, is more consistent with other popovers, and allows us to use
  more descriptive text.
* Added correct icons for grease pencil add menu.
* Added bespoke icons for grease pencil modifiers.
* Added icon for particle instance modifier.
* Added icon for fake user on & off states.
* Added correct icons for enabling/disabling modifiers in the dopesheet &
  f-curve editor.
* Made it so the restrict viewport & restrict render toggles for modifier
  update correctly when enabled or disabled, by flipping the order in the
  icon sheet. This also required changing the outliner to match.
* Removed the few old remaining icons in the old style and made sure to replace
  the last places where they were used.
* Updated many icons to be clearer & more consistent.

2 years agoUI: allow off/on icons to be in reverse order.
Brecht Van Lommel [Mon, 29 Oct 2018 15:58:34 +0000 (16:58 +0100)]
UI: allow off/on icons to be in reverse order.

The same icons are reused for "hide" and "show" properties, which need
to be in reverse order compared to each other.

2 years agoCleanup: remove unused RNA flag.
Brecht Van Lommel [Mon, 29 Oct 2018 15:19:03 +0000 (16:19 +0100)]
Cleanup: remove unused RNA flag.

2 years agoDepsgraph: use full operation key to preserve update tags on rebuild.
Alexander Gavrilov [Mon, 29 Oct 2018 17:52:32 +0000 (20:52 +0300)]
Depsgraph: use full operation key to preserve update tags on rebuild.

The key used by find_operation consists of the operation code,
node name, and an index for array property drivers. All three
elements are required to unambiguously look up a node.

2 years agoFix T57488: crash in Shrinkwrap constraint due to unsafe multi-threading.
Alexander Gavrilov [Mon, 29 Oct 2018 17:30:31 +0000 (20:30 +0300)]
Fix T57488: crash in Shrinkwrap constraint due to unsafe multi-threading.

- Constraints must not use mesh_get_eval_final as it isn't thread-safe.
- Depsgraph should keep lastDataMask when re-running COW.

2 years agoGP: Remove unneeded code to get icon
Antonioya [Mon, 29 Oct 2018 16:49:26 +0000 (17:49 +0100)]
GP: Remove unneeded code to get icon

Test the object type is not good idea here.

2 years agoGP: Cleanup typo
Antonioya [Mon, 29 Oct 2018 15:42:47 +0000 (16:42 +0100)]
GP: Cleanup typo

2 years agoDepsgraph cleanup: use proper DEG_debug_print_eval call...
Bastien Montagne [Mon, 29 Oct 2018 15:37:00 +0000 (16:37 +0100)]
Depsgraph cleanup: use proper DEG_debug_print_eval call...

2 years agoBBox accessor: switch to `switch`, add missing gpencil case.
Bastien Montagne [Mon, 29 Oct 2018 11:06:27 +0000 (12:06 +0100)]
BBox accessor: switch to `switch`, add missing gpencil case.

2 years agoEevee: Fix Sun soft shadows not starting at first sample
Clément Foucault [Mon, 29 Oct 2018 15:02:13 +0000 (16:02 +0100)]
Eevee: Fix Sun soft shadows not starting at first sample

2 years agoEdit Mode: Fix "Hidden Wire" option not working
Clément Foucault [Mon, 29 Oct 2018 14:34:47 +0000 (15:34 +0100)]
Edit Mode: Fix "Hidden Wire" option not working

2 years agoCycles: Support generating Denoising passes without actually denoising
Lukas Stockner [Mon, 29 Oct 2018 14:45:58 +0000 (15:45 +0100)]
Cycles: Support generating Denoising passes without actually denoising

Needed for the animation denoiser since the denoising filter is done separately there.

Reviewers: brecht, sergey

Reviewed By: brecht

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

2 years agoUI: Typo in tooltip
Pablo Vazquez [Mon, 29 Oct 2018 13:43:12 +0000 (14:43 +0100)]
UI: Typo in tooltip

2 years agoFix: Pose Breakdown operator (continued)
Jacques Lucke [Mon, 29 Oct 2018 13:07:47 +0000 (14:07 +0100)]
Fix: Pose Breakdown operator (continued)

2 years agoFix: Pose Breakdown operator
Jacques Lucke [Mon, 29 Oct 2018 12:57:17 +0000 (13:57 +0100)]
Fix: Pose Breakdown operator

Reviewer: brecht

Differential Revision: D3848

2 years agoMerge branch 'master' into blender2.8
Brecht Van Lommel [Mon, 29 Oct 2018 12:26:09 +0000 (13:26 +0100)]
Merge branch 'master' into blender2.8

2 years agoCycles: more detailed tooltips for cryptomatte options.
Brecht Van Lommel [Mon, 29 Oct 2018 12:05:29 +0000 (13:05 +0100)]
Cycles: more detailed tooltips for cryptomatte options.

2 years agoEnable dependency graph update while rendering
Sergey Sharybin [Mon, 29 Oct 2018 11:16:18 +0000 (12:16 +0100)]
Enable dependency graph update while rendering

It is a whole point of copy-on-write to make such updates safe.
If this causes an issues, we need to solve them.

Fixes T57302: Viewport (selection etc) not updated while rendering

2 years agoFix unneeded/unwanted user counter when freeing CoW NLA
Sergey Sharybin [Mon, 29 Oct 2018 10:13:19 +0000 (11:13 +0100)]
Fix unneeded/unwanted user counter when freeing CoW NLA

2 years agoFix T57360: Crash when Play Animation in this scene
Sergey Sharybin [Mon, 29 Oct 2018 10:06:53 +0000 (11:06 +0100)]
Fix T57360: Crash when Play Animation in this scene

Was caused by a code which was putting animation value back to
original datablock.

The tricky part here is that we don't always know ID, so can not
put those values. Would be nice to have a solution for this, but
for until then we should be relatively good.

2 years agoFix T57372: Second full scene copy crashes on deletion.
Bastien Montagne [Mon, 29 Oct 2018 10:42:38 +0000 (11:42 +0100)]
Fix T57372: Second full scene copy crashes on deletion.

Hope this time we are done for good (root of the issue was that master
collections are not in bmain...).

2 years agoFix stupid multiple-call of same function in Collections remapping code.
Bastien Montagne [Mon, 29 Oct 2018 09:49:46 +0000 (10:49 +0100)]
Fix stupid multiple-call of same function in Collections remapping code.

Related to T57372: Second full scene copy crashes on deletion (fixes
deleting second copy, but now it crashes on deleting the first copy...).

2 years agoFix T57384: Depsgraph assert after loading file with Mask Node
Philipp Oeser [Fri, 26 Oct 2018 08:32:57 +0000 (10:32 +0200)]
Fix T57384: Depsgraph assert after loading file with Mask Node

Maniphest Tasks: T57384

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

2 years agoFix topbar UI being lost on undo w/ mode change
Campbell Barton [Mon, 29 Oct 2018 09:20:16 +0000 (20:20 +1100)]
Fix topbar UI being lost on undo w/ mode change

2 years agoFix topbar tool UI being lost on undo
Campbell Barton [Mon, 29 Oct 2018 06:32:15 +0000 (17:32 +1100)]
Fix topbar tool UI being lost on undo

Using operators to the object mode was resetting the tool.

See: T56865

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Mon, 29 Oct 2018 04:23:02 +0000 (15:23 +1100)]
Merge branch 'master' into blender2.8

2 years agoFix assert weight painting after undo
Campbell Barton [Mon, 29 Oct 2018 04:21:25 +0000 (15:21 +1100)]
Fix assert weight painting after undo

2 years agoMulti-Object EditMode: curve select next/prev
Campbell Barton [Mon, 29 Oct 2018 02:41:44 +0000 (13:41 +1100)]
Multi-Object EditMode: curve select next/prev

D3842 & D3843 by @zazizizou

2 years agoMulti-Object EditMode: curve select more/less
Campbell Barton [Mon, 29 Oct 2018 02:25:04 +0000 (13:25 +1100)]
Multi-Object EditMode: curve select more/less

D3844 by @zazizizou with support for select-less

2 years agoMerge branch 'master' into blender2.8
Campbell Barton [Mon, 29 Oct 2018 02:04:47 +0000 (13:04 +1100)]
Merge branch 'master' into blender2.8

2 years agoModifier: mask threshold option
Campbell Barton [Mon, 29 Oct 2018 02:01:48 +0000 (13:01 +1100)]
Modifier: mask threshold option

D3834 by @Allosteric

2 years agoCleanup: avoid C++ keyword in DNA
Campbell Barton [Mon, 29 Oct 2018 01:49:47 +0000 (12:49 +1100)]
Cleanup: avoid C++ keyword in DNA

2 years agoPyAPI: remove GPUVertFormat() creation from a list
Campbell Barton [Mon, 29 Oct 2018 00:08:55 +0000 (11:08 +1100)]
PyAPI: remove GPUVertFormat() creation from a list

We already have `attr_add` method,
best not have two ways to do the same thing.

See: D3830

2 years agoCleanup: typo
Campbell Barton [Sun, 28 Oct 2018 23:35:05 +0000 (10:35 +1100)]
Cleanup: typo

2 years agoCleanup: style
Campbell Barton [Sun, 28 Oct 2018 23:24:42 +0000 (10:24 +1100)]
Cleanup: style

2 years agoFix crash flipping region without active area
Julian Eisel [Sun, 28 Oct 2018 21:55:21 +0000 (22:55 +0100)]
Fix crash flipping region without active area

Would happen when cursor is in-between editors for example.

2 years agoDRW: Cleanup: Redundant check
Clément Foucault [Sun, 28 Oct 2018 20:46:52 +0000 (21:46 +0100)]
DRW: Cleanup: Redundant check

2 years agoEevee: Implement jittered soft shadowmap
Clément Foucault [Sun, 28 Oct 2018 20:41:40 +0000 (21:41 +0100)]
Eevee: Implement jittered soft shadowmap

This new option is located in the shadows options in the render settings.
This approach is simple and just randomize the shadow map position (not
the lamp itself) and just let the temporal supersampling do the average of
all the shadowing. The downside is that is needs quite a large number of
samples to give smooth results and individual sample position can remain
visible.

Enabling this option will make the viewport refresh all shadow maps every
redraw so it has a serious performance impact.

This approach is not physicaly based at all and will not match cycles.

----

The sampling for point lamps (spheres) is not

2 years agoBLI: Add comment about to orthogonalize_m3/4
Clément Foucault [Sun, 28 Oct 2018 18:27:14 +0000 (19:27 +0100)]
BLI: Add comment about to orthogonalize_m3/4

2 years agoEevee: Fix contact shadow creating to overshadowing
Clément Foucault [Sun, 28 Oct 2018 18:24:56 +0000 (19:24 +0100)]
Eevee: Fix contact shadow creating to overshadowing

This was because the shadow rays could be generated below the geometric
normal.

2 years agoUse keyword argument for ui label text in cryptomatte passes
Philipp Oeser [Sun, 28 Oct 2018 19:39:44 +0000 (20:39 +0100)]
Use keyword argument for ui label text in cryptomatte passes

2 years agoGP: Refactor Instance modifier and rename to Array
Antonioya [Sun, 28 Oct 2018 17:08:24 +0000 (18:08 +0100)]
GP: Refactor Instance modifier and rename to Array

The old name Instance was logic when the modifier created new object instances, but now works equal to mesh Array modifier, so the old name was not logic and must be Array.

Also added a Object to use as offset similar to mesh Array modifier.

2 years agoFix label misalignment when there are multiple buttons on the right side.
Brecht Van Lommel [Thu, 25 Oct 2018 13:27:31 +0000 (15:27 +0200)]
Fix label misalignment when there are multiple buttons on the right side.

2 years agoCleanup: fix compiler warnings.
Brecht Van Lommel [Sun, 28 Oct 2018 16:22:26 +0000 (17:22 +0100)]
Cleanup: fix compiler warnings.

2 years agoMerge branch 'master' into blender2.8
Brecht Van Lommel [Sun, 28 Oct 2018 15:41:30 +0000 (16:41 +0100)]
Merge branch 'master' into blender2.8

2 years agoFix snaps appearing in system bookmarks on Linux.
Roel Koster [Sun, 28 Oct 2018 12:03:50 +0000 (13:03 +0100)]
Fix snaps appearing in system bookmarks on Linux.

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

2 years agoFix Linux build after Cryptomatte commit.
Brecht Van Lommel [Sun, 28 Oct 2018 13:53:08 +0000 (14:53 +0100)]
Fix Linux build after Cryptomatte commit.

2 years agoFix T57394: missing bl_category in panel (custom props / stereoscopy)
Philipp Oeser [Fri, 26 Oct 2018 18:30:41 +0000 (20:30 +0200)]
Fix T57394: missing bl_category in panel (custom props / stereoscopy)

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

2 years agoCycles: Added Cryptomatte output.
Stefan Werner [Sun, 28 Oct 2018 09:37:41 +0000 (05:37 -0400)]
Cycles: Added Cryptomatte output.

This allows for extra output passes that encode automatic object and material masks
for the entire scene. It is an implementation of the Cryptomatte standard as
introduced by Psyop. A good future extension would be to add a manifest to the
export and to do plenty of testing to ensure that it is fully compatible with other
renderers and compositing programs that use Cryptomatte.

Internally, it adds the ability for Cycles to have several passes of the same type
that are distinguished by their name.

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

2 years agoCleanup: More meaningful variable name
Severin [Sat, 27 Oct 2018 15:12:51 +0000 (17:12 +0200)]
Cleanup: More meaningful variable name

2 years agoFix T57393: Cycles OSL bevel and AO not working after OSL upgrade.
Brecht Van Lommel [Fri, 26 Oct 2018 17:26:06 +0000 (19:26 +0200)]
Fix T57393: Cycles OSL bevel and AO not working after OSL upgrade.

2 years agoTool System: pie menu style activate-on-release
Campbell Barton [Sat, 27 Oct 2018 01:22:20 +0000 (12:22 +1100)]
Tool System: pie menu style activate-on-release

Support activate on release for the popup toolbar.

2 years agoUI: operator to press the active button
Campbell Barton [Sat, 27 Oct 2018 01:21:19 +0000 (12:21 +1100)]
UI: operator to press the active button

Needed to use the keymap to activate buttons from other keys.

2 years agoMulti-Objects: Curve - select pick, linked and short path
Dalai Felinto [Fri, 26 Oct 2018 22:54:11 +0000 (19:54 -0300)]
Multi-Objects: Curve - select pick, linked and short path

I'm following mesh editing to decide when to switch active object, or
deselect the other objects. I hope we can keep this all consistent in
the end.

2 years agoCleanup: Remove silly redundant if check in ED_armature_edit_select_pick
Dalai Felinto [Fri, 26 Oct 2018 22:20:12 +0000 (19:20 -0300)]
Cleanup: Remove silly redundant if check in ED_armature_edit_select_pick

2 years agoFix T57367: Multi-Object-Mode: Edit Lattice selection only working for active object
Dalai Felinto [Fri, 26 Oct 2018 22:18:49 +0000 (19:18 -0300)]
Fix T57367: Multi-Object-Mode: Edit Lattice selection only working for active object

For the records, curves still have this problem.

2 years agoFix lasso selection not working for lattices
Dalai Felinto [Fri, 26 Oct 2018 21:29:42 +0000 (18:29 -0300)]
Fix lasso selection not working for lattices

Regression introduced on e88e80a6.
This was broken for both single and multi-objects.

It is a typo that apparently slipt through testing, oh well.
I'm glad I caught this, I just wished it would have been faster.

2 years agoFix crash when switching to Scripting workspace
Dalai Felinto [Fri, 26 Oct 2018 18:33:03 +0000 (15:33 -0300)]
Fix crash when switching to Scripting workspace

Crash introduced on: a4a6ed1ba3c86ed842f4373c65d64d28d827f864.

2 years agoSmall cleanup: Remove uneeded/wrong check
Dalai Felinto [Fri, 26 Oct 2018 16:45:35 +0000 (13:45 -0300)]
Small cleanup: Remove uneeded/wrong check

If ob was NULL it would crash in the else part of the if statement.
If we really think we may run into that (which we should not) we can just assert
or add a if (ob == NULL) return; in the top of the function.

2 years agoFix unreported: Crash when adding lattice vertex group
Dalai Felinto [Fri, 26 Oct 2018 16:44:14 +0000 (13:44 -0300)]
Fix unreported: Crash when adding lattice vertex group

2 years agoFix unreported: Crash when removing lattice vertex group
Dalai Felinto [Fri, 26 Oct 2018 16:36:30 +0000 (13:36 -0300)]
Fix unreported: Crash when removing lattice vertex group

2 years agoRefactor cleanup: BKE_object_is_in_editmode
Dalai Felinto [Fri, 26 Oct 2018 16:21:54 +0000 (13:21 -0300)]
Refactor cleanup: BKE_object_is_in_editmode

Using switch and keep it concise.

2 years agoFix T57368: Multi-Object-Mode: Edit Lattice draws only active
Dalai Felinto [Fri, 26 Oct 2018 16:11:07 +0000 (13:11 -0300)]
Fix T57368: Multi-Object-Mode: Edit Lattice draws only active

As it turned out the issue wasn't that we were drawing only the active,
but that the "object mode" lattice drawing was drawing on top of the
drawing for all the edit mode lattice objects.

We are doing the same original behaviour for curves and even meshes. To be
investigated if it is ok for those other cases.

2 years agoCycles: Expose noisy image pass by default when rendering with denoiser
Lukas Stockner [Thu, 30 Aug 2018 21:28:10 +0000 (23:28 +0200)]
Cycles: Expose noisy image pass by default when rendering with denoiser

Apparently quite a few users would like to have the noisy pass available when using the denoiser, and since it's being generated anyways we might as well expose it by default.

Reviewers: brecht

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

2 years agoMulti-Objects: LATTICE_OT_make_regular
Dalai Felinto [Fri, 26 Oct 2018 14:01:53 +0000 (11:01 -0300)]
Multi-Objects: LATTICE_OT_make_regular

Committing this for the sake of completionism. I'm going to bring this
up for review, I think we may want to revert it.

Fundamentally I'm changing the behaviour of the operator both in object
mode (acting on all selected lattice objects), as well as the edit mode
(acting on all lattices in edit mode, regardless of them having any
 selected vertice).

2 years agoEevee: SSS: Fix issue with mac and stencil buffer blitting
Clément Foucault [Thu, 25 Oct 2018 20:13:46 +0000 (22:13 +0200)]
Eevee: SSS: Fix issue with mac and stencil buffer blitting

Adding a workaround in this case: we blit the depth buffer instead of the
stencil buffer and use the copy as the texture. This is slower but at
least it should work.

2 years agoGPU: Add workarounds for buggy glBlitFramebuffer function on macOS + Radeon
Clément Foucault [Thu, 25 Oct 2018 19:57:40 +0000 (21:57 +0200)]
GPU: Add workarounds for buggy glBlitFramebuffer function on macOS + Radeon

When calling glBlitFramebuffer on most (if not all) mac that have a GPU
from the Radeon Pro series, the data is not properly copied and only a
subset of the pixels are correctly copied.

This only happens when blitting the depth buffer if the depth buffer is
GL_DEPTH24_STENCIL8.

Changing the depth buffer format to GPU_DEPTH32F_STENCIL8 fixes the issue
but only works if blitting the depth componnent. The stencil componnent
still provoke issues when being copied.

2 years agoGPUTexture: Add supports for GL_DEPTH32F_STENCIL8 texture format
Clément Foucault [Thu, 25 Oct 2018 17:08:35 +0000 (19:08 +0200)]
GPUTexture: Add supports for GL_DEPTH32F_STENCIL8 texture format

2 years agoWorkbench: Fix shadows on macOS
Clément Foucault [Thu, 25 Oct 2018 11:01:15 +0000 (13:01 +0200)]
Workbench: Fix shadows on macOS

2 years agoGP: Assign new materials to brushes
Antonioya [Fri, 26 Oct 2018 07:02:28 +0000 (09:02 +0200)]
GP: Assign new materials to brushes

When create a new material, this must be set to the brushes automatically.

2 years agoPyAPI: raise error when toolbar panels use tabs
Campbell Barton [Fri, 26 Oct 2018 04:05:07 +0000 (15:05 +1100)]
PyAPI: raise error when toolbar panels use tabs

Add-ons that register panels in the toolbar can
no longer use 'bl_categories' (tabs).

2 years agoCorrection for Gizmo.draw_custom_shape utility API
Campbell Barton [Fri, 26 Oct 2018 01:43:40 +0000 (12:43 +1100)]
Correction for Gizmo.draw_custom_shape utility API

2 years agoPyAPI: gpu utility module to create new batches
Jacques Lucke [Fri, 26 Oct 2018 01:38:04 +0000 (12:38 +1100)]
PyAPI: gpu utility module to create new batches

Support the common case of creating batches from python geometry,
a shader and optionally indices.

See D3779