blender.git
3 years agoMerge branch 'master' into blender2.8
Sergey Sharybin [Wed, 7 Jun 2017 12:09:53 +0000 (14:09 +0200)]
Merge branch 'master' into blender2.8

3 years agoDepsgraph: Remove modifiers operation code
Sergey Sharybin [Wed, 7 Jun 2017 12:08:11 +0000 (14:08 +0200)]
Depsgraph: Remove modifiers operation code

Was internally a no-op operation, which only caused extra work
to be done during depsgrpah traversal and evaluation, without
making any measurable improvement.

3 years agoDepsgraph: Remove unused operation codes
Sergey Sharybin [Wed, 7 Jun 2017 10:53:38 +0000 (12:53 +0200)]
Depsgraph: Remove unused operation codes

3 years agoDepsgraph: Remove dead/unused operation codes
Sergey Sharybin [Wed, 7 Jun 2017 10:47:19 +0000 (12:47 +0200)]
Depsgraph: Remove dead/unused operation codes

3 years agoMerge branch 'master' into blender2.8
Sergey Sharybin [Wed, 7 Jun 2017 10:18:07 +0000 (12:18 +0200)]
Merge branch 'master' into blender2.8

3 years agoReport OpenSubdiv version Blender is compiled against
Sergey Sharybin [Wed, 7 Jun 2017 10:16:48 +0000 (12:16 +0200)]
Report OpenSubdiv version Blender is compiled against

3 years agoCollada: Add search path which is used default by it's SCons build system
Sergey Sharybin [Wed, 7 Jun 2017 09:38:12 +0000 (11:38 +0200)]
Collada: Add search path which is used default by it's SCons build system

3 years agoMerge remote-tracking branch 'origin/master' into blender2.8
Dalai Felinto [Wed, 7 Jun 2017 09:38:03 +0000 (11:38 +0200)]
Merge remote-tracking branch 'origin/master' into blender2.8

3 years agogcc5 has issues with Wconversion
Dalai Felinto [Wed, 7 Jun 2017 09:37:28 +0000 (11:37 +0200)]
gcc5 has issues with Wconversion

This leads to a crash in 2.8, but commiting here.
Patch by Campbell Barton.

3 years agoOptimization of tangent calculation
Sergey Sharybin [Wed, 7 Jun 2017 09:23:59 +0000 (11:23 +0200)]
Optimization of tangent calculation

Avoid doing string comparison when we already know layer is
to be added to bitfield.

3 years agoWM: remove unused return values
Campbell Barton [Tue, 6 Jun 2017 13:04:46 +0000 (23:04 +1000)]
WM: remove unused return values

3 years agoSmall cleanup: Use ELEM and wrong identation
Dalai Felinto [Tue, 6 Jun 2017 15:01:20 +0000 (17:01 +0200)]
Small cleanup: Use ELEM and wrong identation

3 years agoCMake: Update clay engine message
Dalai Felinto [Tue, 6 Jun 2017 15:00:19 +0000 (17:00 +0200)]
CMake: Update clay engine message

3 years agoEevee: Fix shader compilation issue.
Clément Foucault [Tue, 6 Jun 2017 16:19:38 +0000 (18:19 +0200)]
Eevee: Fix shader compilation issue.

3 years agoCycles: Fix infinite update when using duplis
Sergey Sharybin [Tue, 6 Jun 2017 14:27:02 +0000 (16:27 +0200)]
Cycles: Fix infinite update when using duplis

The issue was caused by usage of address of dupli-object (which will vary
from iteration process to iteration process) as something denoting whether
we've got the data synchronized to Cycles or not.

For now solved by using address of original object (the one DupliObject
points to) as a pointer for the map.

Need to do more thoughts about this.

3 years agoDraw Manager: Prevent misuse of static draw context
Dalai Felinto [Tue, 6 Jun 2017 14:19:07 +0000 (16:19 +0200)]
Draw Manager: Prevent misuse of static draw context

This is supposed to help catch bugs if referrencing stack data out of
the draw loop context.

No change is suppose to happen for users (specially because the changes
here happens mostly on debug).

It includes a change in the logic for render loop, to make sure DST is
not accessed before we enter it - contribution by Campbell Barton.

3 years agoDepsgraph: Cleanup, unused includes
Sergey Sharybin [Tue, 6 Jun 2017 12:19:25 +0000 (14:19 +0200)]
Depsgraph: Cleanup, unused includes

3 years agoCycles: Support rendering objects from dupli-list
Sergey Sharybin [Tue, 6 Jun 2017 11:58:40 +0000 (13:58 +0200)]
Cycles: Support rendering objects from dupli-list

This commit extends the work from Dalai made around scene iterators to
support iterating into objects from dupli-lists.

Changes can be summarized as:

- Depsgraph iterator will hold pointer to an object which created current
  duplilist. It is available via `dupli_parent` field of the iterator.
  It is only set when duplilist is not NULL and guaranteed to be NULL
  for all other cases.

- Introduced new depsgraph.duplis collection which gives a more extended
  information about depsgraph iterator.  It is basically a collection on top
  of DEGObjectsIteratorData.

  It is used to provide access to such data as persistent ID, generated space
  and so on.

Things which still needs to be done/finished/clarified:

- Need to introduce some sort of `is_instance` boolean property which will
  indicate Python and C++ RNA that we are inside of dupli-list.

- Introduce a way to skip dupli-list for particular objects.

  So, for example, if we are culling object due to distance we can skip all
  objects it was duplicating.

- Introduce a way to skip particular duplicators.

  So we can skip iterating into particle system.

- Introduce some cleaner API for C side of operators to access all data such as
  persistent ID and friends.

  This way we wouldn't need de-reference iterator and could keep access to such
  data really abstract. Who knows how we'll be storing internal state of the
  operator in the future.

While there is still stuff to do, current state works and moves us in the proper
direction.

3 years agoWM: manipulator callback arg order
Campbell Barton [Tue, 6 Jun 2017 12:14:21 +0000 (22:14 +1000)]
WM: manipulator callback arg order

Use same arg order for C & RNA

3 years agoForce crash on depsgraph iterator wrong access.
Dalai Felinto [Tue, 6 Jun 2017 10:47:47 +0000 (12:47 +0200)]
Force crash on depsgraph iterator wrong access.

Related to T51718, so it crashes even when no fancy ASAN flags are used.
Patch suggestion by Campbell Barton.

3 years agoMerge branch 'master' into blender2.8
Sergey Sharybin [Tue, 6 Jun 2017 10:17:07 +0000 (12:17 +0200)]
Merge branch 'master' into blender2.8

3 years agoDepsgraph: Only use extern "C" when really needed
Sergey Sharybin [Tue, 6 Jun 2017 10:14:39 +0000 (12:14 +0200)]
Depsgraph: Only use extern "C" when really needed

3 years agoBLI: Use C++ guards for stack header
Sergey Sharybin [Tue, 6 Jun 2017 10:13:45 +0000 (12:13 +0200)]
BLI: Use C++ guards for stack header

This is handy to have C++ guards for BLI functions so they
can be easily re-used in C++ code. This matches other headers
from this library as well.

3 years agoDraw manager: visibility of objects centers to mimic old 2.7x behaviour
Dalai Felinto [Tue, 6 Jun 2017 09:45:29 +0000 (11:45 +0200)]
Draw manager: visibility of objects centers to mimic old 2.7x behaviour

We only show object center if object is selected, active or if viewport
has the "All Object Origins" options.

The viewport display options can migrate to renderlayer options.
However, we can mimic 2.7x as a compromise while the final design is
finalized.

3 years agoScene object iterator: Replace recursion with loop
Sergey Sharybin [Tue, 6 Jun 2017 09:22:13 +0000 (11:22 +0200)]
Scene object iterator: Replace recursion with loop

This way we are not afraid of recursion being too deep.

That could have happened when having two collections which
are sharing same list of 1000s of objects.

3 years agoMake particle size follow world space instead of screen space
Luca Rood [Tue, 6 Jun 2017 07:56:27 +0000 (09:56 +0200)]
Make particle size follow world space instead of screen space

3 years agoWM: functions for assigning all manipulator callbacks
Campbell Barton [Tue, 6 Jun 2017 07:07:26 +0000 (17:07 +1000)]
WM: functions for assigning all manipulator callbacks

- Move callbacks into type struct.
- Rename render_3d_intersection -> draw_select.
- Add header for function signatures (needed for types and api headers).
- Add WM_manipulatormaptype_find

3 years agoEevee: Optimize scene with a large number of objects.
Clément Foucault [Mon, 5 Jun 2017 20:05:21 +0000 (22:05 +0200)]
Eevee: Optimize scene with a large number of objects.

Using a GHash to store the shgroup of every Material. This way we do not duplicates the DRWShadingGroups allocations on every object.

3 years agoWM: pass manipulator-map when creating wmManipulatorGroup
Campbell Barton [Mon, 5 Jun 2017 17:34:09 +0000 (03:34 +1000)]
WM: pass manipulator-map when creating wmManipulatorGroup

Also store parent-pointer in wmManipulatorGroup's,
since its not always possible to access the parent pointer.

3 years agoMerge branch 'master' into blender2.8
Campbell Barton [Mon, 5 Jun 2017 08:11:59 +0000 (18:11 +1000)]
Merge branch 'master' into blender2.8

3 years agoWM: add WM_manipulatorgrouptype_append_ptr
Campbell Barton [Mon, 5 Jun 2017 08:10:52 +0000 (18:10 +1000)]
WM: add WM_manipulatorgrouptype_append_ptr

Needed for PyAPI registration.

3 years agoWM: de-duplicate operator append code
Campbell Barton [Mon, 5 Jun 2017 07:57:57 +0000 (17:57 +1000)]
WM: de-duplicate operator append code

WM_operatortype_append(_ptr) functions had diverged.

3 years agoPyAPI: is_staticmethod used for classmethods's too
Campbell Barton [Mon, 5 Jun 2017 06:05:36 +0000 (16:05 +1000)]
PyAPI: is_staticmethod used for classmethods's too

Add note to investigate this, don't change so close to release.

3 years agoPyAPI: correct exception, expect 'staticmethod'
Campbell Barton [Mon, 5 Jun 2017 05:31:05 +0000 (15:31 +1000)]
PyAPI: correct exception, expect 'staticmethod'

3 years agoDwM: skip background-set objects w/ selection
Campbell Barton [Mon, 5 Jun 2017 05:02:47 +0000 (15:02 +1000)]
DwM: skip background-set objects w/ selection

3 years agoFix alembic tests not running with debug build on windows
Ray Molenkamp [Sun, 4 Jun 2017 23:05:59 +0000 (17:05 -0600)]
Fix alembic tests not running with debug build on windows

3 years agoClay Engine: Improve sampling of SSAO
Clément Foucault [Sun, 4 Jun 2017 21:11:48 +0000 (23:11 +0200)]
Clay Engine: Improve sampling of SSAO

Replace completly random noise by Blue noisen, giving a better aspect.
Also randomize the distance in the sample direction to cover the whole distance even with 1 sample. Using another blue noise for this.
Replace spiral samples (that had tendency to align if the number of samples was near the chosen constant) with Hammersley samples that have good coverage even for low number of samples.
Use a UBO instead of Texture (a bit less latency) making things a tiny bit faster.
Move the noise data to the SceneLayerData, because each render layer can have a different sample count.

3 years agoEevee: Modify Blue Noise.
Clément Foucault [Sun, 4 Jun 2017 19:45:41 +0000 (21:45 +0200)]
Eevee: Modify Blue Noise.

3 years agoEevee: Move Spherical Harmonics to a new Probe UBO.
Clément Foucault [Sun, 4 Jun 2017 14:50:22 +0000 (16:50 +0200)]
Eevee: Move Spherical Harmonics to a new Probe UBO.

Keep data packing tight to prevent use of padding floats

3 years agoEevee: Material code refactor.
Clément Foucault [Sun, 4 Jun 2017 10:12:58 +0000 (12:12 +0200)]
Eevee: Material code refactor.

Separate material handling inside another file.
Make use of enums to identify shader variations.
Group all 64*64 LUTs into one array texture.
Only update world probe if world changes.

3 years agoWorld: Add temporary update flag.
Clément Foucault [Sun, 4 Jun 2017 10:08:34 +0000 (12:08 +0200)]
World: Add temporary update flag.

3 years agoFix T51587: Blender fails to interpret a specific layer in OpenEXR multilayer file
Lukas Stockner [Sat, 3 Jun 2017 22:58:38 +0000 (00:58 +0200)]
Fix T51587: Blender fails to interpret a specific layer in OpenEXR multilayer file

3 years agoEevee: Fix compilation error
Clément Foucault [Fri, 2 Jun 2017 23:43:25 +0000 (01:43 +0200)]
Eevee: Fix compilation error

3 years agoEevee: Cleanup. Group data functions into one file.
Clément Foucault [Fri, 2 Jun 2017 22:53:47 +0000 (00:53 +0200)]
Eevee: Cleanup. Group data functions into one file.

3 years agoEevee: fix bad eye vector and get rid of two uniform
Clément Foucault [Fri, 2 Jun 2017 19:52:40 +0000 (21:52 +0200)]
Eevee: fix bad eye vector and get rid of two uniform

3 years agoEevee: Reduce shadow map precision.
Clément Foucault [Fri, 2 Jun 2017 19:00:10 +0000 (21:00 +0200)]
Eevee: Reduce shadow map precision.

Since we only store linear distance now we don't need so much bytes per pixels.

3 years agoEevee: fix shadows artifact by clearing to max depth
Clément Foucault [Fri, 2 Jun 2017 18:52:44 +0000 (20:52 +0200)]
Eevee: fix shadows artifact by clearing to max depth

3 years agoEevee: fix light update when a shadow caster is deleted
Clément Foucault [Fri, 2 Jun 2017 18:51:35 +0000 (20:51 +0200)]
Eevee: fix light update when a shadow caster is deleted

3 years agoEevee: Polishing of Exponential Shadow mapping
Clément Foucault [Fri, 2 Jun 2017 18:50:04 +0000 (20:50 +0200)]
Eevee: Polishing of Exponential Shadow mapping

Added exponent parameter to tweak light bleeding.
Added depth bias to the shadow test.
Added better blurring using 32 samples.

3 years agoUI: Change shadow map bias tooltip
Clément Foucault [Fri, 2 Jun 2017 13:28:32 +0000 (15:28 +0200)]
UI: Change shadow map bias tooltip

3 years agoEevee: Update Light data panel
Clément Foucault [Fri, 2 Jun 2017 13:27:57 +0000 (15:27 +0200)]
Eevee: Update Light data panel

3 years agoObject Mode Engine: Fix spot cone shader.
Clément Foucault [Fri, 2 Jun 2017 10:30:01 +0000 (12:30 +0200)]
Object Mode Engine: Fix spot cone shader.

3 years agoPyAPI: Cleanup "Python API Overview" doc
nBurn [Fri, 2 Jun 2017 21:22:44 +0000 (17:22 -0400)]
PyAPI: Cleanup "Python API Overview" doc

Reword to clean up some odd grammar (mostly dangling modifiers) and
improve readability.

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

3 years agoFix for crash/error drawing duplis
Campbell Barton [Fri, 2 Jun 2017 16:21:10 +0000 (02:21 +1000)]
Fix for crash/error drawing duplis

Drawing object centers used stack memory,
we don't want to draw these anyway so add check.

3 years agoCleanup: Trailign whitespace
Sergey Sharybin [Fri, 2 Jun 2017 14:08:53 +0000 (16:08 +0200)]
Cleanup: Trailign whitespace

3 years agoFix logic for bitwise flags in bases during deg iterator
Dalai Felinto [Fri, 2 Jun 2017 12:30:37 +0000 (14:30 +0200)]
Fix logic for bitwise flags in bases during deg iterator

Spotted/reported by Sergey Sharybin.

3 years agoFixup for 824bf261f773 so Cycles does not show dupli
Dalai Felinto [Fri, 2 Jun 2017 11:05:14 +0000 (13:05 +0200)]
Fixup for 824bf261f773 so Cycles does not show dupli

Cycles is using rna_depsgraph, not rna_scene. Duplis are still not working there
but now at least it shows it was showing before the commit.

To show duplis in Cycles do:

-       data->flag = DEG_OBJECT_ITER_FLAG_SET;
+       data->flag = DEG_OBJECT_ITER_FLAG_ALL;

3 years agoFix T51691: Shear cursor input scales w/ zoom
Campbell Barton [Fri, 2 Jun 2017 10:40:41 +0000 (20:40 +1000)]
Fix T51691: Shear cursor input scales w/ zoom

Use relative value from cursor movement.

3 years agoSilence annoying rna warnings from Eevee
Dalai Felinto [Fri, 2 Jun 2017 09:47:47 +0000 (11:47 +0200)]
Silence annoying rna warnings from Eevee

3 years agoInitial implememtation for dupli objects
Dalai Felinto [Thu, 1 Jun 2017 13:26:47 +0000 (15:26 +0200)]
Initial implememtation for dupli objects

Now dupli groups, objects, particles, ... are all working.

This introduces a flag for the iterator to determine whether we go over
Set and dupli objects or not.

Important to remember to keep the iteration of DEG_ as readonly.

Cycles is not working well for dupli groups, and it's memleaking
for dupli particles. So for now we iterate over main objects and set
only, not dupli.

To change that go in rna_scene.c and:

-DEG_OBJECT_ITER(graph, ob, DEG_OBJECT_ITER_FLAG_SET)
+DEG_OBJECT_ITER(graph, ob, DEG_OBJECT_ITER_FLAG_ALL)

Review and suggestions by Sergey Sharybin

3 years agoSuppress assert for meshes with no faces
Campbell Barton [Fri, 2 Jun 2017 06:42:39 +0000 (16:42 +1000)]
Suppress assert for meshes with no faces

3 years agoFix T51695: Border select fails w/ lamps
Campbell Barton [Fri, 2 Jun 2017 06:35:58 +0000 (16:35 +1000)]
Fix T51695: Border select fails w/ lamps

Draw order doesn't match scene order when mixing object types.

3 years agoMerge branch 'master' into blender2.8
Campbell Barton [Fri, 2 Jun 2017 05:39:25 +0000 (15:39 +1000)]
Merge branch 'master' into blender2.8

3 years agoCleanup: style
Campbell Barton [Fri, 2 Jun 2017 05:38:04 +0000 (15:38 +1000)]
Cleanup: style

3 years agoFix View3D orientation index initial value
Campbell Barton [Fri, 2 Jun 2017 05:21:56 +0000 (15:21 +1000)]
Fix View3D orientation index initial value

Would assert after transform

3 years agoFix crash using non-camera object as camera
Campbell Barton [Fri, 2 Jun 2017 05:12:39 +0000 (15:12 +1000)]
Fix crash using non-camera object as camera

Also sync with master to avoid conflicts

3 years agoPyAPI: update to bpy.types.Operator.5.py
nBurn [Fri, 2 Jun 2017 01:59:51 +0000 (21:59 -0400)]
PyAPI: update to bpy.types.Operator.5.py

This is a minor update add more information on how Blender handles modal
operators. The existing docs provide a good overview, but might not be
as helpful to those unfamiliar with modal programming. This patch also
corrects a few small grammar issues.

3 years agoEevee: Tag shadow maps to update only when necessary.
Clément Foucault [Thu, 1 Jun 2017 16:20:44 +0000 (18:20 +0200)]
Eevee: Tag shadow maps to update only when necessary.

Shadow maps are now only updated if one shadow casting object inside it's shadow bounds has been updated.

3 years agoDEG: Add per object update flag for Depsgraph.
Clément Foucault [Thu, 1 Jun 2017 14:44:24 +0000 (16:44 +0200)]
DEG: Add per object update flag for Depsgraph.

This is in order to communicate what portion of this object has changed.
For now it's just a bool, but it will be extended later.

3 years agoMove custom transform orientations to workspace
Julian Eisel [Thu, 1 Jun 2017 18:41:18 +0000 (20:41 +0200)]
Move custom transform orientations to workspace

This commit moves the list of transform orientations from scenes to workspaces.
Main reasons for this are:
* Transform orientations are UI data and should not be stored in the scene.
* Introducion of workspaces caused some (expected) glitches with transform orientations. Mainly when removing one.
* Improves code.

More technically speaking, this commit does:
* Move list of custom transform orientations from Scene to WorkSpace struct.
* Store active transform orientation index separate from View3D.twmode (twmode can only be set to preprocessor defined values now).
* Display custom transform orientation name in header when transforming in it (used to show "global" which isn't really correct).

3 years agoMain Workspace Integration
Julian Eisel [Thu, 1 Jun 2017 17:56:58 +0000 (19:56 +0200)]
Main Workspace Integration

This commit does the main integration of workspaces, which is a design we agreed on during the 2.8 UI workshop (see https://wiki.blender.org/index.php/Dev:2.8/UI/Workshop_Writeup)

Workspaces should generally be stable, I'm not aware of any remaining bugs (or I've forgotten them :) ). If you find any, let me know!
(Exception: mode switching button might get out of sync with actual mode in some cases, would consider that a limitation/ToDo. Needs to be resolved at some point.)

== Main Changes/Features
* Introduces the new Workspaces as data-blocks.
* Allow storing a number of custom workspaces as part of the user configuration. Needs further work to allow adding and deleting individual workspaces.
* Bundle a default workspace configuration with Blender (current screen-layouts converted to workspaces).
* Pressing button to add a workspace spawns a menu to select between "Duplicate Current" and the workspaces from the user configuration. If no workspaces are stored in the user configuration, the default workspaces are listed instead.
* Store screen-layouts (`bScreen`) per workspace.
* Store an active screen-layout per workspace. Changing the workspace will enable this layout.
* Store active mode in workspace. Changing the workspace will also enter the mode of the new workspace. (Note that we still store the active mode in the object, moving this completely to workspaces is a separate project.)
* Store an active render layer per workspace.
* Moved mode switch from 3D View header to Info Editor header.
* Store active scene in window (not directly workspace related, but overlaps quite a bit).
* Removed 'Use Global Scene' User Preference option.
* Compatibility with old files - a new workspace is created for every screen-layout of old files. Old Blender versions should be able to read files saved with workspace support as well.
* Default .blend only contains one workspace ("General").
* Support appending workspaces.

Opening files without UI and commandline rendering should work fine.

Note that the UI is temporary! We plan to introduce a new global topbar
that contains the workspace options and tabs for switching workspaces.

== Technical Notes
* Workspaces are data-blocks.
* Adding and removing `bScreen`s should be done through `ED_workspace_layout` API now.
* A workspace can be active in multiple windows at the same time.
* The mode menu (which is now in the Info Editor header) doesn't display "Grease Pencil Edit" mode anymore since its availability depends on the active editor. Will be fixed by making Grease Pencil an own object type (as planned).
* The button to change the active workspace object mode may get out of sync with the mode of the active object. Will either be resolved by moving mode out of object data, or we'll disable workspace modes again (there's a `#define USE_WORKSPACE_MODE` for that).
* Screen-layouts (`bScreen`) are IDs and thus stored in a main list-base. Had to add a wrapper `WorkSpaceLayout` so we can store them in a list-base within workspaces, too. On the long run we could completely replace `bScreen` by workspace structs.
* `WorkSpace` types use some special compiler trickery to allow marking structs and struct members as private. BKE_workspace API should be used for accessing those.
* Added scene operators `SCENE_OT_`. Was previously done through screen operators.

== BPY API Changes
* Removed `Screen.scene`, added `Window.scene`
* Removed `UserPreferencesView.use_global_scene`
* Added `Context.workspace`, `Window.workspace` and `BlendData.workspaces`
* Added `bpy.types.WorkSpace` containing `screens`, `object_mode` and `render_layer`
* Added Screen.layout_name for the layout name that'll be displayed in the UI (may differ from internal name)

== What's left?
* There are a few open design questions (T50521). We should find the needed answers and implement them.
* Allow adding and removing individual workspaces from workspace configuration (needs UI design).
* Get the override system ready and support overrides per workspace.
* Support custom UI setups as part of workspaces (hidden panels, hidden buttons, customizable toolbars, etc).
* Allow enabling add-ons per workspace.
* Support custom workspace keymaps.
* Remove special exception for workspaces in linking code (so they're always appended, never linked). Depends on a few things, so best to solve later.
* Get the topbar done.
* Workspaces need a proper icon, current one is just a placeholder :)

Reviewed By: campbellbarton, mont29

Tags: #user_interface, #bf_blender_2.8

Maniphest Tasks: T50521

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

3 years agoMerge branch 'master' into blender2.8
Julian Eisel [Thu, 1 Jun 2017 17:56:11 +0000 (19:56 +0200)]
Merge branch 'master' into blender2.8

3 years agoRemove comment (missed last commit)
Campbell Barton [Thu, 1 Jun 2017 15:10:34 +0000 (01:10 +1000)]
Remove comment (missed last commit)

3 years agoFix T51651: translate w/ individual origins fails
Campbell Barton [Thu, 1 Jun 2017 15:04:11 +0000 (01:04 +1000)]
Fix T51651: translate w/ individual origins fails

Regression in fix for T46892

3 years agoMerge branch 'master' into blender2.8
Sergey Sharybin [Thu, 1 Jun 2017 14:31:56 +0000 (16:31 +0200)]
Merge branch 'master' into blender2.8

3 years agoDepsgraph: Cleanup, line wraps after shortening API
Sergey Sharybin [Thu, 1 Jun 2017 14:20:48 +0000 (16:20 +0200)]
Depsgraph: Cleanup, line wraps after shortening API

3 years agoDepsgraph: Remove operation types enum
Sergey Sharybin [Thu, 1 Jun 2017 14:15:23 +0000 (16:15 +0200)]
Depsgraph: Remove operation types enum

Was only used to indicate entry/exit operation of component,
which is now done explicitly. No reason to keep something which
is unused and confusing.

3 years agoDepsgraph: use explicit marking of component entry/exit operations
Sergey Sharybin [Thu, 1 Jun 2017 14:04:35 +0000 (16:04 +0200)]
Depsgraph: use explicit marking of component entry/exit operations

This isn't used too often, and haivng such API will let us to skip
specifying operation type for all oeprations.

3 years agoDepsgraph: Cleanup, use DEG_NODE_CLASS prefix for node classes
Sergey Sharybin [Thu, 1 Jun 2017 13:42:53 +0000 (15:42 +0200)]
Depsgraph: Cleanup, use DEG_NODE_CLASS prefix for node classes

3 years agoDepsgraph: Cleanup, use DEG_NODE_TYPE prefix for depsgraph node types
Sergey Sharybin [Thu, 1 Jun 2017 13:40:02 +0000 (15:40 +0200)]
Depsgraph: Cleanup, use DEG_NODE_TYPE prefix for depsgraph node types

3 years agoDepsgraph: Remove unused argument from time source query
Sergey Sharybin [Thu, 1 Jun 2017 13:38:15 +0000 (15:38 +0200)]
Depsgraph: Remove unused argument from time source query

3 years agoDepsgraph: Remove subgraph nodes
Sergey Sharybin [Thu, 1 Jun 2017 13:14:11 +0000 (15:14 +0200)]
Depsgraph: Remove subgraph nodes

Those were never finished nor used. Again, starting from clean
state before we go into more complicated details.

3 years agoDepsgraph: Remove dead code
Sergey Sharybin [Thu, 1 Jun 2017 13:07:47 +0000 (15:07 +0200)]
Depsgraph: Remove dead code

Was never used or worked on in ages, if any of this code is
needed in the future it'll need to be redone anyway.

3 years agoDepsgraph: Remove dead code from add_time_source()
Sergey Sharybin [Thu, 1 Jun 2017 13:06:05 +0000 (15:06 +0200)]
Depsgraph: Remove dead code from add_time_source()

This was never finished or done or used, no reason to keep it.
Better to simplify things before adding complexity of overrides
and copy-on-write.

3 years agoDepsgraph: Cleanup, get rid of relation type
Sergey Sharybin [Thu, 1 Jun 2017 12:49:17 +0000 (14:49 +0200)]
Depsgraph: Cleanup, get rid of relation type

It was never actually used apart from being stored at a construciton time.
This caused some redundancy and ncertanty about which relation type to use
during construciton (often existing types were not close enough to particular
use case).

3 years agoCleanup: use row() sub-layout to expand enum properties horizontaly
raa [Thu, 1 Jun 2017 13:38:32 +0000 (16:38 +0300)]
Cleanup: use row() sub-layout to expand enum properties horizontaly

3 years agoGPUCodegen: fix missing ViewMatrix in new shading.
Clément Foucault [Thu, 1 Jun 2017 11:22:30 +0000 (13:22 +0200)]
GPUCodegen: fix missing ViewMatrix in new shading.

3 years agoGawain: Optimize shader uniform access
Sergey Sharybin [Thu, 1 Jun 2017 10:26:27 +0000 (12:26 +0200)]
Gawain: Optimize shader uniform access

Before this change Gawain was doing list lookup twice,
doing string comparison of every and each input which
is not efficient and not friendly for CPUs with small
cache size.

Now we store hash of input name together with actual
name and compare hashes first. Additionally, we do
everything in a single pass which is much better from
cache coherency point of view.

This brings Eevee cache population time from 80ms to
60ms on my desktop and from 800ms to 400ms for Clement
when navigating in a file from T50027.

Reviewers: merwin, dfelinto

Subscribers: fclem

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

3 years agoFix T51687: GPUmat evaluation of shader tree would crash uppon unknown/unsupported...
Bastien Montagne [Thu, 1 Jun 2017 10:18:57 +0000 (12:18 +0200)]
Fix T51687: GPUmat evaluation of shader tree would crash uppon unknown/unsupported socket types.

Made this resilient to unknown types, for now. Supporting specific INT
sockets (through implicit conversion to GPU_FLOAT ones) is considered nice TODO.

3 years agoCorrect select-similar end value
Campbell Barton [Thu, 1 Jun 2017 09:41:19 +0000 (19:41 +1000)]
Correct select-similar end value

3 years agoAdd Face-Map to select similar
Campbell Barton [Thu, 1 Jun 2017 06:42:14 +0000 (16:42 +1000)]
Add Face-Map to select similar

Handy for setting up face-maps,
also allows selecting all faces with no assigned map.

3 years agoFix bad index use drawing deformed face centers
Campbell Barton [Thu, 1 Jun 2017 05:04:22 +0000 (15:04 +1000)]
Fix bad index use drawing deformed face centers

3 years agoClear pose draw data in BGE pose copy
Campbell Barton [Thu, 1 Jun 2017 04:57:27 +0000 (14:57 +1000)]
Clear pose draw data in BGE pose copy

3 years agoFix custom-bone display-at option
Campbell Barton [Thu, 1 Jun 2017 03:54:29 +0000 (13:54 +1000)]
Fix custom-bone display-at option

3 years agoResolve assert in weight paint mode w/ no weights
Campbell Barton [Thu, 1 Jun 2017 03:35:27 +0000 (13:35 +1000)]
Resolve assert in weight paint mode w/ no weights

3 years agoFix bad handling of 'extra' user for groups at their creation.
Bastien Montagne [Wed, 31 May 2017 19:24:41 +0000 (21:24 +0200)]
Fix bad handling of 'extra' user for groups at their creation.

Was just keeping the default '1' user from `BKE_libblock_alloc()`,
instead of using correct way to handle extra virtual user needed when we
want to keep unused datablocks around...

3 years agoFix T51680: 'Delete Group' from Group view of Outliner does not work.
Bastien Montagne [Wed, 31 May 2017 19:14:08 +0000 (21:14 +0200)]
Fix T51680: 'Delete Group' from Group view of Outliner does not work.

Do not call invoke ops from outliner's operations menus. Invoke op would
search again for item under mouse coordinates... when it is invoked!
Means often entry menu you would have clicked would not be over target
item, leading to either nothing or operation being applied to wrong item.

Note: about groups, there is another minor annoyance leading to some
assert - groups have an annoying virtual fake user which breaks
usercount, will see whether this is easily fixable. :|

3 years agoDwM: Show wire only mesh objects
Campbell Barton [Wed, 31 May 2017 16:26:24 +0000 (02:26 +1000)]
DwM: Show wire only mesh objects

3 years agoFix manipulator immediate mode use
Campbell Barton [Wed, 31 May 2017 16:06:30 +0000 (02:06 +1000)]
Fix manipulator immediate mode use

Needs 3D coords

3 years agoMerge branch 'master' into blender2.8
Sergey Sharybin [Wed, 31 May 2017 13:51:17 +0000 (15:51 +0200)]
Merge branch 'master' into blender2.8