blender.git
2 months agoIndustry Compat Keymap: Accept Knife tool with double-click
William Reynish [Mon, 6 May 2019 13:03:40 +0000 (15:03 +0200)]
Industry Compat Keymap: Accept Knife tool with double-click

Suggested by users on Devtalk

2 months agoimprove tooltip of ViewLayer.use
Philipp Oeser [Mon, 6 May 2019 12:24:33 +0000 (14:24 +0200)]
improve tooltip of ViewLayer.use

thx @Zoot (Gavin Scott) for spotting and providing better wording

Fixes T64157

2 months agoremove unused T_LOCAL_MATRIX
Philipp Oeser [Mon, 6 May 2019 09:15:30 +0000 (11:15 +0200)]
remove unused T_LOCAL_MATRIX

- was introduced in rB844a17a3d9d2 but apparently never used
- spotted while looking into T57767

Reviewers: brecht

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

2 months agoFix T64164: Resetting a curvemap could result in a mirrored curve
Philipp Oeser [Mon, 6 May 2019 11:03:23 +0000 (13:03 +0200)]
Fix T64164: Resetting a curvemap could result in a mirrored curve

A template_curve_mapping with brush=True was always resetting the curve
to a positive slope (descending from left to right).
Behaviour is now changed so that specifying "use_negative_slope" is
taken into account as well.

Also use this for:
- paint "cavity_curve"
- gpencil "curve_sensitivity" / "curve_strength" / "curve_jitter" /
"interpolation_curve"

Reviewers: brecht

Maniphest Tasks: T64164

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

2 months agoUI: Remove wrong use of icon for Rename Active Item
William Reynish [Mon, 6 May 2019 11:42:06 +0000 (13:42 +0200)]
UI: Remove wrong use of icon for Rename Active Item

2 months agoUI: Outliner Filter popover layout
William Reynish [Mon, 6 May 2019 11:40:51 +0000 (13:40 +0200)]
UI: Outliner Filter popover layout

  - Use checkboxes with aligned text
  - Use icons next to the checkboxes
  - Remove wrong use of icons
  - Better grouping

2 months agoSound: Port more cases to be a part of dependency graph
Sergey Sharybin [Mon, 6 May 2019 10:46:14 +0000 (12:46 +0200)]
Sound: Port more cases to be a part of dependency graph

Mainly covers RNA callbacks which were still doing direct scene update,
which was causing crashes. Now corresponding ID_RECALC flags are used,
so all scenes can update accordingly.

Also tested animated volume/pitch on strips, which now works as well.

Fixes T64133: Assert after changing FPS
Fixes T64154: Immediate crash when changing the current frame on the timeline
Fixes T64185: Client Crashes when the frame position value is changed
Fixes T64190: Blender Crash using Timeline Editor
Fixes T64128: Click to close bug type on timeline
Fixes T64147: Crash when setting current frame from Python
Fixes T64152: Blender Auto-Close on timeline change

2 months agoColor management: add functions to detect scene linear and sRGB color spaces
Brecht Van Lommel [Sun, 5 May 2019 11:14:37 +0000 (13:14 +0200)]
Color management: add functions to detect scene linear and sRGB color spaces

Same as the ones in Cycles, but intended for GPU textures.

2 months agoFix error running Eevee render tests
Brecht Van Lommel [Sun, 5 May 2019 16:31:49 +0000 (18:31 +0200)]
Fix error running Eevee render tests

2 months agoUI: disable colored icons in menus for now
Brecht Van Lommel [Mon, 6 May 2019 09:50:50 +0000 (11:50 +0200)]
UI: disable colored icons in menus for now

Only a few icons are colored, which caused some random icons to be colored and
others not. We can add it back for specific menus later (like add object or
modifiers).

2 months agoUI: File Browser bookmarks panels
William Reynish [Mon, 6 May 2019 09:56:55 +0000 (11:56 +0200)]
UI: File Browser bookmarks panels

  - Group these together in sub-panels
  - Use much clearer naming
  - Close Volumes and Recents by default

2 months agoUI: Icons update
William Reynish [Mon, 6 May 2019 09:54:46 +0000 (11:54 +0200)]
UI: Icons update

New icons from Andrzej Ambroż / jendrzych:

  - New icons for select tool modes
  - Brought back screen icon for viewport visibility toggles
  - Added new Instanced visibility toggle (unused currently - meant for forthcoming updates to the Outliner)
  - New Gizmo icon for the header
  - Many tweaks and alterations to existing icons. Full list on Devtalk
  - Use correct icon when Proportional Editing is disabled

2 months agoSound: Fix access wrong dependency graph
Sergey Sharybin [Mon, 6 May 2019 09:29:25 +0000 (11:29 +0200)]
Sound: Fix access wrong dependency graph

Due to some fields in the context being NULL access was happening
to the default view layer, not the active one.

Simply re-arranged context initialization, so it happens before
accessing dependnecy graph.

Fixes T64183: Crash in BKE_sound_scene_playing due to Scene NULL
Fixes T64192: Crash opening a file with a non-default View Layer active

2 months agoDepsgraph: Fix wrong comment
Sergey Sharybin [Mon, 6 May 2019 08:03:22 +0000 (10:03 +0200)]
Depsgraph: Fix wrong comment

2 months agoImplement mirroring in pose mode (absolute and relative)
Sebastian Parborg [Mon, 6 May 2019 07:47:45 +0000 (09:47 +0200)]
Implement mirroring in pose mode (absolute and relative)

Added working X-mirroring in pose mode with an optional relative mirror
mode.

Reviewed By: Campbell Barton

Differential Revision: http://developer.blender.org/D4765

2 months agoFix T64178: Invisible image 2D cursor
Campbell Barton [Mon, 6 May 2019 02:55:54 +0000 (12:55 +1000)]
Fix T64178: Invisible image 2D cursor

Own error in 928becec60d16, move cursor drawing to single location.

2 months agoCleanup: clang-format
Campbell Barton [Mon, 6 May 2019 01:59:03 +0000 (11:59 +1000)]
Cleanup: clang-format

2 months agoUI: Tooltips
William Reynish [Sun, 5 May 2019 19:36:12 +0000 (21:36 +0200)]
UI: Tooltips

  - Add missing tooltips to Quick Effects and Subdivide Edge Ring
  - Add proper tooltip to the Bevel operator
  - Clearer tooltips for the extrude operators

Plus a few other tweaks

Suggested by users on Devtalk.

2 months agoIndustry Compat keymap: Remove ability to cancel knife with right click.
William Reynish [Sun, 5 May 2019 18:49:25 +0000 (20:49 +0200)]
Industry Compat keymap: Remove ability to cancel knife with right click.

Was too easy to do by mistake while attempting to zoom.

Unfortunately it seems like it's not currently possible to add zooming to the Knife modal keymap, so this is still missing here.

2 months agoRNA: add an Object method to clear all shape keys for completeness.
Alexander Gavrilov [Sun, 5 May 2019 15:58:25 +0000 (18:58 +0300)]
RNA: add an Object method to clear all shape keys for completeness.

This matches bpy.ops.object.shape_key_remove(all=True) in behavior.

2 months agoIndustry Compat Keymap: Fix Select All operators in the Info Editor
William Reynish [Sun, 5 May 2019 15:42:18 +0000 (17:42 +0200)]
Industry Compat Keymap: Fix Select All operators in the Info Editor

Patch by Valentin (Poulpator)

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

2 months agoDepsgraph: fix Bone property drivers stored in Object animdata.
Alexander Gavrilov [Sat, 4 May 2019 17:12:19 +0000 (20:12 +0300)]
Depsgraph: fix Bone property drivers stored in Object animdata.

This can easily happen if adding drivers through Python via
pose.bones[...].bone.driver_add(), e.g. in Rigify code: the
bone field doesn't change id_data, so the driver is associated
with the object ID.

To handle this it's necessary to skip from Object to data in
RNA_Bone-specific code both for generic RNA and in the custom
code for drivers. The latter also had to be changed to use the
proper parsed RNA pointer instead of string matching on paths.

2 months agoGPencil: Verify brush is valid for grease pencil
Antonioya [Sun, 5 May 2019 07:10:44 +0000 (09:10 +0200)]
GPencil: Verify brush is valid for grease pencil

Usually the brush type is correct, but for some old files the brush could be a not valid type. In this case, returns the object active material.

This is related to T61413

2 months agoCleanup: fallthrough attribute warning
Campbell Barton [Sun, 5 May 2019 02:13:10 +0000 (12:13 +1000)]
Cleanup: fallthrough attribute warning

Fall-through without label or default after it.

2 months agoSound: add stubs to build without audaspace
Campbell Barton [Sun, 5 May 2019 02:28:16 +0000 (12:28 +1000)]
Sound: add stubs to build without audaspace

2 months agoFix T63789: Precision issues in glsl noise texture
mano-wii [Sat, 4 May 2019 19:44:44 +0000 (16:44 -0300)]
Fix T63789: Precision issues in glsl noise texture

There is a significant precision loss when converting large float values to int.

2 months agoSound: Make sure spin lock is initialized for new sound datablocks
Sergey Sharybin [Sat, 4 May 2019 18:34:56 +0000 (20:34 +0200)]
Sound: Make sure spin lock is initialized for new sound datablocks

Should have been done as a part of 9f681bea68f.

2 months agoSound: Delay creating sound scene handle for until is needed
Sergey Sharybin [Sat, 4 May 2019 17:20:41 +0000 (19:20 +0200)]
Sound: Delay creating sound scene handle for until is needed

Solves crash loading volume Cycles regression files.

2 months agoFix T64144: Crash when displaying audio waveforms in VSE
Sergey Sharybin [Sat, 4 May 2019 17:15:15 +0000 (19:15 +0200)]
Fix T64144: Crash when displaying audio waveforms in VSE

2 months agoFix T64143: Crash when scrubbing in the graph editor
Sergey Sharybin [Sat, 4 May 2019 16:53:59 +0000 (18:53 +0200)]
Fix T64143: Crash when scrubbing in the graph editor

2 months agoCycles: Fix NULL instead of false
Sergey Sharybin [Sat, 4 May 2019 16:49:37 +0000 (18:49 +0200)]
Cycles: Fix NULL instead of false

Not really noticeable for users, since the compiled code is the same,
but semantically this is incorrect.

2 months agoFix T64045: Crash activating fullscreen workspace
Julian Eisel [Sat, 4 May 2019 13:27:31 +0000 (15:27 +0200)]
Fix T64045: Crash activating fullscreen workspace

See d83a72ec104ce9.

2 months agoUI: Add Split and Separate to the mesh editing context menus
William Reynish [Sat, 4 May 2019 13:12:20 +0000 (15:12 +0200)]
UI: Add Split and Separate to the mesh editing context menus

2 months agoUI: Add color and blending to paint mode context menus
William Reynish [Sat, 4 May 2019 13:03:42 +0000 (15:03 +0200)]
UI: Add color and blending to paint mode context menus

2 months agoIndustry Compat Keymap: Set Proportional Editing to B key
William Reynish [Sat, 4 May 2019 12:35:40 +0000 (14:35 +0200)]
Industry Compat Keymap: Set Proportional Editing to B key

Same as popular DCC app.

This means having to change Bevel to Ctrl/Cmd-B

Also fix missing shortcut for Extrude in Curve Edit mode.

2 months agoUI: Add Look Developer Balls Size option
George Vogiatzis [Sat, 4 May 2019 12:03:51 +0000 (14:03 +0200)]
UI: Add Look Developer Balls Size option

Note: Some adjustments were made compared to the diff mainly for code
readability and made the default ball size 150px.

Reviewed By: fclem

Differential Revision: http://developer.blender.org/D4793

2 months agoCleanup: GPU_buffers: Remove obsolete debug drawing
Clément Foucault [Fri, 3 May 2019 23:44:55 +0000 (01:44 +0200)]
Cleanup: GPU_buffers: Remove obsolete debug drawing

2 months agoCleanup: Eevee: Remove Flat normal shader variation
Clément Foucault [Fri, 3 May 2019 23:42:50 +0000 (01:42 +0200)]
Cleanup: Eevee: Remove Flat normal shader variation

Was use by sculpt mode but that's not used anymore.

2 months agoCleanup: Remove unused code in sculpt_mode, workbench and draw manager
Clément Foucault [Fri, 3 May 2019 23:41:39 +0000 (01:41 +0200)]
Cleanup: Remove unused code in sculpt_mode, workbench and draw manager

2 months agoSculpt: Refactor draw manager sculpt drawing mechanism
Clément Foucault [Fri, 3 May 2019 23:39:35 +0000 (01:39 +0200)]
Sculpt: Refactor draw manager sculpt drawing mechanism

Workbench/Eevee now displays multiple multi-materials correctly.

Iterate over pbvh nodes when doing object iteration. This makes the
rendering process more streamlined and allow for using different materials.

This change will make possible to:
- Add culling pass of each pbvh leaf node. (speedup if zoomed on a small
area)
- Reduce number of lead node iteration.
- Reduce code complexity

2 months agoGPUBuffers: Save / expose material index per buffers
Clément Foucault [Fri, 3 May 2019 22:46:26 +0000 (00:46 +0200)]
GPUBuffers: Save / expose material index per buffers

2 months agoFix T64102: Can't add X-Mirror to quick favorites
Campbell Barton [Fri, 3 May 2019 10:58:49 +0000 (20:58 +1000)]
Fix T64102: Can't add X-Mirror to quick favorites

2 months agoCleanup: unused vars
Campbell Barton [Sat, 4 May 2019 00:56:33 +0000 (10:56 +1000)]
Cleanup: unused vars

2 months agoUI: Dynamic region size for file browser options
Julian Eisel [Fri, 3 May 2019 21:09:47 +0000 (23:09 +0200)]
UI: Dynamic region size for file browser options

Makes the file browser operator property region (lower left) dynamically
sized to content. Previously, the default size would work really badly
for file browsers opened in small windows, e.g. to install Add-ons from
the preferences window. It would be mostly empty but use lots of space
then.

2 months agoFix crash in background rendering after recent sound changes
Brecht Van Lommel [Fri, 3 May 2019 17:44:49 +0000 (19:44 +0200)]
Fix crash in background rendering after recent sound changes

2 months agoFix Cycles crash when trying to load image that does not exist
Brecht Van Lommel [Fri, 3 May 2019 17:07:22 +0000 (19:07 +0200)]
Fix Cycles crash when trying to load image that does not exist

It was crashing due to array out of bounds access. This is not a great fix,
but brings back behavior the same as before now. Perhaps images that failed
to load should be stored separately somewhere.

2 months agoGPencil: Add stroke color to Materials Popover
Antonioya [Fri, 3 May 2019 16:43:11 +0000 (18:43 +0200)]
GPencil: Add stroke color to Materials Popover

This makes more easy to manage the color, specially for advanced brushes with pinned materials.

Reviewers: @pepeland, @mendio

2 months agoUI: color icons in the properties editor tabs
Brecht Van Lommel [Fri, 3 May 2019 16:20:35 +0000 (18:20 +0200)]
UI: color icons in the properties editor tabs

Still can use more tweaks and icon reorganization, but this gets us closer
to the intended design so we can evaluate it. Ref T61561, T63521.

2 months agoFix Cycles assert on exit after recent changes
Brecht Van Lommel [Fri, 3 May 2019 15:42:08 +0000 (17:42 +0200)]
Fix Cycles assert on exit after recent changes

2 months agoSound: Fix for being unable to jump to a frame during playback with A/V sync
Sergey Sharybin [Fri, 3 May 2019 15:47:44 +0000 (17:47 +0200)]
Sound: Fix for being unable to jump to a frame during playback with A/V sync

2 months agoUI: Fix crash when region becomes too thin
Jacques Lucke [Fri, 3 May 2019 15:42:45 +0000 (17:42 +0200)]
UI: Fix crash when region becomes too thin

2 months agoSound: More fixes for access of original scene
Sergey Sharybin [Fri, 3 May 2019 15:27:13 +0000 (17:27 +0200)]
Sound: More fixes for access of original scene

Same as previous commit, just few lines to the bottom.

2 months agoSound: Fix access original scene during playback
Sergey Sharybin [Fri, 3 May 2019 15:19:24 +0000 (17:19 +0200)]
Sound: Fix access original scene during playback

Was required to have AV-sync enabled. and then simply play playback
would have triggered an assert.

In release builds the sync would have happened to a wrong frame.

2 months agofix image_changed() doing unneccessary texture updates when texture wasnt
Philipp Oeser [Fri, 3 May 2019 09:18:32 +0000 (11:18 +0200)]
fix image_changed() doing unneccessary texture updates when texture wasnt
using an image

Reviewers: brecht

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

2 months agoCleanup: Selling in comment
Sergey Sharybin [Fri, 3 May 2019 08:19:08 +0000 (10:19 +0200)]
Cleanup: Selling in comment

2 months agoDepsgraph: Make comment about evaluation more obvious
Sergey Sharybin [Fri, 3 May 2019 07:49:15 +0000 (09:49 +0200)]
Depsgraph: Make comment about evaluation more obvious

2 months agoSound: Make sound handles only be in evaluated datablocks
Sergey Sharybin [Thu, 2 May 2019 12:31:33 +0000 (14:31 +0200)]
Sound: Make sound handles only be in evaluated datablocks

Quite straightforward change, which makes it so audio handles are
only created inside of evaluated datablocks.

Exception is adding sound strip to the sequencer, which needs an
audio handle to query length and number of channels. This is done
by temporarily loading sound file into an original datablock, and
then tossing it away.

There is an assert in sound.c which verifies that audio system is
used from an evaluated domain, which should help porting all the
cases which are likely missed by this commit.

Some annoying parts:

- `BKE_sound_update_scene()` is iterating over all bases, and does
  special ID tags to see whether sound has been handled or not
  already. This can not be done the old fashion now.

  Ideally, this will be done as a speaker datablock evaluation,
  but seems that would require a lock since audio API is not safe
  for threading. So this is not a desired way i'd say.

  Possible solution here would be to iterate over ID datablocks
  using dependency graph query API.

- Frame jump needs to call `BKE_sound_seek_scene()` directly
  because there might be some flags assigned to the scene which
  could be clear after operator execution is over.

  Need to verify if that's the case though. This is a bit hairy
  code, so sticking to a safest and known to work approach for
  now.

- Removed check for format when opening new sound file.
  Maybe we can have some utility function which queries channel
  and duration information, leaving the caller's code clean and
  tidy.

Tested following cases:
- Adding/removing/moving sequencer's sound strips.
- Adding/moving speakers in viewport.
- Rendering audio.

Reviewers: brecht

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

2 months agoDepsgraph: Preserve sound and audio pointers through copy-on-write
Sergey Sharybin [Thu, 2 May 2019 09:14:10 +0000 (11:14 +0200)]
Depsgraph: Preserve sound and audio pointers through copy-on-write

This allows to have scene and speaker copy-on-write executed without
interrupting the playing sound.

2 months agoDepsgraph: Store original sequencer strip pointer
Sergey Sharybin [Thu, 2 May 2019 08:17:25 +0000 (10:17 +0200)]
Depsgraph: Store original sequencer strip pointer

Allows to identify where the strip came from.

2 months agoSound: Move evaluation to dependency graph
Sergey Sharybin [Wed, 1 May 2019 13:57:16 +0000 (15:57 +0200)]
Sound: Move evaluation to dependency graph

The sound handles are still in the original datablocks, so it's easier
to test since there should be no functional changes.

2 months agoSound: Delay opening handlers for until really needed
Sergey Sharybin [Wed, 1 May 2019 13:12:38 +0000 (15:12 +0200)]
Sound: Delay opening handlers for until really needed

Needs to be done in order to localize sound handlers to the evaluated
IDs only. This commit might not be fully optimal, since it does more
things on every scene update request, but that will be solved by the
upcoming change which will put those updates to a dependency graph.

2 months agoDepsgraph: Add scene audio component
Sergey Sharybin [Wed, 1 May 2019 10:46:47 +0000 (12:46 +0200)]
Depsgraph: Add scene audio component

The idea is to make that responsible for dealing with
things like audio update on frame jump and such.

2 months agoDepsgraph: Tag sequencer for update on changes
Sergey Sharybin [Wed, 1 May 2019 10:10:32 +0000 (12:10 +0200)]
Depsgraph: Tag sequencer for update on changes

Currently only adding, removing and transforming strips. Most likely more
tags is needed.

2 months agoDepsgraph: Initial work to cover sequencer
Sergey Sharybin [Wed, 1 May 2019 09:51:11 +0000 (11:51 +0200)]
Depsgraph: Initial work to cover sequencer

Just adds sequencer operation and links possible sound ID to it.

No functional changes, just moving towards sound system integration
into the dependency graph.

2 months agoDepsgraph: Make sound ID part of the graph
Sergey Sharybin [Wed, 1 May 2019 09:23:20 +0000 (11:23 +0200)]
Depsgraph: Make sound ID part of the graph

Currently those IDs are not covered by copy-on-write mechanism since
that ruins the current design of BKE_sound, But this change allows to
move towards system where sound handlers are only valid for an evaluated
ID datablocks.

2 months agoFix compiler warning/error after recent changes
Brecht Van Lommel [Fri, 3 May 2019 13:49:15 +0000 (15:49 +0200)]
Fix compiler warning/error after recent changes

2 months agoFix width of compact buttons with icons, e.g. layout.menu().
Alexander Gavrilov [Fri, 3 May 2019 13:15:11 +0000 (16:15 +0300)]
Fix width of compact buttons with icons, e.g. layout.menu().

As mentioned in the comment, the icon width computation relies on
big enough margins; however in compact mode they aren't big enough
and the label gets truncated.

2 months agoFix crash opening file saved in editmode with a brush image texture
Philipp Oeser [Fri, 3 May 2019 07:55:38 +0000 (09:55 +0200)]
Fix crash opening file saved in editmode with a brush image texture

started with recent UV Sculpt tool-system integration rB928becec60d1

Fixes T64094

Reviewers: brecht

Maniphest Tasks: T64094

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

2 months agoUI: remove bone only constraints from object constraint menu
Nathan Craddock [Fri, 3 May 2019 12:32:45 +0000 (14:32 +0200)]
UI: remove bone only constraints from object constraint menu

This is better than showing an error after trying to add them. Ref T61560.

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

2 months agoCycles: support loading images from arbitrary OpenColorIO color space
Lukas Stockner [Thu, 2 May 2019 13:45:31 +0000 (15:45 +0200)]
Cycles: support loading images from arbitrary OpenColorIO color space

These are the internal changes to Cycles, for Blender integration there are no
functional changes in this commit.

Images are converted to scene linear color space on file load, and on reading
from the OpenImageIO texture cache. 8-bit images are compressed with the sRGB
transfer function to avoid precision loss while keeping memory usages low. This
also means that for common cases of 8-bit sRGB images no conversion happens at
all on image loading.

Initial patch by Lukas, completed by Brecht.

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

2 months agoCycles: add colorspace manager class and utilities based on OpenColorIO
Lukas Stockner [Fri, 3 May 2019 09:23:16 +0000 (11:23 +0200)]
Cycles: add colorspace manager class and utilities based on OpenColorIO

This is the groundwork for supporting loading image textures with arbitrary
color spaces through OpenColorIO.

Initial patch by Lukas, completed by Brecht.

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

2 months agoCleanup: refactor Cycles OSL texture handling
Brecht Van Lommel [Thu, 2 May 2019 10:40:24 +0000 (12:40 +0200)]
Cleanup: refactor Cycles OSL texture handling

This adds our own OSL texture handle, that has info for OIIO textures or our
own custom texture types. A filename to handle hash map is used for lookups.
This is efficient because it happens at OSL compile time, because the optimizer
can figure out constant strings and replace them with texture handles.

2 months agoCleanup: refactor passing of OSL kernel globals for upcoming changes
Brecht Van Lommel [Thu, 2 May 2019 13:39:23 +0000 (15:39 +0200)]
Cleanup: refactor passing of OSL kernel globals for upcoming changes

2 months agoUI: Pass color id into view2d text drawing
Jacques Lucke [Fri, 3 May 2019 13:09:28 +0000 (15:09 +0200)]
UI: Pass color id into view2d text drawing

2 months agoIndustry Compat Keymap: Fix box selecting keys in the Graph Editor
William Reynish [Fri, 3 May 2019 12:35:44 +0000 (14:35 +0200)]
Industry Compat Keymap: Fix box selecting keys in the Graph Editor

It was not selecting the handles, causing a skewed offset when transforming

2 months agoFix missiong collection move line in outliner after recent changes
Harley Acheson [Fri, 3 May 2019 12:19:26 +0000 (14:19 +0200)]
Fix missiong collection move line in outliner after recent changes

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

2 months agoICK: Missed one line in last commit
William Reynish [Fri, 3 May 2019 11:55:01 +0000 (13:55 +0200)]
ICK: Missed one line in last commit

2 months agoIndustry Compat Keymap: Fix Return key in the File Browser
William Reynish [Fri, 3 May 2019 11:53:41 +0000 (13:53 +0200)]
Industry Compat Keymap: Fix Return key in the File Browser

Return was set to Rename in all editors. Now set it per editor and exclude File Browser

2 months agoRefactor: Support arbitrary y offset for channel list
Jacques Lucke [Fri, 3 May 2019 11:00:18 +0000 (13:00 +0200)]
Refactor: Support arbitrary y offset for channel list

At first you could think that this refactor would not be
necessary, because `ACHANNEL_FIRST` exists already.
It contained the small y offset that all channels had.

Unfortunately, a lot of code assumed that
`ACHANNEL_FIRST = -ACHANNEL_HEIGHT`, making the
define pretty much useless. This refactor fixes that
for the action and nla editor.

As a nice side effect, this patch fixes channel box select.
Before there was always have a half-channel offset.

Reviewers: brecht

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

2 months agoDepsgraph: Remove filtering API
Sergey Sharybin [Fri, 3 May 2019 10:39:12 +0000 (12:39 +0200)]
Depsgraph: Remove filtering API

This was an attempt to speed up motion path calculation, which didn't
really work in real world animation files, where animators already
hide and disable all the heavy collections. Filtering approach also
doesn't allow to have multiple frames evaluated in multiple threads
easily.

Filtering also adds extra complexity on keeping the graph in a correct
and consistent state.

Fixes T64057: Blender crash when use motion paths

2 months agoIndustry Compat Keymap: Set Tab to use Add Search in node editors
William Reynish [Fri, 3 May 2019 10:08:01 +0000 (12:08 +0200)]
Industry Compat Keymap: Set Tab to use Add Search in node editors

More useful than operator search here, and more like some other apps.

2 months agoIndustry Compat Keymap: Use Alt-key navigation in the Image Editor
William Reynish [Fri, 3 May 2019 09:41:56 +0000 (11:41 +0200)]
Industry Compat Keymap: Use Alt-key navigation in the Image Editor

Was missing this by mistake

2 months agoUI: Display panel tweaks
William Reynish [Fri, 3 May 2019 08:26:24 +0000 (10:26 +0200)]
UI: Display panel tweaks

  - Use Display As rather than Draw Type, following naming conventions
  - Rename Advanced subpanel to Stretching, since that more accurately describes what it's for

2 months agoRevert "Cleanup: add semicolon after PyObject_VAR_HEAD"
Campbell Barton [Fri, 3 May 2019 08:09:04 +0000 (18:09 +1000)]
Revert "Cleanup: add semicolon after PyObject_VAR_HEAD"

This reverts commit a01bcfa6366f893fbc8fdbf537d91ece4832ea03.

This causes MSVC2019 build to fail with error C2059

Unfortunately this means we have to put up with bad formatting
in Python structs.

2 months agoUI: Add Annotate tool to Sculpt and Paint mode toolbars
William Reynish [Fri, 3 May 2019 07:41:34 +0000 (09:41 +0200)]
UI: Add Annotate tool to Sculpt and Paint mode toolbars

Users have requested to have the Annotate tool added to Sculpt Mode. It can be useful for annotating while sculpting.

  - Remove Measure tool from the tools_annotate group
  - Add Measure tool to object and edit mode toolbar
  - Add Annotate tools to Sculpt and Paint modes

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

2 months agoFix T59474: Crash assign shortcuts
Campbell Barton [Fri, 3 May 2019 07:08:47 +0000 (17:08 +1000)]
Fix T59474: Crash assign shortcuts

2 months agoFix active tool side-bar redrawing on tool change
Campbell Barton [Fri, 3 May 2019 04:15:38 +0000 (14:15 +1000)]
Fix active tool side-bar redrawing on tool change

2 months agoFix tool header message subscriber
Campbell Barton [Fri, 3 May 2019 03:58:22 +0000 (13:58 +1000)]
Fix tool header message subscriber

2 months agoCleanup: replace RGN_ALIGN_ENUM_MASK
Campbell Barton [Fri, 3 May 2019 03:04:37 +0000 (13:04 +1000)]
Cleanup: replace RGN_ALIGN_ENUM_MASK

This was only used once, other checks were masking out
RGN_SPLIT_PREV which isn't future proof (if other flags are added).

Add RGN_ALIGN_ENUM_FROM_MASK macro, use it everywhere we need to
check the alignment enum.

2 months agoCleanup: add semicolon after PyObject_VAR_HEAD
Campbell Barton [Fri, 3 May 2019 02:26:29 +0000 (12:26 +1000)]
Cleanup: add semicolon after PyObject_VAR_HEAD

clang-format doesn't expand macros,
add semicolon to prevent misleading formatting.

2 months agoCleanup: warnings
Campbell Barton [Fri, 3 May 2019 02:41:06 +0000 (12:41 +1000)]
Cleanup: warnings

Quiet extra-semi-stmt & missing-variable-declarations

2 months agoDefaults: disable developer extras
Campbell Barton [Fri, 3 May 2019 02:15:25 +0000 (12:15 +1000)]
Defaults: disable developer extras

Was enabled by accident when updating startup.blend.

2 months agoDNA: remove unused 'osa' member
Campbell Barton [Fri, 3 May 2019 02:03:06 +0000 (12:03 +1000)]
DNA: remove unused 'osa' member

Also correct unused flag comment, use doxy cross references.

2 months agoIndustry Compat Kerymap: Add Pick Shortest Path to keymap
William Reynish [Thu, 2 May 2019 17:03:15 +0000 (19:03 +0200)]
Industry Compat Kerymap: Add Pick Shortest Path to keymap

Use Ctrl-Shift-Click for this.

2 months agoFix T64072: DynamicPaint: Bake failed: Canvas mesh not updated
Sergey Sharybin [Thu, 2 May 2019 15:46:08 +0000 (17:46 +0200)]
Fix T64072:  DynamicPaint: Bake failed: Canvas mesh not updated

Baking is to happen form within an evaluated scene.

2 months agoFix T63997 Weird z-fight during weight paint
Clément Foucault [Thu, 2 May 2019 14:51:17 +0000 (16:51 +0200)]
Fix T63997 Weird z-fight during weight paint

PBVH drawing was used even in weightpaint/vertexpaint because both uses
the sculpt session.

2 months agoCleanup: Draw Manager: remove DRW_state_invert_facing
Clément Foucault [Thu, 2 May 2019 14:49:48 +0000 (16:49 +0200)]
Cleanup: Draw Manager: remove DRW_state_invert_facing

2 months agoIndustry Compat Keymap: Suppurt MMB for translating nodes
William Reynish [Thu, 2 May 2019 14:28:13 +0000 (16:28 +0200)]
Industry Compat Keymap: Suppurt MMB for translating nodes

Consistent with 3D View and animation editors.

2 months agoGPencil: New API to remove grease pencil material settings
Antonioya [Thu, 2 May 2019 14:26:57 +0000 (16:26 +0200)]
GPencil: New API to remove grease pencil material settings

This is required for some add-ons

Example use:
ma = bpy.data.materials[0]
# create settings
bpy.data.materials.create_gpencil_data(ma)
# remove settings
bpy.data.materials.remove_gpencil_data(ma)

Related to T63707

2 months agoWorkbench,EEVEE: Viewport Render Samples
Jeroen Bakker [Thu, 2 May 2019 13:18:53 +0000 (15:18 +0200)]
Workbench,EEVEE: Viewport Render Samples

 - Add `render_aa` and `viewport_aa` sampling setting for workbench. 0
   samples means no AA, 1 sample uses FXAA and more samples will use
   TAA.
   The viewport `gpu_viewport_quality` can still limit viewport anti-aliasing
   method.
 - Use TAA when rendering images. (this used to be CPU based FSAA)
 - Removed `R_OSA` related settings.

Reviewers: fclem, brecht

Maniphest Tasks: T60847

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