Commit Graph

75472 Commits

Author SHA1 Message Date
Bastien Montagne
cd5ee24656 Operators: add a new flag stating that operator needs access to evaluated data.
For now, that flag is only used in redo code, since after undo step
depsgraph is totally empty... We *may* want to add at least an assert in
op calling code too, though?
2018-08-03 10:15:34 +02:00
Bastien Montagne
b5a1e3d471 Depsgraph: add helper to ensure a given scene/view_layer graph is up-to-date.
Since that call make the graph active, it should only be used in active
editing context aware code (i.e. essentially, operators).
2018-08-03 10:13:33 +02:00
Clément Foucault
f55863acd4 DRW: Augment Debug messages 2018-08-03 09:49:31 +02:00
Clément Foucault
fa0f938b11 Eevee: Fix assert with hair drawing
This remove unused clip_block when not needed and the useless ubo bind that
were put there for the sake of not crashing.
2018-08-03 09:49:31 +02:00
Campbell Barton
3eab49dd36 Icons: add particle brush icons 2018-08-03 11:43:50 +10:00
Clément Foucault
2a8413a0dd Eevee: Don't show probe display when not using scene lighting
The display is broken otherwise.
2018-08-02 21:12:08 +02:00
Clément Foucault
9887b32e73 Eevee: Fix missing UBO bind. 2018-08-02 20:52:07 +02:00
Antonioya
836db3aee8 Add Assign Material option to Special menu (W key)
Also some renames and cleanups.
2018-08-02 19:35:29 +02:00
Antonioya
45751065c0 Add list of color to Assign color operator
It's more clear for user to see the name of the color
2018-08-02 19:21:23 +02:00
Clément Foucault
acdb136dce DRW: Add UBO binding checking routine. 2018-08-02 18:33:49 +02:00
Clément Foucault
e7adf1dfb0 Cleanup: Fix compilation warnings. 2018-08-02 18:33:49 +02:00
Clément Foucault
bd7ab6b989 DRW: Cleanup: Fix header naming. 2018-08-02 18:33:49 +02:00
Clément Foucault
8f6ff3adfa GPUShader: Add name for debugging & identifying shaders. 2018-08-02 18:33:49 +02:00
Clément Foucault
3578212e46 Eevee: Fix missing UBO binds.
Some of them are unecessary and should be removed from the shader instead.

But for now we need a quick fix for the crashes happening on some platforms.

See T55475.
2018-08-02 18:33:49 +02:00
Antonioya
ce551ada92 Fix missing type for material arry
This function was called by RNA Api and had grease pencil object type missing.
2018-08-02 18:03:01 +02:00
Antonioya
909556aa26 Fix wrong RNA Api parameter definition 2018-08-02 17:45:32 +02:00
Bastien Montagne
9914c05bd7 Depsgraph: fix some DEG queries crashing with new, empty graph.
Calling code is responsible to check on NULL pointers here, or ensure
is does have a fully built and evaluated depsgraph, but this should
never crash in DEG queries themselves.
2018-08-02 17:17:04 +02:00
Bastien Montagne
771973869d Fix assert in UI string trimming code when we have 'protected' right part. 2018-08-02 16:39:15 +02:00
Campbell Barton
f36855f0fd UI: show all particle brush settings in topbar
Also show particle brush in tool-properties panel.
2018-08-02 22:10:38 +10:00
Sergey Sharybin
200212079d Subsurf: Better crease which represents sharp edges
Enabled infinite sharp patches for topology refiner and evaluator,
which allows to have sharp edge at first subdivision level.

Also tweaked crease export from Blender to OpenSubdiv to have more
artistic control over the whole 0..1 range.
2018-08-02 12:24:55 +02:00
Campbell Barton
3a93314753 Tool System: initial particle system support 2018-08-02 19:27:26 +10:00
Campbell Barton
d79df6c0bc Tool System: sync changes from changes to brushes
Changing a brush now updates the tool.
2018-08-02 18:18:53 +10:00
Campbell Barton
d3c387d605 Merge branch 'master' into blender2.8 2018-08-02 17:52:22 +10:00
Campbell Barton
cb6d7cb0b2 RNA: make particle enum public 2018-08-02 17:49:03 +10:00
Joshua Leung
503866c681 Fix T56199: Crash on Annotation in (VSE) Image Preview
In some cases (e.g. using old userpref settings/keymaps)
it was possible to trigger a crash when the wrong GP/Annotation
operators were triggered in the wrong contexts (e.g. using
the old GPENCIL_OT_paint in annotation-only contexts like
all the 2D editors).

This commit resolves several issues that were caused by sloppy
code-churn + features that had been hacked on.
2018-08-02 16:35:43 +12:00
Joshua Leung
0fdd058991 Dev Tooling: Instrument motion path calculation operator (for bones) to collect timing data
This will be useful for checking on the progress of our optimisation
efforts, and to generate some nice stats for later.
2018-08-02 15:04:58 +12:00
Pablo Vazquez
ab49b7d739 UI: Slightly larger action zone for corner resizing
Pretty minor, from 0.6 to 0.8, but the improvement is noticeable
especially when using a stylus, without overlapping too much with
the buttons and dropdowns in headers.
2018-08-02 01:26:58 +02:00
Campbell Barton
918288138d Cleanup: warnings, trailing space 2018-08-02 08:26:57 +10:00
Clément Foucault
504454ee5e GPUMaterial: Normal Map Node: Make default inputs interactives 2018-08-01 22:08:36 +02:00
Clément Foucault
48e661e05d GPUMaterial: Fix assert when shader failed to compile. 2018-08-01 22:08:36 +02:00
Clément Foucault
e8dd5e5cc6 GPUMaterial: Make Mapping node use UBO storage
This means tweaking parameter is now interactive and does not need to
recompile the shaders.
2018-08-01 22:08:36 +02:00
Clément Foucault
ad64cb6344 GPUMaterial: Make Localize tree live longer
This is in order to reference the localized node->storage when populating
the UBO data.
2018-08-01 22:08:36 +02:00
Clément Foucault
4510f30026 GPUMaterial: Fix nearest sampling
texelFetch return vec4(0.0) if the target pixel is outside the texture
rect. So we mimic the default repeate mode that we have for linear
interpolation.

Fix T56156 Mapping-Node doesn't work
2018-08-01 22:08:36 +02:00
Clément Foucault
c6f55fb0db GPUUniformBuffer: Fix bad memcpy error catched by asan
We need to copy the size of the gputype not the padded type.
2018-08-01 22:08:36 +02:00
Sergey Sharybin
86270b60db Subsurf: Evaluate all UV layers
Before that it was only first UV layer which was properly evaluated,
the rest were ignored. Now all layers are being properly handled.
2018-08-01 18:43:03 +02:00
Sergey Sharybin
5b3b0ed54f Subsurf: Add API to provide vertex sharpness
Currently unused, added for the future and API completeness.
2018-08-01 18:42:59 +02:00
Sergey Sharybin
4fe14d6a26 Subsurf: Support subdivision of mesh with just loose elements 2018-08-01 18:42:59 +02:00
Sergey Sharybin
63058490a3 Subsurf: Cleanup, remove unused mappings and topology queries 2018-08-01 18:42:59 +02:00
Sergey Sharybin
ec4ba68730 Subsurf: Fix/workaround crashes and failures with non-manifold geometry
The idea is simple: do not provide full topology to OpenSubdiv, leave
edges creation to OpenSubdiv itself. This solves issues with non-manifold
meshes which were known to fail, including the ones from T52059.

On a positive side we can simplify our side of converter, keeping code
shorter.

it is still possible that we'll need to ensure all loops has same
winding, but that is less things to worry about.
2018-08-01 18:42:59 +02:00
Sergey Sharybin
08e6bccdf4 Subsurf: Support subdivision of loose elements
Applies to vertices and edges. Biggest annoyance here is that OpenSubdiv's
topology converter expects that there is no loose geometry, otherwise it
is getting confused.

For now solution is to create some sort of mapping from real Mesh vertex
and edge index to a non-loose-index. Now the annoying part is that this
is an extra step to calculate before we can compare topology, meaning FPS
will not be as great as if we knew for sure that topology didn't change.

Loose edges subdivision is different from what it used to be with old
subdivision code, but probably nice feature now is that endpoints of loose
edges are stay at the coarse vertex locations. This allows to have things
like plane with hair strands, without need to duplicate edge vertices at
endpoints.

All this required some re-work of topology refiner creation, which is now
only passing edges and vertices which are adjacent to face. This is how
topology refiner is supposed to be used, and this is how its validator
also works. Vertices which are adjacent to loose edges are marked as
infinite sharp. This seems to be good-enough approximation for now. In the
future we might tweaks things a bit and push such vertices in average
direction of loose edges, to match old subdivision code closer.
2018-08-01 18:42:59 +02:00
Sergey Sharybin
9e2f678ba2 Fix mistake in atomic bitmap
Internally values are stored as 32bit integers, no idea why i thought
they were 8 bit.
2018-08-01 18:42:59 +02:00
Sergey Sharybin
63dc52c66e Subsurf: Cleanup, remove dead code 2018-08-01 18:42:59 +02:00
Bastien Montagne
110abebe1d Fix missing poll function for flip_matcap operator (see T56183). 2018-08-01 17:28:30 +02:00
Bastien Montagne
be5ccb9ce8 Merge branch 'master' into blender2.8 2018-08-01 16:13:13 +02:00
Bastien Montagne
9336aef4eb Fix T56195: Typo in BLI_array_utils.h. 2018-08-01 16:12:36 +02:00
Brecht Van Lommel
c48eb52164 Fix Cycles headless render failing, after grease pencil merge.
Now it should at least succeed when there are no grease pencil objects.
2018-08-01 14:47:02 +02:00
Bastien Montagne
cc004fd13c Some more minor typo fixes in comments. 2018-08-01 14:37:24 +02:00
Bastien Montagne
9a43ebdd5b Fix more merge stupid leftover, and some build warnings. 2018-08-01 14:29:36 +02:00
Bastien Montagne
ef8ab3b4c2 Fix issues after last 2.8 merge. 2018-08-01 14:21:45 +02:00
Bastien Montagne
936d1cef6e Merge branch 'blender2.8' into soc-2018-bevel
Conflicts:
	release/scripts/addons
	release/scripts/startup/bl_ui/space_view3d_toolbar.py
	source/blender/editors/space_outliner/outliner_draw.c
2018-08-01 14:16:41 +02:00