blender.git
9 months agoEEVEE: Cleanup remove unused shader.
mano-wii [Mon, 19 Nov 2018 10:55:59 +0000 (08:55 -0200)]
EEVEE: Cleanup remove unused shader.

9 months agoBKE object: Correct bound box of bezier curve objects not matching the object viewed.
mano-wii [Mon, 19 Nov 2018 10:54:49 +0000 (08:54 -0200)]
BKE object: Correct bound box of bezier curve objects not matching the object viewed.

9 months agoThemes: Remove deprecated themes.
Pablo Vazquez [Mon, 19 Nov 2018 11:31:00 +0000 (12:31 +0100)]
Themes: Remove deprecated themes.

Most themes have missing/wrong settings due to the new editors in 2.8

A Call-for-content has been made at devtalk.blender.org for the community to contribute new ones.

9 months agoFix T57889: Crashes on undo and redo while working with image or image empty
Sergey Sharybin [Mon, 19 Nov 2018 11:04:02 +0000 (12:04 +0100)]
Fix T57889: Crashes on undo and redo while working with image or image empty

9 months agoRNA: re-enable update notifier flags
Campbell Barton [Mon, 19 Nov 2018 10:00:14 +0000 (21:00 +1100)]
RNA: re-enable update notifier flags

This was causing too many missing updates and each need investigation
which won't happen before beta.

9 months agoPy API Docs: Fix wrong type
Jacques Lucke [Thu, 15 Nov 2018 16:21:04 +0000 (17:21 +0100)]
Py API Docs: Fix wrong type

9 months agoTool System: improve popup w/ modifier keys
Campbell Barton [Mon, 19 Nov 2018 03:39:25 +0000 (14:39 +1100)]
Tool System: improve popup w/ modifier keys

When the toolbar is accessed with modifiers (eg shift-space):

- Check if we can use the key without any modifiers to set the cursor.
- Pie-menu stile release event no longer checks for modifiers.

9 months agoCleanup: style
Campbell Barton [Mon, 19 Nov 2018 02:37:18 +0000 (13:37 +1100)]
Cleanup: style

9 months agoCleanup: use define for key-config string
Campbell Barton [Mon, 19 Nov 2018 02:16:18 +0000 (13:16 +1100)]
Cleanup: use define for key-config string

9 months agoFix keymap loading multiple times
Campbell Barton [Mon, 19 Nov 2018 02:07:57 +0000 (13:07 +1100)]
Fix keymap loading multiple times

Blender defaults data-file was loading it's own key-map
with a capital 'B', the preset would load it again w/ a lowercase name.

Use lowercase key-map names.

9 months agoFix tool-system popup and tips w/ empty keymap
Campbell Barton [Mon, 19 Nov 2018 00:56:22 +0000 (11:56 +1100)]
Fix tool-system popup and tips w/ empty keymap

That this looks like an issue loading keymaps correctly,
needs to be investigated.

9 months agoGizmo: tweak navigation highlight display
Campbell Barton [Mon, 19 Nov 2018 00:38:48 +0000 (11:38 +1100)]
Gizmo: tweak navigation highlight display

Show occluded axis highlight on top when pointing away.

9 months agoMerge branch 'master' into blender2.8
Campbell Barton [Sun, 18 Nov 2018 21:54:07 +0000 (08:54 +1100)]
Merge branch 'master' into blender2.8

9 months agoLinux: list GVFS mount points
Roel Koster [Sun, 18 Nov 2018 21:34:04 +0000 (08:34 +1100)]
Linux: list GVFS mount points

9 months agoFix object box select new w/o any objects
Campbell Barton [Sun, 18 Nov 2018 20:21:14 +0000 (07:21 +1100)]
Fix object box select new w/o any objects

A new selection with no objects found needed to de-select all.

9 months agoCleanup: naming
Campbell Barton [Sun, 18 Nov 2018 20:06:38 +0000 (07:06 +1100)]
Cleanup: naming

9 months agoCleanup: naming
Campbell Barton [Sun, 18 Nov 2018 20:04:24 +0000 (07:04 +1100)]
Cleanup: naming

9 months agoKeymap: move left click select to a preference
Campbell Barton [Sun, 18 Nov 2018 19:14:20 +0000 (06:14 +1100)]
Keymap: move left click select to a preference

9 months agoGP: Harmonize Sculpt Struct and field names
Antonioya [Sun, 18 Nov 2018 18:28:54 +0000 (19:28 +0100)]
GP: Harmonize Sculpt Struct and field names

Changed the following names:

- GP_EditBrush_Data->GP_Sculpt_Data
- eGP_EditBrush_Types->eGP_Sculpt_Types
- eGP_EditBrush_Flag->eGP_Sculpt_Flag
- eGP_BrushEdit_SettingsFlag->eGP_Sculpt_SettingsFlag
- GP_BrushEdit_Settings->GP_Sculpt_Settings
- GP_EDITBRUSH_FLAG*->GP_SCULPT_FLAG*
- GP_EDITBRUSH_TYPE*->GP_SCULPT_TYPE*
- GP_BRUSHEDIT_FLAG_*->GP_SCULPT_SETT_FLAG_*

9 months agoGP: Rename GPENCIL_OT_brush_paint to GPENCIL_OT_sculpt_paint
Antonioya [Sun, 18 Nov 2018 17:07:16 +0000 (18:07 +0100)]
GP: Rename GPENCIL_OT_brush_paint to GPENCIL_OT_sculpt_paint

This makes the operator name more consistent. Part of T57818

9 months agoFix T57835: Textured-fill layer opacity not working
Antonioya [Sun, 18 Nov 2018 15:28:57 +0000 (16:28 +0100)]
Fix T57835: Textured-fill layer opacity not working

This was an unsupported feature.

9 months agoFix T57896: Crash updating grease pencil material preview
Sergey Sharybin [Sun, 18 Nov 2018 14:56:14 +0000 (15:56 +0100)]
Fix T57896: Crash updating grease pencil material preview

9 months agoKeymaps: make click event use position on button press rather than release.
Brecht Van Lommel [Sun, 18 Nov 2018 11:14:55 +0000 (12:14 +0100)]
Keymaps: make click event use position on button press rather than release.

This may improve reliability with left click select and pen input, assuming
that the place where the pen first touched the surface is closer to the
intended location than where it was released from the surface.

I'm not sure if this will make a significant difference in practice, but it
seems worth a try.

9 months agoGP: Set Rim Blur default to 0
Antonioya [Sun, 18 Nov 2018 09:21:37 +0000 (10:21 +0100)]
GP: Set Rim Blur default to 0

9 months agoKeymap: preference to swap space/shift-space keys
Campbell Barton [Sun, 18 Nov 2018 02:22:58 +0000 (13:22 +1100)]
Keymap: preference to swap space/shift-space keys

This option is for animators who may not use the tool-system much
(mostly staying in object/pose-mode with the transform-tool active).

9 months agoKeymap: add user-prefs to the default keyconfig
Campbell Barton [Sun, 18 Nov 2018 01:41:05 +0000 (12:41 +1100)]
Keymap: add user-prefs to the default keyconfig

Currently the only option is to use select-all as a toggle.

9 months agoKeymap: Default pref for select-all to toggle
Campbell Barton [Sun, 18 Nov 2018 01:35:01 +0000 (12:35 +1100)]
Keymap: Default pref for select-all to toggle

Access in the UI next.

9 months agoUI: show active keymap user preferences
Campbell Barton [Sun, 18 Nov 2018 01:31:36 +0000 (12:31 +1100)]
UI: show active keymap user preferences

9 months agoPyAPI: add bpy.utils.execfile
Campbell Barton [Sun, 18 Nov 2018 00:49:03 +0000 (11:49 +1100)]
PyAPI: add bpy.utils.execfile

Wraps `importlib.util`, avoids duplicate preset loading calls.

9 months agoCleanup: tweak to keymap layout args
Campbell Barton [Sun, 18 Nov 2018 00:16:25 +0000 (11:16 +1100)]
Cleanup: tweak to keymap layout args

Needed to support user-keyconfig draw call.
No functional changes.

9 months agoGP: Set Thickness default to 2
Antonioya [Sat, 17 Nov 2018 18:28:10 +0000 (19:28 +0100)]
GP: Set Thickness default to 2

New modifiers have thsi default value.

9 months agoEevee: Optimize Color Ramp node for common cases.
Clément Foucault [Sat, 17 Nov 2018 17:20:10 +0000 (18:20 +0100)]
Eevee: Optimize Color Ramp node for common cases.

9 months agoEevee: Fix SSR/SSS when the bsdf nodes are inside groups
Clément Foucault [Sat, 17 Nov 2018 16:08:21 +0000 (17:08 +0100)]
Eevee: Fix SSR/SSS when the bsdf nodes are inside groups

9 months agoGPU: Cleanup / Opti : Vectorize + MADD and remove unused function
Clément Foucault [Sat, 17 Nov 2018 13:55:53 +0000 (14:55 +0100)]
GPU: Cleanup / Opti : Vectorize + MADD and remove unused function

9 months agoFix T53750: Mirrored UV have bad tangent space
Clément Foucault [Sat, 17 Nov 2018 13:52:03 +0000 (14:52 +0100)]
Fix T53750: Mirrored UV have bad tangent space

I feel silly because it was my fault all along! (see the WATCH IT warning)

9 months agoBLI: Math: Add normal_float_to_short_v4
Clément Foucault [Sat, 17 Nov 2018 13:45:59 +0000 (14:45 +0100)]
BLI: Math: Add normal_float_to_short_v4

9 months agoDRW: Fix object wire appearing when object is drawn as bounds
Clément Foucault [Sat, 17 Nov 2018 12:27:28 +0000 (13:27 +0100)]
DRW: Fix object wire appearing when object is drawn as bounds

9 months agoCleanup: correct variable names
Campbell Barton [Sat, 17 Nov 2018 11:21:01 +0000 (22:21 +1100)]
Cleanup: correct variable names

9 months agoCleanup: style
Campbell Barton [Sat, 17 Nov 2018 11:20:04 +0000 (22:20 +1100)]
Cleanup: style

9 months agoCleanup: correct const usage
Campbell Barton [Sat, 17 Nov 2018 11:22:45 +0000 (22:22 +1100)]
Cleanup: correct const usage

9 months agoDraw Manager: Fix memory leak
mano-wii [Sat, 17 Nov 2018 02:23:17 +0000 (00:23 -0200)]
Draw Manager: Fix memory leak

10 months agoFix T57874: Crash due to IMM_BUFFER_SIZE when drawing cached frames...
Clément Foucault [Fri, 16 Nov 2018 18:26:23 +0000 (19:26 +0100)]
Fix T57874: Crash due to IMM_BUFFER_SIZE when drawing cached frames...

... in the timeline.

10 months agoUI: Eevee: Rename Volume Exponential Sampling to Distribution
Clément Foucault [Fri, 16 Nov 2018 18:24:55 +0000 (19:24 +0100)]
UI: Eevee: Rename Volume Exponential Sampling to Distribution

10 months agoEevee: SSR: Only fade based on reflected pixel position
Clément Foucault [Fri, 16 Nov 2018 13:02:53 +0000 (14:02 +0100)]
Eevee: SSR: Only fade based on reflected pixel position

Not on reflector pixel position. This improve the feel of SSRs and the
final render quality.

10 months agoFix crash when rendering a scene first and then goes to eevee preview modes and cleanup
mano-wii [Fri, 16 Nov 2018 15:46:13 +0000 (13:46 -0200)]
Fix crash when rendering a scene first and then goes to eevee preview modes and cleanup

The crash only occurs with Intel 3rd generation GPUs.
It occurs because the program needs to be used at least once in the opengl context in which it is created.

10 months agoCleanup: removes unused varyings
mano-wii [Thu, 15 Nov 2018 11:15:02 +0000 (09:15 -0200)]
Cleanup: removes unused varyings

10 months agoMinor edits in `effect_ssr_frag.glsl`
mano-wii [Thu, 15 Nov 2018 10:34:33 +0000 (08:34 -0200)]
Minor edits in `effect_ssr_frag.glsl`

10 months agoCleanup: remove unused variable
mano-wii [Wed, 14 Nov 2018 16:24:05 +0000 (14:24 -0200)]
Cleanup: remove unused variable

10 months agoFix T56673: Tara.blend from Blender cloud crashes on load
Sergey Sharybin [Fri, 16 Nov 2018 15:11:24 +0000 (16:11 +0100)]
Fix T56673: Tara.blend from Blender cloud crashes on load

The issue was caused by dependency cycle solver killing relation
which was guaranteed various things: i.e. copy-on-write component
orders and pose evaluation order (which must first run pose init
function).

Now it is possible to prevent such relations from being ignored.

This is not a complete fix, but is enough to make this specific
rig to work. Ideally, we also need to run copy-on-write operation
prior to anything else.

10 months agoFix T57850, bevel modifier crash with vertex groups and face area mode.
Howard Trickey [Fri, 16 Nov 2018 15:06:05 +0000 (10:06 -0500)]
Fix T57850, bevel modifier crash with vertex groups and face area mode.

Used wrong Loop variable in this case.

10 months agoFix inconsistent frame set event in graph compared to other animation editors.
Brecht Van Lommel [Fri, 16 Nov 2018 14:53:48 +0000 (15:53 +0100)]
Fix inconsistent frame set event in graph compared to other animation editors.

10 months agoKeymaps: some more tweaks for left click select based on user feedback.
Brecht Van Lommel [Fri, 16 Nov 2018 13:24:31 +0000 (14:24 +0100)]
Keymaps: some more tweaks for left click select based on user feedback.

* More tools now combine with select click by only starting on drag.
* Alt+LMB works again as loop select as alternative to double click LMB.

10 months agoFix related to T57851: broken normalmap handling in py shader wrapper.
Bastien Montagne [Fri, 16 Nov 2018 13:58:37 +0000 (14:58 +0100)]
Fix related to T57851: broken normalmap handling in py shader wrapper.

Pretty stupid mistake...

10 months agoFix T57477: Switching between edit mode, and particle edit mode crashes
Sergey Sharybin [Fri, 16 Nov 2018 13:21:57 +0000 (14:21 +0100)]
Fix T57477: Switching between edit mode, and particle edit mode crashes

10 months agoMerge branch 'master' into blender2.8
Sybren A. Stüvel [Fri, 16 Nov 2018 13:05:05 +0000 (14:05 +0100)]
Merge branch 'master' into blender2.8

10 months agoCall PRE_VIEW and POST_VIEW draw callbacks in movie clip editor
Sybren A. Stüvel [Fri, 16 Nov 2018 12:58:11 +0000 (13:58 +0100)]
Call PRE_VIEW and POST_VIEW draw callbacks in movie clip editor

10 months agoPyTemplates operator_modal_view3d_raycast: update to blender2.8 (*/@)
Philipp Oeser [Fri, 16 Nov 2018 11:09:41 +0000 (12:09 +0100)]
PyTemplates operator_modal_view3d_raycast: update to blender2.8 (*/@)

10 months agoFix T57566: Blender 2.8 crashes with the new multires
Sergey Sharybin [Fri, 16 Nov 2018 09:34:00 +0000 (10:34 +0100)]
Fix T57566: Blender 2.8 crashes with the new multires

10 months agoKeymap: allow filling in existing key-configs
Campbell Barton [Fri, 16 Nov 2018 04:59:44 +0000 (15:59 +1100)]
Keymap: allow filling in existing key-configs

Needed so we can get the preferences of a key-config
which are sent to a function that generates the contents.

10 months agoCleanup: set variable for preference name
Campbell Barton [Fri, 16 Nov 2018 04:00:27 +0000 (15:00 +1100)]
Cleanup: set variable for preference name

10 months agoKeymap: add support for key-config preferences
Campbell Barton [Fri, 16 Nov 2018 00:24:49 +0000 (11:24 +1100)]
Keymap: add support for key-config preferences

This is needed for keymaps to define their own options,
which can include left/right mouse select.

This can also help to us to provide popular keymap tweaks as options,
so users can easily fit blender to their workflow with well supported
adjustments which don't give the overhead of having to maintain
your own keymap, which become out-dated when operators change.

10 months agoKeymap: remove loading keymaps from old files
Campbell Barton [Fri, 16 Nov 2018 01:30:02 +0000 (12:30 +1100)]
Keymap: remove loading keymaps from old files

These keymaps are not going to work usefully in 2.8x,
remove support for loading them.

10 months agoCleanup: remove 27X define
Campbell Barton [Fri, 16 Nov 2018 00:04:19 +0000 (11:04 +1100)]
Cleanup: remove 27X define

10 months agoBKE: Fix probe duplication not duplicating data block
Clément Foucault [Fri, 16 Nov 2018 00:03:04 +0000 (01:03 +0100)]
BKE: Fix probe duplication not duplicating data block

10 months agoCleanup: de-duplicate 3d view select items
Campbell Barton [Thu, 15 Nov 2018 23:41:17 +0000 (10:41 +1100)]
Cleanup: de-duplicate 3d view select items

10 months agoEdit Mesh: Fixes display of custom normals
Clément Foucault [Thu, 15 Nov 2018 23:45:13 +0000 (00:45 +0100)]
Edit Mesh: Fixes display of custom normals

Should fix T57620

10 months agoKeymaps: add double click loop select to RMB keymap.
Brecht Van Lommel [Thu, 15 Nov 2018 23:27:00 +0000 (00:27 +0100)]
Keymaps: add double click loop select to RMB keymap.

10 months agoFix Blender RMB keymap cursor being set when using border select.
Brecht Van Lommel [Thu, 15 Nov 2018 23:32:32 +0000 (00:32 +0100)]
Fix Blender RMB keymap cursor being set when using border select.

10 months agoFix Blender 2.7 keymap missing spacebar search menu.
Brecht Van Lommel [Thu, 15 Nov 2018 23:24:52 +0000 (00:24 +0100)]
Fix Blender 2.7 keymap missing spacebar search menu.

10 months agoEdit Mesh: Improve mesh cage drawing / fix errors and cleanup
Clément Foucault [Thu, 15 Nov 2018 23:12:45 +0000 (00:12 +0100)]
Edit Mesh: Improve mesh cage drawing / fix errors and cleanup

* Fixes vertices with bad coloring. Now vertices draw with depth write so
they occlude the underlying face geom overlay, avoiding double drawing the
vertex.

* Decrease the z_offset of edges so they don't poke too much through
geometry. Also delete this offset in ortho view.

* Add zoffset to active and selected vertices so they always draw on top
if they overlap a non selected vertex.

* Fix alpha of edge_fix in vertex selection mode

10 months agoRNA: LayerCollection.has_hidden_objects
Dalai Felinto [Thu, 15 Nov 2018 20:25:45 +0000 (18:25 -0200)]
RNA: LayerCollection.has_hidden_objects

With this we have a way to tell that a collection has visible objects
but not all of its objects are visible.

10 months agoKeymaps: left click select keymap changes
Brecht Van Lommel [Thu, 15 Nov 2018 22:27:53 +0000 (09:27 +1100)]
Keymaps: left click select keymap changes

Both the active tools and selection are now on LMB, which leads to
various conflicts.

For that reason the LMB keymap now has a couple of differences
compared to before. These changes do not affect the RMB keymap.

* Context Menu: W -> RMB
* Select Tool activate: None -> W
* Set Cursor: RMB -> Shift+RMB
* Loop Select: Alt+LMB -> double click LMB
* Mask Feather Vertex Slide: Shift+RMB -> Ctrl+Shift+RMB
* Node Select: only with LMB now, no RMB

The idea behind the W key Select Tool shortcut is that various
tools can't be combined with selection, unlike the RMB keymap.
So this works as a quick shortcut to drop a tool
and go back to selection.

Tools: set Select Box tool as default, rather than Cursor.

This goes along with coming LMB select keymap changes,
where we want the user to be able to LMB click to select by default,
rather than set the cursor.
The cursor will still be directly setabble with shift+RMB.

10 months agoRevert "Keymap: remove 3D cursor keymap"
Campbell Barton [Thu, 15 Nov 2018 22:44:19 +0000 (09:44 +1100)]
Revert "Keymap: remove 3D cursor keymap"

This reverts commit 8ecc51e87fd0e3e9bb13622456d03d09926eab47.

This is needed for keymaps that dont include cursor placement by
default.

10 months agoWM: fix hard coded rename
Campbell Barton [Thu, 15 Nov 2018 22:35:24 +0000 (09:35 +1100)]
WM: fix hard coded rename

Currently the filenames are used when setting keymaps.
This hard coded naming meant the preset and setting function
need to be kept in sync.

Prefer to not have hard coded replacements which need to be duplicated.

10 months agoError in recent keymap update
Campbell Barton [Thu, 15 Nov 2018 22:23:48 +0000 (09:23 +1100)]
Error in recent keymap update

10 months agoWM: Fix secondary toolbar events being ignored
Campbell Barton [Thu, 15 Nov 2018 22:19:33 +0000 (09:19 +1100)]
WM: Fix secondary toolbar events being ignored

Error in recent workaround.

10 months agoKeymaps: replace select / action mouse system
Brecht Van Lommel [Thu, 15 Nov 2018 21:28:58 +0000 (08:28 +1100)]
Keymaps: replace select / action mouse system

For Blender builtin configurations the option to choose the select mouse remains
and is now also in the splash screen. It works by changing the keymap dynamically
in the script, rather than using special events.

The system of automatic switching of events was not flexible enough to deal with
side effects that require further keymap changes, so it is now under more manual
control in the script.

This breaks compatibility for some scripts and exported key configurations.
These can be fixed by replacing SELECTMOUSE, ACTIONMOUSE, EVT_TWEAK_S and
EVT_TWEAK_A with appropriate LEFTMOUSE, RIGHTMOUSE, EVT_TWEAK_L and
EVT_TWEAK_R events.

Other than that, there should be no functional changes.

10 months agoKeymap: remove 3D cursor keymap
Campbell Barton [Thu, 15 Nov 2018 20:56:38 +0000 (07:56 +1100)]
Keymap: remove 3D cursor keymap

Rely on 3D view keymap, fixes T57843

10 months agoEevee: Add Filter Quality setting
Clément Foucault [Thu, 15 Nov 2018 19:04:35 +0000 (20:04 +0100)]
Eevee: Add Filter Quality setting

This setting can be tweaked to improve glossy reflection cubemaps.

It increases the sample count for each roughness level.
This settings affect the lookdev mode quality as well.

10 months agoEevee: Add Glossy Reflection clamping
Clément Foucault [Thu, 15 Nov 2018 18:41:15 +0000 (19:41 +0100)]
Eevee: Add Glossy Reflection clamping

This enables reducing the noise comming from very bright light sources
(like a sun) that can be found in distant HDRIs.

The lost energy may be replaced manually by a sunlight that compensate the
this loss.

This clamping only concerns Reflection Cubmaps and is done on all on all
of them.

Setting to 0.0 disables it (default).

10 months agoViewport collections visibility: Viewport and Selection options
Dalai Felinto [Thu, 15 Nov 2018 15:32:03 +0000 (13:32 -0200)]
Viewport collections visibility: Viewport and Selection options

Right now we have a different behaviour whether users click on the name or on
the visibility eye.

When clicking on the eye, it is a toggle. When clicking in the name, you
are isolating this collection (unless you use shift).

As for the UI I tried using separator_spacer, but it was more work than
worth. A lot of sub panels, and LEFT/RIGHT alignment work just fine.

10 months agoViewport collections visibility: Remove collection icon
Dalai Felinto [Thu, 15 Nov 2018 18:46:27 +0000 (16:46 -0200)]
Viewport collections visibility: Remove collection icon

I added the icon inspired by the H menu, but there is no need for this.

10 months agoExplicitly disable separator spacer in popover and pie menus
Dalai Felinto [Thu, 15 Nov 2018 18:44:42 +0000 (16:44 -0200)]
Explicitly disable separator spacer in popover and pie menus

It is doable to get it to work, you just need to process it line
by line though, and get the right width of each one.

Disabling it for now since it is not implemented anyways.

10 months agoFix tool error opening Sculpt template.
Brecht Van Lommel [Thu, 15 Nov 2018 17:48:29 +0000 (18:48 +0100)]
Fix tool error opening Sculpt template.

10 months agoTemplates: set autosmooth threshold to 30°, matching default for new meshes.
Brecht Van Lommel [Thu, 15 Nov 2018 17:28:51 +0000 (18:28 +0100)]
Templates: set autosmooth threshold to 30°, matching default for new meshes.

10 months agoFix T57854: Disable viewport visibility crash
Sergey Sharybin [Thu, 15 Nov 2018 17:28:43 +0000 (18:28 +0100)]
Fix T57854: Disable viewport visibility crash

10 months agoEevee: Add irradiance smoothing
Clément Foucault [Thu, 15 Nov 2018 17:13:07 +0000 (18:13 +0100)]
Eevee: Add irradiance smoothing

This is a parameter that will make the interpolation between irradiance
cells of a same Irradiance Volume smoother, reducing the weight of the
light leaking correction factors.

It is usefull in some cases to avoid harsh lighting transition that can
happen when a sample point it near a surface.

10 months agoEevee: Irradiance Grid: Make the influence shape corners round
Clément Foucault [Thu, 15 Nov 2018 16:52:55 +0000 (17:52 +0100)]
Eevee: Irradiance Grid: Make the influence shape corners round

This makes it easier to add corrective light grids without having ugly
blending corners revealing the shape of the grid bounds.

10 months agoEevee: Lights: Reduce default cascade distance
Clément Foucault [Thu, 15 Nov 2018 14:34:42 +0000 (15:34 +0100)]
Eevee: Lights: Reduce default cascade distance

10 months agoEevee: Cleanup & small optimization
Clément Foucault [Thu, 15 Nov 2018 13:51:51 +0000 (14:51 +0100)]
Eevee: Cleanup & small optimization

10 months agoEevee: Add Light Threshold value
Clément Foucault [Thu, 15 Nov 2018 13:44:45 +0000 (14:44 +0100)]
Eevee: Add Light Threshold value

This is an important change. Starting from now, all lights have a finite
influence radius (similar to the old sphere option for BI).

In order to avoid costly setup time, this distance is first computed
automatically based on a light threshold. The distance is computed
at the light origin and using the inverse square falloff. The setting
can be found inside the render settings panel > shadow tab.

This light threshold does not take the light shape into account an may not
suit every case. That's why we provide a per lamp override where you can
just set the cutt off distance (Light Properties Panel > Light >
Custom Distance).

The influence distance is also used as shadow far clip distance.

This influence distance does not concerns sun lights that still have a
far clip distance.

---

This change is important because it makes it possible to cull lights
an improve performance drastically in the future.

10 months agoEevee: Optimisation: Bypass light power calculation when not needed
Clément Foucault [Wed, 14 Nov 2018 15:03:24 +0000 (16:03 +0100)]
Eevee: Optimisation: Bypass light power calculation when not needed

This makes quite a big improvement in my case 1.8ms vs 2.3ms for a single
area light.
This will make even more difference with light attenuation.

10 months agoEevee: Cleanup: Fix wrong sun area light power calculation
Clément Foucault [Wed, 14 Nov 2018 14:54:10 +0000 (15:54 +0100)]
Eevee: Cleanup: Fix wrong sun area light power calculation

10 months agoEevee: Make sun power match cycles better.
Clément Foucault [Wed, 14 Nov 2018 14:46:40 +0000 (15:46 +0100)]
Eevee: Make sun power match cycles better.

I made an empirical test with a 100% diffuse sphere and manually tweak the
lighting power of a sun lamp trying to fit cycles and eevee the best I can.

Then I plotted the result and found a rough fit to the equation and that
seems to work pretty well.

10 months agoFix node_shader_utils: "Specular Tint" is a float (not a color)
Philipp Oeser [Thu, 15 Nov 2018 16:44:14 +0000 (17:44 +0100)]
Fix node_shader_utils: "Specular Tint" is a float (not a color)

10 months agoRNA: always allow fallback from defaultarray to defaultvalue.
Alexander Gavrilov [Sun, 11 Nov 2018 17:56:42 +0000 (20:56 +0300)]
RNA: always allow fallback from defaultarray to defaultvalue.

The python getters for the array already allowed that, but not the
actual C RNA access functions. This is inconsistent, so implement
the fallback in all cases. Now if by default the property should
contain the same value in all positions, it is not necessary to
actually use an array.

Reviewers: campbellbarton

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

10 months agoCycles: Cleanup, code style
Sergey Sharybin [Thu, 15 Nov 2018 16:19:26 +0000 (17:19 +0100)]
Cycles: Cleanup, code style

10 months agoMerge branch 'master' into blender2.8
Sergey Sharybin [Thu, 15 Nov 2018 16:17:37 +0000 (17:17 +0100)]
Merge branch 'master' into blender2.8

10 months agoCycles: Cleanup, code style
Sergey Sharybin [Thu, 15 Nov 2018 16:16:40 +0000 (17:16 +0100)]
Cycles: Cleanup, code style

10 months agoPy API: Fix documentation/actual behavior missmatch in gpu.matrix
Jacques Lucke [Thu, 15 Nov 2018 16:10:32 +0000 (17:10 +0100)]
Py API: Fix documentation/actual behavior missmatch in gpu.matrix