Commit Graph

2470 Commits

Author SHA1 Message Date
Pablo Vazquez
8845e3243d UI: Remove duplicate icons on menus
As per the human interface guidelines, do not use the same icon in
consecutive items within a group in a menu.

* Operator Search in Top Bar's Edit menu
* Viewport Render Keyframes in Viewport's View menu
2024-09-12 16:19:34 +02:00
Julien Duroure
00bc059894 glTF: Fix typo in a previous commit 2024-09-12 15:50:58 +02:00
Pablo Vazquez
32a2c9ea32 UI: Add missing ellipsis to File menu items
As per the writing style guidelines, add ellipsis to labels of
operators that do not run immediately but open settings or require
further steps.

Pull Request: https://projects.blender.org/blender/blender/pulls/127475
2024-09-12 15:48:41 +02:00
Pablo Vazquez
14208b6dfa UI: Compositor: Show Parent button when available
The Parent Node Tree operator button to go up a level in nested
node trees is always visible in the header, regardless if we are
currently in a nested tree or not.

Only show the button when it is actually possible to go a level up.
This frees up space in the header when at the top level.
2024-09-12 15:44:06 +02:00
Pablo Vazquez
3986b99e42 UI: Compositor: do not expand backdrop channels
To be consistent with other editors (Image Editor, Sequencer), and use
less space in the header.
2024-09-12 15:44:06 +02:00
Julien Duroure
a9bfca5483 glTF exporter: fix missing hook parameters leading to crash 2024-09-12 15:41:00 +02:00
Julien Duroure
0169abd220 glTF exporter: account for library when gathering image URI
When using "keep original" option
2024-09-12 15:19:32 +02:00
Falk David
c07c9d5729 GPv3: Change "use_locked_material" option
This option is meant to ignore any material locking when it
comes to editing strokes that might use locked materials.

There were some issues with the current implementation.
* The name did not reflect what it was supposed to do, so it
   was renamed to `ignore_locked_materials`.
* The description of the option has been updated to better
   reflect the behavior.
* Some util functions have been refactored

Pull Request: https://projects.blender.org/blender/blender/pulls/127423
2024-09-12 14:20:16 +02:00
Sybren A. Stüvel
3417934eff Anim: add Action Slot assignment to NLA strip
For an NLA strip to use a slotted Action, it needs to specify which slot
to use in that action. This is now handled by two new properties on the
strip in DNA & RNA: `action_slot_handle` and `action_slot_name`.

These serve the same purpose as their counterparts on the `AnimData`
struct.

Note that this commit does NOT add NLA evaluation support for slotted
Actions. It merely allows assigning them. Evaluation, tweak mode
support, etc. will be implemented in future commits.

Pull Request: https://projects.blender.org/blender/blender/pulls/127359
2024-09-12 14:08:16 +02:00
Falk David
8f86a04c72 Fix: GPv3: Missing context mode case in overlay options panel
The vertex paint mode options was missing in this panel.
2024-09-12 13:39:28 +02:00
Julien Duroure
044d20fe46 glTF importer: Fix light spot default values check 2024-09-12 12:05:48 +02:00
Julien Duroure
4c441c1c64 glTF exporter: fix accessor min/max float check 2024-09-12 12:02:51 +02:00
Julien Duroure
936ca7636a glTF exporter: Removes a duplicate lookup 2024-09-12 11:49:16 +02:00
Julien Duroure
89c389c465 glTF: hook UI, distinct import & export draw code 2024-09-12 11:42:22 +02:00
Jacques Lucke
1a52f2bbab Fix #126924: instable fire simulation by default
The cfl_condition default was changed in 9a0a75eff0 with the intention
of making liquids behave better. However, that degraded the simulations of fire.

Now the property will be set to its old value if the quick smoke operator is used.
Can't think of a great way always use the old value for smoke simulations for now.
2024-09-11 17:48:20 +02:00
Philipp Oeser
d1aa30f1ac UI: Expose "Frame Selected" in image editor mask mode
Was already included in `IMAGE_MT_view_pie`, but missing from
`IMAGE_MT_view`

NOTE: the functionality has problems, see #127352, but that will be
tackled separately

Pull Request: https://projects.blender.org/blender/blender/pulls/127391
2024-09-11 13:30:40 +02:00
Pablo Vazquez
095aab986b Keymap: Map Back/Next mouse buttons in File Browser
Assign mouse button 4 and 5 to navigate back/next in the
File Browser. These button numbers are usually mapped to
this actions on browsers.

Additionally to the existing Alt/Option+Left/Right shortcuts.
Both in Blender default keymap and Industry Compatible.

Pull Request: https://projects.blender.org/blender/blender/pulls/127413
2024-09-11 12:29:19 +02:00
Campbell Barton
54153629f4 Fix #127329: Keyboard interrupt doesn't work from Python 2024-09-11 14:30:51 +10:00
Falk David
942499382d GPv3: Vertex Paint Mode
This adds the vertex paint mode and all of the tools
from GPv2:
 * Average
 * Blur
 * Draw
 * Replace
 * Smear

Pull Request: https://projects.blender.org/blender/blender/pulls/125674
2024-09-10 18:56:31 +02:00
YimingWu
168c568058 Fix #126946: GPv3: Handle erase mode when using a tablet pen
Pressing ctrl-click should switch the drawing tool into a eraser
for grease pencil. This is now handled by detecting
`EVT_TABLET_ERASER` and switch to `BRUSH_STROKE_ERASE` mode.

Pull Request: https://projects.blender.org/blender/blender/pulls/126962
2024-09-10 11:59:08 +02:00
Sietse Brouwer
9c9b562d54 GPv3: Smooth active vertex group operator
This PR implements the "Smooth" operator in Weight Paint mode for GPv3.
The Smooth operator smooths the weights in the active vertex group by
applying a gaussian blur to the vertex weights.

The operator has two properties:
- `factor` (0.0 - 1.0): The extent to which the smoothed weight is
applied to the original weight, where 0.0 is 'keep the original weight'
and 1.0 is 'replace fully with the smoothed weight'.
- `repeat`: The number of times the smoothing is executed. A higher
value means more smoothing.

The operator is added to the 'Weight' menu in Weight Paint mode.

Pull Request: https://projects.blender.org/blender/blender/pulls/126429
2024-09-09 10:59:06 +02:00
Sybren A. Stüvel
416625738e Anim: avoid Python exception in Dope Sheet header
Fix a Python exception when drawing the Dope Sheet header in Shape Keys
mode, when the active Object type cannot have shape keys.
2024-09-09 10:49:59 +02:00
Sybren A. Stüvel
bbccf912b4 Anim: remove the 'Animation Debug' panel
Remove the 'Animation Debug' panel from the 3D Viewport. It was always
meant as a temporary debugging tool, and it's no longer needed.

Pull Request: https://projects.blender.org/blender/blender/pulls/127200
2024-09-06 10:59:04 +02:00
Jeroen Bakker
458faa6486 Preferences: GPU backend selection
This PR allows users to select a GPU backend.

In the system tab of the user preferences the GPU backend can be selected in the `Display Graphics` panel.
It will require a restart of Blender before the changes become effective.

During startup minimum requirements are checked. Blender will switch automatically
to OpenGL when no compatible Vulkan device could be detected. A dialog will be shown
to inform the user.

The setting of the in the `Display Graphics` panel are still overridden when blender is started
using the `--gpu-backend` option. When starting blender with `--debug-gpu` the backend
detection will print to the console.

See PR for detailed information and screenshots of the UI.

Implements #126504
Pull Request: https://projects.blender.org/blender/blender/pulls/126545
2024-09-06 08:28:41 +02:00
Campbell Barton
43f7b50df3 Fix #127127: bpy.types sometimes reference their parent's "bl_rna"
Accessing `bl_rna` for type defined in `scripts/modules/bpy_types.py`
could return their parent-classes RNA when accessed via their parent
types __subclasses__() method.
2024-09-06 14:57:26 +10:00
Campbell Barton
97179b10fb Refactor: make "sys_info" an internal module, rename for clarity
- Move sys_info into an internal module to avoid having so many
  top level modules for Blender's internal functionality.
- Rename system_info sub-modules that pre-fill URL's for clarity.
- Move top-level exception handling into the operator.
- Report an error if an unexpected exception occurs.
- Use `Exception` instead of `BaseException` as there is no reason to
  catch the additional exceptions.
- Remove use of sys_info from the command line example,
  replace with in-lined system info.
2024-09-06 11:11:26 +10:00
Sybren A. Stüvel
383c3c8253 Anim: Add Action+Slot selectors to Property editor tabs
Add Action + Action Slot selectors to various Property Editor tabs.
This follows the pattern established in
f917b60036.

Support for `CacheFile` data-blocks is not included here. That needs
some discussion, as currently its interface is part of the Modifier
stack (and thus implemented in C++ and not Python, and using a
different layout).

Since this PR is about adding to the Property Editor, some data-blocks
that have no representation there are thus excluded (like `Mask`).
Even when they could actually use an Action+Slot selector somewhere.

Pull Request: https://projects.blender.org/blender/blender/pulls/127074
2024-09-05 12:11:35 +02:00
Sybren A. Stüvel
efcd0e04b3 Fix #126896: Shape Key Editor can't browse actions
The new Action selector (51fd355c01) avoids the need to use
`space_data.action` in the dope sheet (that attribute was a bit of a
hack; the new Action selector was made to avoid that). It failed to take
the dope sheet's shape key mode into account properly, though. This is
now fixed.

Pull Request: https://projects.blender.org/blender/blender/pulls/127177
2024-09-05 12:02:23 +02:00
YimingWu
2ee223b774 Clip Editor: Add clip.delete_track shortcut in dopesheet view
Previously there isn't a "delete" shortcut in dopesheet view of
the movie clip editor. Now the shortcut (`X` key) is added for
convenience.
2024-09-05 11:51:17 +08:00
Pratik Borhade
0bfad6cc5a GPv3: Wrong radius property in draw context menu
Mistake in 9ca6e049a7
Adjust draw brush properties based on `use_locked_size` status

Pull Request: https://projects.blender.org/blender/blender/pulls/127070
2024-09-04 12:58:49 +02:00
Pratik Borhade
0ef35bc475 UI: Expose Proportional edit in image editor mask mode
Proportional edit works with shortcut in mask mode of image editor but
it was never exposed in UI (header). Also move pivot point along with
proportional edit property to the right of mask template.

Pull Request: https://projects.blender.org/blender/blender/pulls/126482
2024-09-03 22:56:48 +02:00
Campbell Barton
e34d9eeac7 Cleanup: use C-style comments, double quote Python text 2024-09-03 21:22:34 +10:00
Campbell Barton
3cb95b0be9 Cleanup: avoid repetition in version extraction 2024-09-03 13:44:44 +10:00
Alaska
3196ef1636 Add a script to collect system information when Blender isn't opening
This commit adds a python script that can collect some of the
information necessary to fill out a bug report.

The primary use case is to help users collect system information for
a bug report in the case that Blender can't open.

CMD and sh files are included to help users use the Python script.

Ref !122191
2024-09-03 13:26:54 +10:00
Campbell Barton
d19c13eb82 Cleanup: spelling & punctuation in comments 2024-09-03 12:59:37 +10:00
Miguel Pozo
7a55bdeaf9 EEVEE: Enable translation of screen messages
Add `Instance::info_append` so it's easier to log correctly formatted
info, and `Instance::info_append_i18n` to support string localization.

Co-authored-by: Damien Picard
Co-authored-by: Bastien Montagne <mont29@noreply.localhost>
Pull Request: https://projects.blender.org/blender/blender/pulls/124257
2024-09-02 20:13:31 +02:00
Sybren A. Stüvel
433278233e Cleanup: formatting
Just running `make format`, no functional changes.
2024-09-02 18:05:55 +02:00
Bastien Montagne
b5ea3beaf9 Fix i18n message extraction tool after recent BPY/RNA fix.
Recent fix 21b820cd33 in BPY/RNA code broke introspection code of RNA
data in i18n message extraction code.

Luckily, it actually fixes things, and allows to remove some of the ugly
hacks we had in this code, especially regarding Operators handling.
2024-09-02 15:59:16 +02:00
YimingWu
7c52bbb30a Cleanup: Remove _has_gpv3 condition in python
GPv3 is no longer really a experimental feature now and the
experimental option is also removed already, so it does not
make much sense keeping this branch in the UI.
2024-09-02 21:21:03 +08:00
Sybren A. Stüvel
a6d7e12e22 Anim: New/Un-assign Slot operators
Add two new operators, `anim.slot_new_for_id` and
`anim.slot_unassign_from_id`. These are used in the Action editor and
the Animation panels in the Properties editor, to respectively create a
new Action Slot for an ID and to unassign whatever slot is currently
assigned to that ID.

The latter operator also replaces the C++ operator
`anim.slot_unassign_object`, which was specifically made for the
Dopesheet header. The Python ones are generic enough to be used there
too.

Pull Request: https://projects.blender.org/blender/blender/pulls/126943
2024-09-02 14:10:49 +02:00
Sybren A. Stüvel
f917b60036 Anim: add Action selectors to Material + Camera properties
In the Properties editor, add Action selectors to the Material
properties and the Camera properties.

For the Material, two Action selectors are shown: for the Material
itself and for its shader node tree. Those are separate IDs of different
types, and thus will always have separate Actions (until the Slotted
Actions are commonplace).

When the 'Slotted Actions' experimental feature is enabled, also show
the Action Slot selector underneath each Action selector.

The Animation panel in the Properties editor is (by default) always at
the bottom, just above the Custom Properties panel.

Pull Request: https://projects.blender.org/blender/blender/pulls/125666
2024-09-02 12:10:14 +02:00
Julien Duroure
780721de19 glTF exporter: fix error message if hook failed 2024-09-01 15:16:27 +02:00
Aaron Carlisle
a08005f484 Docs: Update rna manual references 2024-08-30 17:18:23 -04:00
Charlie Jolly
294994e4b9 Geometry Nodes: new Hash Value node
This node hashes various types into an integer. Note that hashes
cannot generally used as unique identifiers because they are not
guaranteed to be unique. It can be used to generate somewhat
stable randomness though in cases where White Noise does not
offer enough flexibility.

It uses hash functions from BLI_noise.hh. These are also used in
the White Noise node.

Pull Request: https://projects.blender.org/blender/blender/pulls/110769
2024-08-30 16:42:29 +02:00
YimingWu
b98b93ec8f Grease Pencil: Add menu corrections for GPv3
Correct line art icons for add menu in grease pencil v3, also
renamed "Suzanne" back to "Monkey" to keep it consistent with
GPv2.

Pull Request: https://projects.blender.org/blender/blender/pulls/126979
2024-08-30 15:43:40 +02:00
Jacques Lucke
1ee6a8fad5 Geometry Nodes: support customizing warning propagation
Previously, all errors, warnings and info messages were propagated from the node
that generates it to the top level node group. This is a good default, but may
not always be desirable. For example, someone may build a node group asset that
generates some warning that is irrelevant to the user to the asset. Now, the
asset author can selectively disable propagating warnings from that node.

Each node has a new `Warning Propagation` setting. It controls if warnings from
this node should be propagated to the parent group node. By default, everything
is propagated. One can also choose to propagate nothing, only errors or only
errors and warnings.

Note, this does not affect whether the warning is shown in the node itself, only
if the warning is propagated one level up!
Pull Request: https://projects.blender.org/blender/blender/pulls/126786
2024-08-30 12:06:48 +02:00
Julien Duroure
c132bd896f glTF exporter: children type check refactoring 2024-08-30 06:56:34 +02:00
Julien Duroure
11451a2082 glTF export: Add logging level control for export
This was already the case at import
2024-08-30 06:48:07 +02:00
Julien Duroure
4dad2a567d glTF: Use wait cursor instead of empty % cursor 2024-08-30 06:43:52 +02:00
Julien Duroure
8d575d3c85 glTF exporter: Enable exporting joint leaf at tail of leaf bones 2024-08-30 06:42:26 +02:00