Commit Graph

2368 Commits

Author SHA1 Message Date
Pratik Borhade
7bfdc6dfea GPv3: Invert weight operator
Port gp legacy "invert weight" operator.

Pull Request: https://projects.blender.org/blender/blender/pulls/126275
2024-08-14 08:55:24 +02:00
Omar Emara
94d3b764e7 Geometry Nodes: Implement Gabor noise node
This patch ports the Gabor noise shader texture node into Geometry
Nodes.

Pull Request: https://projects.blender.org/blender/blender/pulls/125718
2024-08-14 08:48:17 +02:00
Jacques Lucke
d81ba55ce4 Fix #124467: lazy-connect does not work with Capture Attribute node
The lazy-connect feature of node wrangler uses the built-in `connect_sockets`
function which automatically handles virtual sockets in group input and output
nodes already. However, it does not handle virtual sockets in other nodes.

The fix is to generalize this behavior. For that, a new `handle_dynamic_sockets`
boolean input is added to `tree.links.new`. When enabled, virtual sockets are
handled properly by internally calling the `bNodeType.insert_link` methods.

The new behavior is turned of by default for compatibility reasons.

Pull Request: https://projects.blender.org/blender/blender/pulls/126282
2024-08-13 16:25:20 +02:00
Sean Kim
64211aa8c6 Sculpt: Add polyline gesture submit on double click
Originally, the polyline gesture tools were intended to have the gesture
submit on clicking on the starting point and pressing enter only. It was
brought up that the knife tool which has similar behavior also exposes
this on double clicking. To better align expected behavior across tools,
this commit adds similar functionality for the polyline tools.

Implements #125249

Pull Request: https://projects.blender.org/blender/blender/pulls/125391
2024-08-12 17:06:25 +02:00
Hans Goudey
be53bd079f Cleanup: Formatting 2024-08-12 09:47:02 -04:00
Pratik Borhade
c89b878371 GPv3: Sculpt context menu
Similar to GP legacy context menu of sculpt mode.

Pull Request: https://projects.blender.org/blender/blender/pulls/126135
2024-08-12 13:05:13 +02:00
Bastien Montagne
473456323f I18N: Extraction tools: Add timeout to async multi-processing.
Once in a while these get (dead)locked for some reason, at least avoid
having to kill the whole Blender then.
2024-08-12 13:00:46 +02:00
Jacques Lucke
e842966c5e Nodes: add group node default width
This adds the ability to customize the default width of a group node that's
created for a node group. This feature works towards the goal of unifying the
features available to built-in nodes and node groups. We often customize the
width of built-in nodes from them to looks slightly better (e.g. to avoid
cut-off labels).

Pull Request: https://projects.blender.org/blender/blender/pulls/126054
2024-08-11 19:25:53 +02:00
Bastien Montagne
7d52265771 Fix several issues with i18n tools on non-linux platforms.
- Paths of C++-parsed files were not properly 'unixified' on Windows.
  This was bad both for changes noisyness in PO files, and broke on
  the un-escaping of `\n` and `\t` sequences.
- The `ProcessPoolExecutor` starts sub-processes differently on Linux
  than on Windows or OSX. While Linux's `fork` keeps the same
  environment (i.e. all Blender stuff remains available in workers
  subprocesses), the 'spawn' used on Windows (and reportedly OSX) starts
  a new bare python interpreter. This means that code executed by these
  needs to be Blender-agnostic to be portable.

The only thing that is currently known broken on non-Linux platforms is
the RTL processing of some languages like Arabic or Hebrew.
2024-08-10 17:35:28 +02:00
Omar Emara
f2fcbc3330 Cleanup: Format 2024-08-08 17:36:23 +03:00
Pratik Borhade
9ca6e049a7 GPv3: Draw Mode: Context menu
Right click context menu has been missing in gpv3 draw mode.
Similar to gp legacy, this includes color picker, active layer etc.

Pull Request: https://projects.blender.org/blender/blender/pulls/125964
2024-08-08 16:03:09 +02:00
Omar Emara
f40cf759c7 Compositor: Add experimental option for new CPU compositor
This patch introduces a new experimental option for the new CPU
compositor under development. This is to make development easier such
that it happens directly in main, but the compositor is not expected to
work and will probably crash.

Pull Request: https://projects.blender.org/blender/blender/pulls/125960
2024-08-08 15:40:06 +02:00
Christoph Lendenfeld
a451971026 Fix #124691: Custom bone wire rendering broken on Mac
This issue occurred only on Mac which has to circumvent
geometry shaders lacking support for them.

This patch reverts the vertex shader for Mac devices to
how it was before f9ea64b0ba. (and uses the frag shader from before that commit)
In order to communicate that to the user I added a label
in the GUI when the platform is Mac.

Co-authored-by: Clément Foucault <foucault.clem@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/125967
2024-08-08 11:19:12 +02:00
Pablo Vazquez
000d34c398 EEVEE: Add toggle for Fast GI Approximation
Add a toggle for Fast GI Approximation in the header of the panel,
following Cycles layout.

Move the `Max Roughness` setting inside the panel, and rename to
Threshold.

Since Fast GI Approximation only has any effect when Threshold/
Max Roughness is below the max (1.0), gray out the rest of the
panel when at that value.

Co-authored-by: Clément FOUCAULT <foucault.clem@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/125452
2024-08-06 14:28:56 +02:00
Campbell Barton
f8e06a5f5f Fix #125763: Uninitialized extension repos printing warnings on startup
Since [0] missing repository directories printed a warning on startup.

When checking for blocked extensions on startup, skip directories
that don't exist & don't print any warnings if the repository data
hasn't been downloaded.

[0]: 656fe6d3e4
2024-08-06 20:53:41 +10:00
Campbell Barton
5110833ff1 Extensions: use wait cursor when toggling add-ons
Add-ons with large wheels can take a while to extract,
set the wait cursor so it's clear Blender is busy.
2024-08-06 12:48:08 +10:00
Devashish Lal
f6e6f2b2d2 Geometry Nodes: PLY import node
This commit adds a PLY format import node, part of the current Google
Summer of Code Project [0]. The importer is refactored to output a mesh,
and a node is added to wrap around the importer. The node supports error
messages from the importer. The node is hidden behind an experimental
option for now, like the others.

0: https://devtalk.blender.org/t/gsoc-2024-geometry-nodes-file-import-nodes/34482)

Pull Request: https://projects.blender.org/blender/blender/pulls/125587
2024-08-05 14:54:54 +02:00
Campbell Barton
fc6a99e0d2 Fix #77837: Error removing addons/extension/wheels on WIN32
When deleting files on WIN32, open files cannot be removed.
This is especially a problem for compiled Python modules which
remain open once imported.

Previously it was not as common for add-ons to include compiled Python
modules however with extensions supporting Python-wheels,
it's increasingly likely users run into this.

Workaround the problem by:
- Scheduling the files for removal next time Blender starts.
- Rename paths that cannot be removed to avoid collisions when
  the paths is reused (re-installing for example).

This is supported for:
- Extensions.
- Python wheels.
- Legacy user add-ons.
- App-templates.

Details:
- On startup, a file exists that indicates cleanup is needed.
  In the common case the file doesn't exist.
  Otherwise module paths are scanned for files to remove.
- Since errors resolving paths to remove could result in user data loss,
  ensure the paths are always within the (extension/addon/app-template)
  directory.
- File locking isn't used, if multiple Blender instances start at the
  same time and try to remove the same files, this won't cause errors.
  Even so, remove the checking file immediately avoid unnecessary
  file-system access overhead for other Blender instances.

Also resolves #125049.
2024-08-05 09:49:14 +10:00
Campbell Barton
afa44b16a6 Fix error installing app-templates & legacy add-ons overwriting symlinks
Resolve error when overwriting existing Python modules would attempt
to recursively remove a symlink which raised an error.

Related to #123827, same error but for extensions.
2024-08-04 20:58:48 +10:00
Campbell Barton
805f66c5c4 Extensions: restore fix for removing extensions with symlinks
Regression from [0], removed the fix for #123827.

[0]: 08b75549e3
2024-08-04 20:52:00 +10:00
Pratik Borhade
e60422c5a7 GPv3: Delete active keyframe operator
Port missing keyframe operator to new structure.
Found this missing operator during #125261

Pull Request: https://projects.blender.org/blender/blender/pulls/125770
2024-08-02 08:18:32 +02:00
Pablo Vazquez
b00a16b4e1 VSE: Place modifier-specific properties first
Modifiers in the VSE have mask properties first, then modifier-specific
settings. This breaks consistency with other modifiers for objects
and Grease Pencil.

Move Mask properties to the bottom, after a separator, and group them
in a column for better alignment.

Fixes #120360

Pull Request: https://projects.blender.org/blender/blender/pulls/125710
2024-08-01 11:28:58 +02:00
Dalai Felinto
7b8640896e Templates: Blender Manifest template
Pull Request: https://projects.blender.org/blender/blender/pulls/125668
2024-08-01 10:15:01 +02:00
Dalai Felinto
7084465393 Templates: Remove bl_info from addon_add_object 2024-08-01 10:14:59 +02:00
Pablo Vazquez
27c06ccd15 UI: VSE: Apply writing style on modifier labels
* Remove colons on labels.
* Do not include "Use" in checkboxes.

https://developer.blender.org/docs/features/interface/human_interface_guidelines/writing_style/
2024-07-31 14:07:22 +02:00
Campbell Barton
ef505727c6 Fix error where upgrading an extension always enabled it
Upgrading disabled extensions should never enable them.
2024-07-31 13:50:22 +10:00
Campbell Barton
14b03fca3c PyAPI: add bpy.app.python_args, use when calling Python from Blender
Expose arguments to use when creating a Python sub-process.

Python could fail to start when loaded in a customized environment,
with PYTHONPATH set for e.g. Blender ignores these and loads but a
Python sub-process attempts to use these environment variables which
may point to incompatible Python versions.

Resolve the root cause of #124731.
2024-07-31 11:59:23 +10:00
Campbell Barton
2cf09525a7 PyAPI: include bpy.utils.extension_path_user in __all__
This wasn't being included in generated docs.
2024-07-31 09:52:25 +10:00
Miguel Pozo
0c429ee652 Fix #125387: Cycles Material Panel shows EEVEE Legacy settings
Update `draw_material_settings` to show EEVEE Next properties.
This only changes the internal function, instead of the Panel classes
themselves, to avoid breaking the Python API.

Pull Request: https://projects.blender.org/blender/blender/pulls/125616
2024-07-30 17:49:25 +02:00
Sybren A. Stüvel
ba1f7caffa Fix #125226: Anim: Rigify limbs.spline_tentacle doesn't generate correctly
A template string was accidentally turned into an f-string in
78b9218c98, which changes the way it is
evaluated. Easy enough to roll back that one change.
2024-07-30 16:13:27 +02:00
Campbell Barton
3a88af5402 Fix #125660: Extensions fail to sync HTTPS repositories on WIN32
Workaround: `[ASN1] nested asn1 error` error when making HTTPS
connections on systems with certificates that OpenSSL cannot parse
are installed.

This is a general issue with Python, resolve by applying a proposed
fix [0] to the extensions Python process at run-time.
(this doesn't impact Blender's Python run-time).

The down side is HTTPS connections will only work for extensions
on systems with this problem so this needs to be resolved by Python
long term.

While any changes to Python's SSL checks is worth avoiding,
this simply skips SSL certificates in the windows store that OpenSSL
can't parse instead of failing all SSL connections.

See related issues:

- https://github.com/python/cpython/issues/79846
- https://github.com/openssl/openssl/issues/25023

[0]: https://github.com/python/cpython/pull/91740

Ref !124943.
2024-07-30 22:49:21 +10:00
Leon Schittek
d30d8b4bfa UI: Add padding to items in ui lists and tree views
Add a utility function to add horizontal padding to the left and right
of items in UI lists and tree views to make them more consistent with
other buttons like menu entries.

Pull Request: https://projects.blender.org/blender/blender/pulls/125498
2024-07-29 23:52:38 +02:00
softyoda
5e9096829c Cycles: Add Central Cylindrical Panoramic camera model
This type of projection is often used e.g. in exhibitions that leverage big
curved screens.

Effectively, the frame is mapped onto a cylinder, with the x axis becoming the
longitude and y axis becoming the height.

Users can configure the min/max longitude, the min/max height and the radius of
the cylinder.

Co-authored-by: Lukas Stockner <lukas.stockner@freenet.de>
Pull Request: https://projects.blender.org/blender/blender/pulls/123046
2024-07-29 15:03:57 +02:00
nutti
e0cdfb8566 Fix: Docstring of the bpy.utils.user_resource argument
Correct argument name is `resource_type`

Pull Request: https://projects.blender.org/blender/blender/pulls/125316
2024-07-29 14:04:41 +02:00
Falk David
0f42f277b7 Grease Pencil: Remove legacy modifiers
This removes the legacy Grease Pencil modifiers from the code.
These should have already been inaccessible from the UI and hidden from
the user. The modifiers have been reimplemented for the new GPv3
data structure.

On top of the modifier code, some other related things have been
removed as well:
 * Operators related to the legacy modifiers.
 * Keymaps for the legacy modifier operators.
 * Some bits of code that used modifier functions.

Some code has to be kept, because it is still used:
 * The core line art code, which is used by the new line art modifier. It's
    moved to `modifiers/lineart`.
 * The DNA structs for the legacy modifiers. They are still needed for
    conversion.
 * A few kernel functions for the modifiers are kept (also for conversion).

Co-authored-by: Lukas Tönne <lukas@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/125102
2024-07-29 10:37:29 +02:00
Harley Acheson
f2f408bebf UI: Tooltip Final Period and Other Typography
This removes the terminal periods automatically added to the end of
tooltip items. The current desire is to only end in period if there
are multiple sentences - so if there is one in the middle of the
description. This also converts our uses of lists to use space and
bullet, rather than just bullet or asterisks.

Pull Request: https://projects.blender.org/blender/blender/pulls/125460
2024-07-26 18:29:50 +02:00
Pratik Borhade
1da83ab046 GPv3: Duplicate active keys operator
Port legacy `frame_duplicate()` operator.

Pull Request: https://projects.blender.org/blender/blender/pulls/125369
2024-07-26 15:39:42 +02:00
Germano Cavalcante
0dad3bdfa7 Fix #123179: can't select multiple snap target elements in UV Editor
Missed after 'Set Snap Base' commit.

Just like in 3D View, UV editing can also benefit from selecting
multiple snap target elements.

The C++ code was already done, it was only necessary to edit the
interface.

Pull Request: https://projects.blender.org/blender/blender/pulls/124986
2024-07-26 14:59:13 +02:00
Sybren A. Stüvel
7346ef03f4 Anim: hide slot selector in Action editor behind experimental flag
Hide the Action Slot selector in the Action editor behind the experimental
flag. Not only shouldn't it be shown, but also it uses an API that's only
available in experimental builds.
2024-07-26 14:34:20 +02:00
Campbell Barton
656fe6d3e4 Extensions: support "blocklist" in the remote repository
Support blocking extensions so there is a way for the maintainers of
the remote repository to notify the user if one of their installed
extensions blocked along with a reason for blocking.

Blocked extensions cannot be installed from the preferences or by
dropping a URL.

When an installed & blocked extension is found:

- An icon int the status bar shows an alert,
  clicking on the icon shows the blocked extensions.
- The extensions preferences show a warning.
- The extensions & add-ons UI shows an alert icon
  and "details" section shows the reason.

Details:

- Blocked & installed extensions are shown first in the installed
  extensions panel.
- The internal "install" logic prevents downloading & installing
  blocked extensions.
- Blocked extensions can still be downloaded & installed from disk.
- The "list" command includes an error message if any installed
  extensions are blocked.
- The "server-generate" command can optionally take a configuration
  file that includes the blocklist for the generated JSON.

See design #124954.
2024-07-26 16:05:34 +10:00
Campbell Barton
8019ad8912 Fix unhandled exception for non dictionary items in extensions repo
Ensure items in the repository list are dictionaries.
2024-07-26 11:50:26 +10:00
Campbell Barton
b4d5c6eea5 Cleanup: remove unused imports 2024-07-26 10:26:11 +10:00
Harley Acheson
5bf44c6eb4 UI: Text Style for Tooltips
This gives users the ability to control the size of tooltip text
separately from other text styles. This is an accessibility issue
in that users with low vision can choose to make these larger than
the working text.

Pull Request: https://projects.blender.org/blender/blender/pulls/125147
2024-07-25 19:12:41 +02:00
Lukas Tönne
f7672438bf GPv3: Trace image operator
Convert an image to grease pencil strokes by tracing features.

Uses the Potrace library to generate curve on averaged b/w values of the image.
Ported from the GPv2 feature of the same name.

Pull Request: https://projects.blender.org/blender/blender/pulls/125328
2024-07-25 18:44:07 +02:00
Sybren A. Stüvel
a8ee0b9a05 Anim: add Action Slot selector to Action editor
Add an Action Slot selector to the Action editor's header, next to the
Action selector. The selector shows all slots in the action that are
suitable for animating objects (as the Action editor itself is limited
to showing the Action of the active object).

This also considerably simplifies the 'Animation Debug' panel, as some
debugging code has been removed, as well as the display of any animation
layers. The latter can be reintroduced (if necessary) when multi-layer
animation support is added. Most importantly, it removes the
WindowManager property that was used as a hack to assign layered Actions
to objects.

API change: the RNA property `AnimData.slot` is now a pointer property
that reflects the actual slot (it used to be an enum property).

Some small changes to the UI code were necessary to make the selector
show the slot's display name (and not their internal name).

Pull Request: https://projects.blender.org/blender/blender/pulls/125416
2024-07-25 17:20:27 +02:00
Pablo Vazquez
784aca8cbc UI: Use hyphen as separator for attribute lists
Replace the "play" emoji ▶ with a hyphen as separator in attribute
lists (Attributes and Color Attributes panel).

The hyphen uses less space while at the same time adding negative
space around domain/datatype making it easier to scan through the list.

See pull request for images.

Pull Request: https://projects.blender.org/blender/blender/pulls/125436
2024-07-25 17:15:46 +02:00
Julian Eisel
0baeca8f9e Fix #123735: Tooltip missing from open URL preset operator
Necessary because the "type" property is no longer the default
`bl_property` since 7bc34283ea.
2024-07-25 12:28:50 +02:00
Sybren A. Stüvel
abf0a2ba05 Anim: rename 'Baklava' panel to 'Animation Debug'
This makes it clearer that this panel is for debugging the new animation
system, and not intended to represent any final user interface.
2024-07-25 11:57:49 +02:00
Sybren A. Stüvel
da458c66e5 Anim: only show Action Slot panel when experimental flag set
Only show the Action Slot panel in the dope sheet when the experimental
flag is set.
2024-07-25 11:41:37 +02:00
Campbell Barton
2edc2393d2 Cleanup: spelling in comments 2024-07-25 10:17:42 +10:00