Commit Graph

66560 Commits

Author SHA1 Message Date
Clément Foucault
f4261cd2ed Workbench: Remove unused framebuffer slot. 2018-12-05 02:51:48 +01:00
Campbell Barton
5c59244238 Object: select objects when revealing
Matches behavior for other modes.
2018-12-05 12:12:07 +11:00
Campbell Barton
8fb3a222a1 Fix T58690: Disable overlay doesn't hide bones 2018-12-05 11:08:50 +11:00
Campbell Barton
9c963d363e Merge branch 'master' into blender2.8 2018-12-05 11:03:48 +11:00
Campbell Barton
45c11c1a1b Fix T49624: Fly uses camera settings outside camera view 2018-12-05 08:36:37 +11:00
Antonioya
b83cf9d340 GP: Enable Smooth Sculpt brush when press Shift key 2018-12-04 22:35:17 +01:00
Dalai Felinto
be012c88c5 Cleanup: Action zone coordinates
No functional changes, but it makes all the coordinates more consistent
(going from small to larger values). It helps debugging in the future
to be able to rule out vertex order as a culprit.
2018-12-04 17:42:31 -02:00
Dalai Felinto
7c56ac2355 Fix area splitting from action zone flipping viewports
The top-left and bottom-right corners were creating the new area in the
wrong place.

Blender 2.7x only had action zone corners in the top-right, and
bottom-left corners. So it had some hardcoded assumptions based on that.

This commit feels a bit like a hack, but I think it may be fine.

Bug reported via IRC, how to reproduce:

* Change shading to Rendered.
* Split viewport from the top-left corner.
2018-12-04 17:42:31 -02:00
Gaia Clary
baf89af0f5 Merge remote-tracking branch 'origin/master' into blender2.8 2018-12-04 20:31:30 +01:00
Gaia Clary
22bba02bc8 fix T58568: used wrong case in variable name 2018-12-04 20:28:20 +01:00
Gaia Clary
5c3955452b Merge branch 'master' into blender2.8 2018-12-04 19:48:21 +01:00
Gaia Clary
10c50d7dbf fix T58568 build errors when using collada 1.6.68 or newer 2018-12-04 19:11:57 +01:00
Alexander Gavrilov
34b73cb11c Fix T57620: display custom normals in Edit Mode.
Since it seems that CD_ORIGINDEX is not available for loops,
the only choice is to simply use the loop normals already
computed by depsgraph after evaluating modifiers.

This revealed a bug where the Auto Smooth settings would be lost
from the mesh after complex modifiers, or after edit mesh to mesh
conversion, so restoring them is needed to get correct results.
2018-12-04 19:53:14 +03:00
Clément Foucault
7e5f31be41 Fix T58609 Subdivision Surface modifier, "Optimal Display" not working
I tried to make it progressive using the wireframe slide but it did not
work well.

So taking the most straight forward way.
2018-12-04 17:52:32 +01:00
Clément Foucault
6f198f7851 Wireframe: Optimization: Only draw triangles that have edges
This only happens after a certain wireframe threshold.

We sort triangles into 2 bins (start and end of the buffer) based on a
threshold and just draw the first bin if the wireframe slider is low enough.

This optimization is disabled for deformed meshes when playback is active.
This optimization is only implemented for meshes object for now.

This should help resolve (to some extent) T58188.
2018-12-04 17:52:32 +01:00
Clément Foucault
f1975a4639 Wireframe: Optimization: Only draw triangles that have edges
This only happens after a certain threshold.

We sort triangles into 2 bins (start and end of the buffer) based on a
threshold and just draw the start bin if the wireframe slider is low enough.

This optimization is disabled for deformed meshes.

This should help resolve (to some extent) T58188.
2018-12-04 17:52:32 +01:00
Clément Foucault
89ef69d23c Wireframe: Optimization: Output degenerate triangles if no edges 2018-12-04 17:52:32 +01:00
Bastien Montagne
6a0c25b447 Fix T58700: Modifier error msgs not showing.
We need to copy those back from evaluated modifierdata to orig one (as
part of `BKE_object_synchronize_to_original()`).
2018-12-04 17:07:47 +01:00
Bastien Montagne
64474fbc22 Cleanup: typo in comments. 2018-12-04 16:56:54 +01:00
Sergey Sharybin
be91d4ef95 Fix T55774: Crash when reloading clip during prefetch
Simply kill prefetch jobs when reloading. Not sure what else
we can do here..
2018-12-04 16:40:04 +01:00
Sergey Sharybin
cf2e35fcfe Fix T58118: Make duplicates real does nothing
The issue was caused by transflag set in geometry evaluation
never copied back top original object.

Now we have a dedicated operation which does all sort copy
back to original object, so we don't have to worry about
atomic assignments or what gets set where.

Still need to move boundbox to the same function, but it
needs some careful doublechecking first.
2018-12-04 16:04:10 +01:00
Sergey Sharybin
e666ee965c Fix T58227: Subdivision Surface Type Simple messes up UVs
This seems to be a bug in OpenSubdiv. For now simply use Catmark
subdivision scheme with infinitely sharp edges.

Later on it's either gets fixed in OpenSubdiv or we do bilinear
subdivision on our side.
2018-12-04 15:18:37 +01:00
Sergey Sharybin
3d013f7b10 Fix for assert failure in material preview
All localized datablocks are not supposed to have animation
data associated with them.

There was an easy way to reproduce assert failure: toggle
animation decorator for Viewport Display -> Color.
2018-12-04 12:31:32 +01:00
Sergey Sharybin
e6141d7b3b Fix T58117: Crash with keyframing, take two
More operators need to become aware of action possibly being gone.
2018-12-04 12:31:32 +01:00
Alexander Gavrilov
b97cd0e690 Depsgraph: execute all COPY_ON_WRITE nodes first as a separate stage.
COW nodes in the graph are mostly connected via a relation type
that doesn't propagate the update flags. Unfortunately, due to
the scheduling implementation that means the relations don't
actually guarantee execution order for indirect dependencies.
Relations also don't guarantee order in case of cycles.

As mentioned in IRC, the simplest way to fix possible problems
is to execute all COW nodes as a separate execution stage. This
seems to fix crashes with Data Transfer modifier in a cycle.

Staging works by simply delaying actual scheduling of tasks for
non-COW nodes until the second run of schedule_graph.

Reviewers: sergey

Differential Revision: https://developer.blender.org/D4027
2018-12-04 14:08:50 +03:00
Alexander Gavrilov
01581d4a1e BLI_task: fix queue in work_and_wait, and support resetting.
To make the pool more usable for running multiple stages of tasks,
fix local queue handling in BLI_task_pool_work_and_wait.

Specifically, after the wait loop the local queue should be empty,
or the wait part of the function contract isn't fulfilled. Instead,
check and run any tasks in queue before the wait loop.

Also, add a new function that resets the suspended state of the pool.
2018-12-04 14:08:50 +03:00
Bastien Montagne
c86e828eee Fix (IRC reported) missing update for RNA Object's matrix_local property.
Reported by @zeffii, thanks!
2018-12-04 12:06:24 +01:00
Sergey Sharybin
df2635099b Merge branch 'master' into blender2.8 2018-12-04 11:45:22 +01:00
Sergey Sharybin
3f31ec8398 Cleanup: Spelling 2018-12-04 11:43:53 +01:00
Sergey Sharybin
c6f47ffa98 Fix T58117: Crash with keyframing 2018-12-04 11:28:54 +01:00
Bastien Montagne
6330b715ef Fix T58220: EdgeSplit at Split Angle: 0 doesn't split flat faces.
Add special handling for both edge cases (:p):
* 180° is same as no splitting by angle;
* 0° is same as split on all edges unconditionnaly.

In both cases we can also avoid computing poly normals.
2018-12-04 10:51:19 +01:00
Sergey Sharybin
36ca072375 Fix T58481: "Make duplicates real" operator settings crashes 2018-12-04 10:18:21 +01:00
Philipp Oeser
b16f03566b Show tool title for favorites menu 2018-12-04 16:14:21 +11:00
Campbell Barton
61678ca8ae Fix T57076: Remove property from favourites menu fails 2018-12-04 15:11:26 +11:00
Campbell Barton
e7641b6834 Edit last commit
Split out ensure-tool check into its own function.
2018-12-04 14:33:45 +11:00
Campbell Barton
80816fc712 Fix T58256: error message w/ missing Select Box tool
Support space modes not having tools.
2018-12-04 13:55:50 +11:00
Campbell Barton
2ff79613a8 Fix T58670: Spin tool crashes w/o gizmo overlay 2018-12-04 13:00:10 +11:00
Campbell Barton
1b6a394d86 Cleanup: unused args 2018-12-04 10:39:03 +11:00
Campbell Barton
c631782542 Fix T58474: Gizmo Operator template fails on rerun 2018-12-04 10:17:42 +11:00
Charlie Jolly
2c19c9b2f6 GP: Draw Mode: Add Arc Primitive
This adds an elliptical arc primitive.
Press CKEY for toggling closed/open arc.
Press FKEY key for flipping arc.

Additional changes to gpencil primitives.
Increases default edges of circle to 64.
Keymap changes to allow primitives to be drawn with Shift or Alt key.
Allow Plus/Minus key to adjust number of edges.

Missing: Toolbar icon

Differential Revision: https://developer.blender.org/D4024
2018-12-03 22:11:38 +00:00
Brecht Van Lommel
f0432e37ab Fix T58636: repeat image in UV editor not working.
A little too much code got removed in fb24813.
2018-12-03 20:08:20 +01:00
Alexander Gavrilov
9637a17856 Depsgraph: immediately free object's derived caches in the COW step.
After update of the mesh some of that data is so broken that using
it would crash. To reduce the risk of crashes in case of dependency
cycles, clean it up immediately.
2018-12-03 20:48:47 +03:00
Clément Foucault
65779b022d Fix T58280: Blender 2.8 hangs when the LookDev mode is enabled
The hang was due to the nodes being "evaluated" for every incomming link.

Solution: only evaluate once per nodetree.

Also merge the tagging of SSS and SSR into one traversal only.
2018-12-03 17:19:11 +01:00
Clément Foucault
95eca49e54 DRW: Make default debug mode a bit more silent
Use --debug-gpu for debugging non found uniforms
2018-12-03 17:19:11 +01:00
Clément Foucault
0759480529 Workbench: Encode Roughness and metallic into 8bits
This reduces the bandwidth + vram usage of workbench even further.
2018-12-03 17:19:11 +01:00
Clément Foucault
223c1a107a Workbench: Make object ID pass optionnal
We separate the background and foreground shading passes to be able to make
the object id pass optionnal if we don't need it.

This saves a bit more memory. Also not clearing all rendertargets saves
some GPU time too.
2018-12-03 17:19:11 +01:00
Clément Foucault
a022811441 DRW: Make fullscreen quad in the background
This is to be able to only draw the background pixels by using a depth
test EQUAL.
2018-12-03 17:19:11 +01:00
Clément Foucault
d8d52e273e Workbench: Cleanup: Remove Spherical harmonic evaluation
It is not used anymore
2018-12-03 17:19:11 +01:00
Clément Foucault
82f01c666f View3D: Grid: Don't make the Zaxis produce any fragment is not needed
This was a bug that was making the grid drawing even more slower than it
is.
2018-12-03 17:19:11 +01:00
Clément Foucault
24fd03d0c2 Workbench: Reduce VRAM usage depending on mode
We exploit the fact that we are using the metallic workflow for material
and pass the metallic parameter instead of the specular color.

Pack the front facing bit in the color buffer only for matcap display.

Change buffer formats to use less bytes as possible.

Also don't request buffers that we won't use.

Saved 40MB on 2K screen on StudioLight + Shadows + Specular Lighting.

Includes several cleanups.
2018-12-03 17:19:11 +01:00