Commit Graph

634 Commits

Author SHA1 Message Date
Brecht Van Lommel
ca5f1c0f00 Shaders: rename Principled BSDF Emission to Emission Color
Ref #99447
Ref #112848
2023-09-25 19:50:41 +02:00
Weizhen Huang
def9b76207 Shader: Change specular tint in Principled BSDF from float to color
For more artistic control. Tints the reflection of dielectric materials
at normal incidence.

Ref #99447

Pull Request: https://projects.blender.org/blender/blender/pulls/112192
2023-09-25 19:42:05 +02:00
Hans Goudey
7e0691d027 Fix: Grammar in operator description 2023-09-25 13:25:32 -04:00
Pablo Vazquez
9a3131323b UI: About: Update links and labels
Following f7af45ccfd, rename link labels:

* Release Notes -> What's New
* Development Fund -> Donate

The description are left as is since they
are still correct, just the labels to be more
in line with language used in blender.org
2023-09-25 18:40:36 +02:00
Pablo Vazquez
f7af45ccfd UI: Splash: Small changes to links and labels
* Rename "Development Fund" to "Donate", more in line with
  the language used in blender.org
* Rename "Release Notes" to "What's New". A bit more inviting
  to click and sounds less technical.
* In "Getting Started", remove "Credits" since it it nos related
  to getting started, and add relevant links already present
  in the Help menu.

Pull Request: https://projects.blender.org/blender/blender/pulls/112741
2023-09-25 18:09:02 +02:00
Pablo Vazquez
05fc31f27f UI: Remove redundant "Context Menu" in menu titles
Context menus are a type of menu, like header menus, there is no need to mention
the type as part of the name since it is implied by context.

Pull Request: https://projects.blender.org/blender/blender/pulls/112662
2023-09-25 16:25:55 +02:00
persun
90d8a07213 UI: Move "Reset Recent" inside a menu
Move the File Browser's `Reset Recent` button into a menu to prevent
accidental clicks of a destructive operation.

Also rename it to a more descriptive  `Clear Recent Items`, and since
the word "Reset" is used for resetting values to default.

Pull Request: https://projects.blender.org/blender/blender/pulls/112853
2023-09-25 15:15:53 +02:00
Jacques Lucke
8362563949 UI: show recently selected items at the top of searches
The goal is to make the search faster to use by dynamically adapting to the user.
This can be achieved using the simple but common approach of showing recently
selected items at the top. Note, that the "matching score" between the query and
each search item still has precedence when determining the order. So the last used
item is only at the top, if there is no other search item that matches the query better.

Besides making the search generally faster to use, my hope is that this can also
reduce the need for manually weighting search items in some places. This is
because while the ordering might not be perfect the first time, it will always be
once the user selected the element that should be at the top once.

This patch includes:
* Support for taking recent searches into account in string searching.
* Keep track of a global list of recent searches.
* Store recent searches on disk similar to recently opened files.
* A new setting in the user preferences that allows disabling the functionality.
  This can be used if deterministic key strokes are required, e.g. for automated tests.

In the future this could be improved in different ways:
* Add some kind of separator in the search list to indicate which elements are at
  the top because they have been used recently.
* Store the recent search items per search, instead of in a global list. This way
  it could adapt to the user even better.

Pull Request: https://projects.blender.org/blender/blender/pulls/110828
2023-09-25 10:56:12 +02:00
Hans Goudey
26e56d0b52 Fix: Correct UI string in previous fix
Sorry for the noise...
2023-09-24 18:58:08 -04:00
Hans Goudey
15f24bd248 Fix #112814: New geometry nodes always named "Tool" 2023-09-24 18:55:02 -04:00
Hans Goudey
d1d570d318 Geometry Nodes: Don't require geometry input for "Mode to Nodes"
It's valid for modifier node groups to not have a geometry input, since
they can just be generators. The operator used to give a warning and
cancel itself when there was no geometry input. Now it works, and
skips adding the geometry input and the group input node to the
new group.
2023-09-23 20:32:52 -04:00
Hans Goudey
652aab0b31 Fix: Swapped icons in node tool header popover 2023-09-22 20:51:34 -04:00
Hans Goudey
2cb34f7c0d UI: Improve geometry nodes tool popover layout
See #101778, #111524

Separate the layout into one popover for object types and another for
object modes. Use checkboxes with icons and full phrases like "Object
Mode". Also rename the modifier popover to "Modifier". Thought
it just has one option right now, so it looks quite weird.

---

![image](https://projects.blender.org/attachments/17e86c35-3c13-48e4-8113-817c5a80fdd3)
![image](https://projects.blender.org/attachments/f92a55a9-e4f0-4c29-8d15-a47a3154ed70)
![image](https://projects.blender.org/attachments/50cd0a93-0abb-4766-819b-62d265251822)

Pull Request: https://projects.blender.org/blender/blender/pulls/112749
2023-09-23 02:33:51 +02:00
Harley Acheson
0dab5818d7 UI: Discrete Thumbnail Sizes for Menus
Allow menus to select thumbnail sizes in discrete steps.

Pull Request: https://projects.blender.org/blender/blender/pulls/112455
2023-09-22 18:49:01 +02:00
Hans Goudey
1c51f74cb4 Geometry Nodes: Filter data-block buttons for tools and modifiers
In the data-block selectors in the node editor and the header,
apply a few rules to increase the separation between tool and
modifier node groups.
1. The modifier accepts non-asset groups or assets marked
   as modifiers (created in the modifier context). Tool node groups
   cannot be used by modifiers.
2. The tool context can only edit node group assets marked as tools
   (created in the tool context).

When switching contexts, the node group is cleared if the state would
be invalid. The tool node group is still stored in the editor's "root node
tree" property. Since it isn't retrieved from the context, the pin button
is useless, so it isn't displayed in the tool mode.

See #101778, #111526.

Pull Request: https://projects.blender.org/blender/blender/pulls/112389
2023-09-22 17:45:00 +02:00
Philipp Oeser
29dfb73eb7 Fix: bl_previews_render.py still using lamp.falloff_type
This was removed in 57d85b32a9.

Pull Request: https://projects.blender.org/blender/blender/pulls/112728
2023-09-22 17:17:05 +02:00
Alexander Gavrilov
be7e2d01a8 Python: support the step and precision arguments in rna_idprop_ui_create.
Support the property settings that were implemented some time ago.

As an aside, change the defaults for min and max to integers: integer
values can be implicitly cast to float, but the reverse results in an
error. Also, pointer properties don't support a default value.

Pull Request: https://projects.blender.org/blender/blender/pulls/112712
2023-09-22 12:07:26 +02:00
Jeroen Bakker
7b379eb657 Cleanup: Make format 2023-09-22 08:32:03 +02:00
Campbell Barton
a5cd497543 Console: add support for displaying tab-stops
Without this it was necessary to convert pasted text into spaces
for them to display properly.

Since tabs are a valid part of a string, it's incorrect to assume
tabs can always be expanded to spaces.

Pasted text and console output now display tabs properly,
the tab still uses spaces for indenting though.
2023-09-22 13:43:12 +10:00
Harley Acheson
18e07098ef UI: Support additional console text operations
Adds the ability to set text cursor position in the Console editor
by clicking with the mouse and many other expected operations such as
cut, select all & deselect on text entry.

Ref !108626
2023-09-22 13:36:29 +10:00
Campbell Barton
fb624720eb Cleanup: remove 'apple' variable for key-map parameters
The OSKEY-Comma key-map item will be kept on macOS by the
bl_keymap_utils.platform_helpers utility function.
2023-09-22 10:37:23 +10:00
Campbell Barton
fd0d6b27bb Cleanup: remove unnecessary hasattr check 2023-09-22 10:16:13 +10:00
Pablo Vazquez
d0aa521ea8 UI: Minor layout and style adjustments in Preferences
Small style and layout tweaks of some tabs in Preferences.
Mainly inline styling for compact layouts, grouping labels and
adding icons where needed.

Purposely leaving aside complex areas such as Themes,
Add-ons, or Keymap. They require larger design decisions.

Pull Request: https://projects.blender.org/blender/blender/pulls/112393
2023-09-22 01:07:56 +02:00
Brecht Van Lommel
208323c087 Fix duplicate preference key shortcut on macOS, causing test failure
After recent changes in 86f659a.
2023-09-21 18:46:30 +02:00
Brecht Van Lommel
1ef63e93b4 Fix missing BSDF nodes in add menu with Hydra render engines
Default to displaying nearly all nodes when the engine is not set to
Cycles or Eeeve. And instead hide nodes not supported in Eevee only
when Eevee is selected.

This way external engines can use the same menu, particularly useful
for upcoming support for conversion to MaterialX.

Only the Shader category was incomplete like this, so it can also be
seen as fixing an inconsistency with other categories.
2023-09-21 18:46:30 +02:00
Christoph Lendenfeld
01927e1e45 Anim: Time Offset Slider
This patch has been originally authored by Ares Deveaux #106520
I am just finishing it up.

This is a new operator for the Graph Editor.
It shifts the value of the keys in time,
while keeping the actual key positions in the same place.
It supports wrapping, so when offsetting beyond the range
of the F-Curve it will take values from the other end,
but offset in y-value so there is no jump.

This works best with dense key data.

Co-authored-by: Ares Deveaux <aresdevo@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/110540
2023-09-21 15:11:16 +02:00
Nathan Vegdahl
be5cf8f8a1 Anim: add graph editor key/handles selection operator
This adds an operator `graph.select_key_handles` to the graph editor
that changes the selection of the different parts of a bezier keyframe.  It
operates on all keys that are either themselves selected or have either of
their handles selected, and changes whether the key itself and/or its handles
are selected.

The operator has three options:

- `left_handle_action`
- `right_handle_action`
- `key_action`

Each of which can be set to:

- Select
- Deselect
- Keep (do nothing)

Co-authored-by: cgtinker <Denys.Hsu@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/111143
2023-09-21 15:05:30 +02:00
Jeroen Bakker
6d91d36161 GPU: Remove GPU_shader_storage_buffer_objects_support
Blender 4.0 requires OpenGL 4.3 which always support SSBO's.
Platforms that don't support enough SSBO bind points will be marked
as unsupported.

Users who start Blender on those platforms will be informed via a
dialog. This PR also updates the `--debug-gpu-force-workarounds`
to match our minimum requirements. Note that some bugs are still
there that should be solved in other PRs:

* Workbench only renders the object using a unit matrix this is because
  there is a bug in the workaround for shader_draw_parameters
* Navigating with middle mouse button is not working. Unsure what the
  cause is, but might be a missing feature check in the OpenGL backend.

Related to #112224

Pull Request: https://projects.blender.org/blender/blender/pulls/112572
2023-09-21 12:55:51 +02:00
Christoph Lendenfeld
25031f8a86 Anim: Graph Editor Push/Pull operator
This finishes the work that Ares Deveaux started here #106527

Scales the selected keys from an imaginary line that
runs from the start to the end of the segment.

Co-authored-by: Ares Deveaux <aresdevo@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/112388
2023-09-21 12:46:27 +02:00
Pablo Vazquez
86f659ad96 Keymap: Add shortcut to open Preferences
Use Ctrl + Comma. It is an expected shortcut since many
other applications use it.
Agreed during module meeting.
2023-09-21 11:48:07 +02:00
Jeroen Bakker
9cc4df8062 Cleanup: Make Format 2023-09-21 07:55:23 +02:00
Pablo Vazquez
da495765b4 UI: Add icon to Library Override menu entries
To create a connection with the icon that shows up in
ID templates and decorators once library is overriden.

Affects Outliner context and Object menu in 3D Viewport.
Similar to the Asset menu.
2023-09-20 15:06:54 +02:00
persun
63fef34fda UI: Add Vertex Crease operator to vertex context menu
Add Vertex Crease operator to vertex context menu. This is consistent with
edge context menu having Edge Crease menu.

Pull Request: https://projects.blender.org/blender/blender/pulls/109146
2023-09-20 08:58:17 +02:00
Campbell Barton
9ed7d7cb03 UI: add extensions section (shown when extension repos are enabled)
This is a place-holder by default, the work-in-progress extensions
add-on makes use of this.
2023-09-20 15:14:07 +10:00
Germano Cavalcante
d61295155c Fix AttributeError: module 'urllib' has no attribute 'parse'
On some systems, the `urllib` package serves as a namespace only and
does not import the `parse` module under it.
2023-09-19 12:55:09 -03:00
Sybren A. Stüvel
b48031df8e Anim: armature edit mode, make Shift+M consistent with pose mode
Replace the 'armature layers' operator (which would toggle visibility of
armature layers) with the 'bone collections' menu (which allows assigning
to and unassigning from bone collections). The functionality of these
operators is quite different, but it unifies the behaviour between
armature pose and edit modes.

Selecting which bone collections are visible in the 3D Viewport may be
reintroduced after nestable bone collections are implemented. Otherwise
the list of bone collections will likely become unwieldy.
2023-09-19 17:43:26 +02:00
Julian Eisel
974d70918b RNA/BPY: Replace asset_library_ref with asset_library_reference
This is a compatibility breaking change to rename all usages of the name
`asset_library_ref` with `asset_library_reference`. Brecht recently
suggested that such abbreviations should be avoided in public API names.
2023-09-19 16:27:07 +02:00
Julian Eisel
591a1ae323 Assets: Remove (almost) all usages of asset handle in Python scripts
The asset handle type is supposed to be replaced by the asset
representation type. It is designed for the asset system as opposed to
the file browser backend. With d421ebac5e, d04cd3f3e6 and f6a6b27ac1, it
can now do everything that is needed in Python to be a replacement.

With this commit the asset handle type and the file handle type it uses
is almost entirely replaced in Python files (only for the asset view
template we require a collection property taking asset handles still,
for internal reasons.)

Part of #102877 and #108806.
2023-09-19 14:41:34 +02:00
Sybren A. Stüvel
62639080bc Anim: armature edit mode, replace 'bone layers' operator with collections
In armature edit mode, replace the 'bone layers' operator with the 'move
to bone collection' operator. This operator now works in both pose mode
and edit mode, and is available with the 'M' hotkey in either mode.
2023-09-19 11:45:40 +02:00
Lukas Tönne
742f3b233f Nodes: Rename ui_items property to items_tree
DNA names are unchanged, just affects the RNA API.

Resolves #112523

Pull Request: https://projects.blender.org/blender/blender/pulls/112527
2023-09-18 18:07:26 +02:00
Hans Goudey
1cfed92c84 Fix: Exception creating geometry node group or node group socket
c951464b8a didn't update the uses of the API.
2023-09-18 11:01:05 -04:00
Sybren A. Stüvel
02659c0d01 Anim: merge bone collection assignment menus
Remove the Ctrl+G shortcut (remnant of the bone group assignment operator),
and change the 'Pose / Bone Collections' menu so that it handles linked
and overridden data properly. Shift+M now shows that menu too.
2023-09-18 14:48:34 +02:00
Damien Picard
418f817879 I18n: do not translate Freestyle modifier breadcrumbs
Each type of Freestyle modifier gets its own panel. Each panel draws
breadcrumbs below the header. These breadcrumbs look like:

MyLineSet > MyLineStyle

They are currently translated, but since they represent data they
should not.

This commit disables translation for these breadcrumbs.

Pull Request: https://projects.blender.org/blender/blender/pulls/112418
2023-09-18 13:03:08 +02:00
Campbell Barton
906a5a89c4 Cleanup: remove fix for #112129 which is no longer needed
Since [0] this is no longer needed.

[0]: a8db828618
2023-09-18 16:06:31 +10:00
Hans Goudey
f122193e24 Cleanup: Remove unused logic from geometry nodes operator
The "new node tree & assign to modifier" operator isn't used in the tool
context of the geometry node editor-- it doesn't have to handle it.
2023-09-17 20:09:14 -04:00
Campbell Barton
7eae806dda Cleanup: format, spelling 2023-09-17 09:05:40 +10:00
Clément Foucault
c00962d038 EEVEE-Next: Raytrace: Add back Screen Space radiance input
This finalize the implementation of the screen space tracing
for EEVEE-Next.

Refractive objects can now have screen space reflection too
and self reflect.

This keeps the feedback radiance buffer principle of the
Classic EEVEE so that we still get infinite bounces by default.

There are some conflict with refraction tracing and ambient
occlusion nodes. Materials using screen space refraction will
not be able to detect occlusion from any refractive surface using
screen space refraction including itself.
They also won't be visible to screen space reflections from other
materials *not* using screen space refraction.
This should be added to the list of limitations for now.

Note that the current approach to feed the radiance is to copy
the radiance buffer. This has the nice property of only containing
the currently rendered objects and not project transparent objects
or other non-yet rendered object onto the depth behind them.

Pull Request: https://projects.blender.org/blender/blender/pulls/112341
2023-09-16 11:48:13 +02:00
Bastien Montagne
e553c71aae I18n Py Module: Update settings after move to Weblate.
This is (mainly) some cleanup in names and descriptions, since we are
not using any SVN repository anymore, and layout of working new Git
repository is quite different.

Change in sync with upcoming update of the `ui_translate` add-on.

Related to https://projects.blender.org/infrastructure/blender-projects-platform/issues/65
2023-09-15 18:08:52 +02:00
Bastien Montagne
0ce02355c1 I18N module: updates for transition to weblate.
Remove `es_ES` language.
Rename `uz_UZ` to `uz_UZ@latin`
Rename `zh_CN` to `zh_HANS`
Rename `zh_TW` to `zh_HANT`

Add support for lowercase chars in `country` part of the locale code
(although in the end it is not needed, since `boost::locale` backend
does not supports lowercase 'country' part in locales identifiers
currently) .

Related to https://projects.blender.org/infrastructure/blender-projects-platform/issues/65
2023-09-15 18:08:52 +02:00
Julian Eisel
728d47f3e4 Asset shelf: Use asset representation for asset shelf BPY methods
Changes the `asset_poll()` and `draw_context_menu()` methods for asset
shelves to use the `AssetRepresentation` type, instead of `AssetHandle`.
The latter should be removed, so it's better to avoid using it in the
asset shelf BPY to avoid future compatibility breakage. This is possible
now with d421ebac5e.
2023-09-15 16:17:44 +02:00