Commit Graph

75472 Commits

Author SHA1 Message Date
Campbell Barton
3a8099c45c Cleanup: unused vars in last commit 2019-03-18 20:30:05 +11:00
Campbell Barton
794aef3f25 Fix T58763: Sample color fails with mirror modifier 2019-03-18 20:16:21 +11:00
Campbell Barton
1d1e06b376 Cleanup: rename color band to color ramp 2019-03-18 18:26:14 +11:00
Campbell Barton
b749e43cd3 Fix color ramp eyedropper menu item
This couldn't be accessed because the poll function was checking the
active button.

Add a "color_ramp" context pointer which is set by the menu.

Alternative fix to D3984
2019-03-18 17:50:18 +11:00
Campbell Barton
8f5ba8e1a1 Cleanup: spaces around operators in DNA headers 2019-03-18 14:23:34 +11:00
Campbell Barton
317cb1dd65 Cleanup: style, duplicate include 2019-03-18 14:13:06 +11:00
Campbell Barton
6c0240e84a UI: clarify "Remap Relative" tooltip
Resolves T62612
2019-03-18 13:58:01 +11:00
Campbell Barton
c7a50d84b6 Fix T62684: Crash transforming w/ snap enabled 2019-03-18 13:42:53 +11:00
Campbell Barton
e1364b21fa Fix T62685: Rename 'Align' to 'Only Origins'
The RNA name didn't match the name used in the UI,
making the quick favourites menu show this as 'Align'.
2019-03-18 13:30:16 +11:00
Campbell Barton
9099305771 Cleanup: rename BLI_kdtree vars & args for clarity 2019-03-18 10:25:15 +11:00
Campbell Barton
4b3aafd44f BLI_kdtree: refactor boids specific logic into callback
Logic to for boids to avoid head-on collisions was in BLI_kdtree.

Move this into a callback which is now defined in boids.c
so the kdtree code can be kept generic.
2019-03-18 09:40:38 +11:00
Brecht Van Lommel
df96455c55 UI: add light/world settings in shader node editor.
Material was already there. Implementation was changed so it's just a
single line of code to adapt a panel to the node editor.
2019-03-17 21:53:13 +01:00
Antonioya
f79ad42808 GPencil: Cleanup extra lines 2019-03-17 20:04:09 +01:00
Antonioya
6577618d5b GPencil: Changes in Fill and new 3D Cursor View Plane
This commit groups several options that were tested in grease pencil branch:

- Changes to fill algorithms and improves, specially in small areas and stroke corners.
  New options has been added in order to define how the fill is working and internally there are optimizations in detect the small areas in the extremes.

  Kudos to @charlie for coding this fill improvements.

- New 3D cursor view plane option.

  Now it's possible to lock the drawing plane to the 3D cursor and use the 3D cursor orientation. This allows more flexibility when you are drawing and reduce the need to create geometry to draw over surfaces.

- Canvas Grid now can be locked to 3D cursor.
- New option to reproject stroke using 3D cursor.
- Small tweaks and fixes.

Changes reviewed by @pepeland and @mendio
2019-03-17 19:47:56 +01:00
Bastien Montagne
887d052e56 Fix T62570: Append Particles System not working properly.
T62570 and T61796 show that we need two slightly different behaviors in
post-linking collection process:
* For linking, we never want to instantiate indirectly-linked
collections or objects.
* For appending however, since all collections and objects will become
local and hence need instantiation, we want to 'link to scene' all
collections first, better than instantiating the objects in the master
collection opf current scene.
2019-03-17 18:07:13 +01:00
Bastien Montagne
94507a7fa7 Fix T62589: Particle system Instance Collection option fails to set a user for a linked collection.
Forgot to tag properly RNA property in rB439437fa3a44.
2019-03-17 16:02:00 +01:00
Luca Rood
0a25cea2cf Fix T62240: Bleed artifacts with degenerate triangles
This makes degenerate triangles be ignored, as they cause artifacts and
don't contribute to the result anyway. There is an extra cost for
all triangles, to check if they are degenerate. Though not ideal, this
seems to be the safest solution at the moment (see code comments).

This commit also changes the clamp value for the bleed len_fact from 5
to 10, to give good corner results with some sharper angles, considering
they will be rounded later.

A lot of the texture paint initialization code could be optimized
by caching the results throughout the session, instead of rerunning it
for each stroke. Stroke initialization is way too expensive at the
moment, and does many redundant computations.
2019-03-17 15:44:41 +01:00
Jacques Lucke
cfd909f184 Fix T62678: Wrong text clipping
There are two issues at play here.
First, BLF_width computed a width that was not wide
enough to actually hold the text.
Second, blf_glyph_calc_rect_test computed an incorrect
rect->xmax when the glyph was moved to the left a bit.
We ignore the overlap on the left, but the right side
should still be adjusted accordingly.
2019-03-17 14:15:26 +01:00
Antonioya
ef66aa2005 GPencil: Cancel all transformations in Draw mode
Actually, when you press G/R/S in Draw mode, the transformations can be done, but this is annoying in draw mode and must be captured an cancel.

This patch capture the transformation and cancel it.

Reviewed by @brecht
2019-03-17 12:20:34 +01:00
Campbell Barton
e04d5a8106 Fix string size passed into name prefix function 2019-03-17 21:14:43 +11:00
Campbell Barton
a19e78aa2d Cleanup: redundant layer access 2019-03-17 21:00:56 +11:00
Campbell Barton
8214712b19 Cleanup: use braces for BLI_kdtree 2019-03-17 21:00:56 +11:00
Campbell Barton
6cbd2e5c4d Cleanup: remove redundant check 2019-03-17 21:00:56 +11:00
Bastien Montagne
d23452897b Remove 3DS add-on from factory startup. 2019-03-17 09:43:32 +01:00
Campbell Barton
cc5bdf0293 Cleanup: rename DEPRECATED to UNUSED
While the flags have been deprecated they're currently unused.
Rename for clarity.
2019-03-17 10:34:59 +11:00
mano-wii
cf5097d71f Cleanup: improve comments. 2019-03-16 18:20:57 -03:00
mano-wii
8b62f203d9 ED View3d: Fix possible bug when subtracting unsigned ints.
Related to rB681661dbed12.
2019-03-16 18:10:44 -03:00
Miguel Porces
9e152f919f Python API: add Python-defined node groups for shaders and compositing.
This was already supported for Cycles shader nodes, but now also works for
Eevee and compositing nodes. Instead of a generic NodeCustomGroup, now
there is ShaderNodeCustomGroup and CompositorNodeCustomGroup that can be
subclassed and registered.

Differential Revision: https://developer.blender.org/D4370
2019-03-16 20:36:35 +01:00
Miguel Porces
5797a5fc65 Fix ID user counting issues with NodeCustomGroup.
User counting now happens before init() and after free() methods, so that
the ID users are in a valid state when Python might modify them. ID user
counting was moved into node.c and simplified.

Patch by Miguel with further refactoring by Brecht. Ref D4370.
2019-03-16 20:21:16 +01:00
Brecht Van Lommel
b9af4efe41 Cleanup: fix compiler warnings. 2019-03-16 20:21:16 +01:00
Antonioya
ad390f514b GPencil: Fix compiler warning
The fill flag was wrong and it was checking the color, not a flag.
2019-03-16 20:05:15 +01:00
Antonioya
9a4192277b GPencil: Disable Pressure for Block brush 2019-03-16 18:56:07 +01:00
Campbell Barton
cabb53effa Correct error in 6aebb5a4d5 2019-03-16 21:49:33 +11:00
Campbell Barton
37af7ce779 DRW: support clipping for armature bone axes
Also minor changes to make empty axis match armature axis.
2019-03-16 18:43:36 +11:00
Campbell Barton
c55fb58e8a DRW: support clipping for envelope armature draw type 2019-03-16 18:26:16 +11:00
Campbell Barton
6aebb5a4d5 DRW: support clipping for relationship lines 2019-03-16 17:37:08 +11:00
Clément Foucault
dbfbd6b904 Fix T62555 Viewport borders flicker when splitting said viewport 2019-03-16 03:58:00 +01:00
Clément Foucault
d438120fe3 Fix T61526 hair doesn't render in workbench but does with openGL 2019-03-16 02:48:19 +01:00
Campbell Barton
bd1d80d0cf Cleanup: use return args last 2019-03-16 11:45:22 +11:00
Clément Foucault
3600bb79d0 Fix T60803 Artifacts with SSR + Reflection Plane + 0 roughness
Tweaked the tracing parameters again to avoid rays terminated before first
iteration.
2019-03-16 00:51:38 +01:00
Campbell Barton
44301175bb Fix __func__ being passed as an output string, also warnings 2019-03-16 10:12:47 +11:00
Clément Foucault
795bddf2bd Fix T55620 Artifacts with SSR and planar reflection
Was caused by 0 pixel extent rays which did not trace at all. Bumping the
threshold for degenerate rays fixes it.
2019-03-15 23:31:41 +01:00
Clément Foucault
86646dab7c Fix T62621 object scale changes tangent node output in Eevee
Normal Matrices were not normalized, leading to non-normalized vector
rotations results.
2019-03-15 22:33:03 +01:00
Clément Foucault
1d6009d7aa Eevee: Fix tangent being renormalized after interpolation 2019-03-15 22:33:02 +01:00
Clément Foucault
66225e84cf Eevee: DOF: Optimization: Move some operations out of the shader 2019-03-15 22:33:02 +01:00
Clément Foucault
fe40e184a6 Fix T61857 Eevee DOF not working if the camera is in orthographic mode
It was just a bad mapping of the ogl depth to scene linear depth.
2019-03-15 22:33:02 +01:00
Clément Foucault
efdde88dfc Particle: Remove Billboard Particle code
The billboard particles were only used by Blender Internal. So until it is
supported by Cycles of Eevee there is no reason to keep it in the code and
UI.

Fix T61695 Billboard particles not displaying in Eevee viewport, render
2019-03-15 22:33:02 +01:00
Dalai Felinto
aaa35d1092 Silence warning from recent GPU simplify commit
Said commit introduced warnings and build problens. Let's be more
careful in the future. Warnings are not to be treated lightly either.
2019-03-15 18:15:31 -03:00
Jens Verwiebe
ddd28bad90 Fix compiling after last commit 2019-03-15 22:07:09 +01:00
mano-wii
681661dbed GPU: Simplify select shaders.
The shaders are: `GPU_SHADER_3D_FLAT_SELECT_ID` and `GPU_SHADER_3D_UNIFORM_SELECT_ID`.
This commit allows the drawing of the mesh select ids to be done on a 32UI format texture.
This simplifies the shader that previously acted on the backbuffer and had to do an uint to rgba conversion.

Differential Revision: https://developer.blender.org/D4350
2019-03-15 17:02:48 -03:00