Commit Graph

132017 Commits

Author SHA1 Message Date
Sergey Sharybin
c368a2c345 Cleanup: Strict compiler warning
A static function is only used from asserts, generating unused
warning for release builds.

Pull Request: https://projects.blender.org/blender/blender/pulls/117398
2024-01-22 10:01:05 +01:00
Campbell Barton
a1761b7c8c UI: adjust the add-ons interface when extensions repositories enabled
- Group Extensions with Add-ons in preferences.
- No more official/community/testing, install and refresh.
- No more showing category on the headers
  (there are no categories for extensions).

Changes proposed in #117285.
2024-01-22 17:47:33 +11:00
Campbell Barton
af160e1613 Cleanup: avoid many allocations recursive filesystem ops on Linux/Unix
Replace string duplication with a buffer that grows as needed and
reuses the existing buffer in nested functions.
2024-01-22 14:42:59 +11:00
Campbell Barton
5b59be81ba Cleanup: spelling in comments 2024-01-22 12:44:56 +11:00
Campbell Barton
c866c93b06 Cleanup: import UIList, following the convention for other UI classes 2024-01-22 12:44:56 +11:00
Campbell Barton
829d08ca42 Cleanup: move addon_category_name into an internal class method 2024-01-22 12:44:54 +11:00
Campbell Barton
f0357220c0 Cleanup: don't pass UI text through iface_ twice 2024-01-22 12:44:53 +11:00
Guillermo Venegas
d7aa1988d1 UI: Replace list of workspace add-ons with a UIList
The list of add-ons could be long without the ability to search or
scroll the list. Using a UI-list.

Resolves #111272

Ref !112684
2024-01-22 12:44:37 +11:00
Campbell Barton
ff333ef397 Cleanup: format 2024-01-22 12:01:45 +11:00
Campbell Barton
d43988e014 Unbreak build from missing include 2024-01-22 11:54:10 +11:00
Bastien Montagne
3df7939eec Cleanup: Move BKE_blender_undo.h to full Cpp header BKE_blender_undo.hh. 2024-01-21 19:49:58 +01:00
Bastien Montagne
d8d44a62f7 Cleanup: Move BKE_appdir.h to full Cpp header BKE_appdir.hh. 2024-01-21 19:42:13 +01:00
Bastien Montagne
6a9d2212e4 Cleanup: Move BKE_blender_copybuffer.h to full Cpp header BKE_blender_copybuffer.hh. 2024-01-21 19:34:20 +01:00
Bastien Montagne
6fcb92fd93 Cleanup: Move BKE_blender_user_menu.h to full Cpp BKE_blender_user_menu.hh. 2024-01-21 19:26:31 +01:00
Bastien Montagne
bfe2e5a069 Cleanup: Move BKE_autoexec.h to full Cpp header BKE_autoexec.hh. 2024-01-21 19:13:46 +01:00
Jacques Lucke
b92443e1d9 Geometry Nodes: optimize single value access in NodeSocketValue
The goal is to get rid of some constant overhead to avoid the small regression mentioned in https://projects.blender.org/blender/blender/pulls/116231#issuecomment-1086124.

Now it is possible to get more direct access to single values stored in `NodeSocketValue`.

Benchmark using the `many_math_nodes` file:
```
version          3.3      3.6      4.0      patch    main
many_math_nodes  0.5352s  0.0606s  0.0293s  0.0292s  0.0304s
```

Pull Request: https://projects.blender.org/blender/blender/pulls/117309
2024-01-21 13:22:16 +01:00
Bastien Montagne
af5731ce03 Cleanup: Move BKE_idtype.h to Cpp header BKE_idtype.hh 2024-01-20 19:17:36 +01:00
Hans Goudey
bbaa4e9d26 Fix #117354: Crash loading file browser tooltips
Caused by 6abf43cef52a3186642959270bfbabe1ea3dc5f3
2024-01-20 10:26:29 -05:00
Pratik Borhade
33bb3d838f Fix #117224: Outliner recursive selection fails in reverse order
Call `do_outliner_select_recursive` for active tree-element
in range_select function to select children of active te.

Pull Request: https://projects.blender.org/blender/blender/pulls/117265
2024-01-19 21:21:27 +01:00
Aras Pranckevicius
d2e4da0f5b Cleanup: reduce C-isms in imbuf headers
Pull Request: https://projects.blender.org/blender/blender/pulls/117327
2024-01-19 20:29:43 +01:00
Aras Pranckevicius
a705259b4b Cleanup: move imbuf .h files to .hh 2024-01-19 20:29:38 +01:00
Brecht Van Lommel
487adcb992 Fix: build error when not using unity build 2024-01-19 20:12:45 +01:00
Harley Acheson
9de0dac46e Cleanup: Make format
Formatting changes resulting from Make Format
2024-01-19 11:10:00 -08:00
Hans Goudey
02342aee0c Cleanup: Sculpt: Store auto-masking cache in unique_ptr 2024-01-19 13:44:42 -05:00
Hans Goudey
0163a92cca Cleanup: Simplify local automasking function names
Remove redundancy with the file's namespace.
2024-01-19 13:27:03 -05:00
Brecht Van Lommel
2afd9e530a Fix: wrong name in bpy_extras.object_utils, causing API doc build failure 2024-01-19 19:03:33 +01:00
Aras Pranckevicius
0dc3ffb5af Fix: windows compile error
Another ambiguous conversion for msvc introduced in baeb4d775393e
2024-01-19 19:34:56 +02:00
Hans Goudey
21407901f8 Cleanup: Various clang tidy changes 2024-01-19 12:08:48 -05:00
Hans Goudey
7ca4dcac5a Cleanup: Use std::string for UI drop box tooltip return type
And use fmt for formatting strings.
2024-01-19 12:08:48 -05:00
Aras Pranckevicius
b2ef92361f Fix: windows compile error
Ambiguous conversions for msvc introduced in baeb4d775393e
2024-01-19 18:58:55 +02:00
Harley Acheson
a510bad81a UI: Change of File Save Icon
UI Module agreed to change of the Save icon to a version, also created
by Andrzej Ambroz, that resembles a traditional floppy-disc style.

Pull Request: https://projects.blender.org/blender/blender/pulls/117251
2024-01-19 17:54:29 +01:00
Omar Emara
4bf08198a7 Compositor: Do not flip bounds of Crop node
The Crop node currently flips its bounds if the lower bound is larger
than the higher bound, which is not a good design. Instead, clamp the
bounds.
2024-01-19 18:42:45 +02:00
Sergey Sharybin
73d9271701 Fix Keying Screen node on Metal GPU
The "Keying Screen" texture is written by the compositor_keying_screen
shader and is not read by the shader. Use appropriate usage flag which
matches the shader behavior.

Note that the texture is read by a node down the road, so both flags are
needed.

Pull Request: https://projects.blender.org/blender/blender/pulls/117340
2024-01-19 17:20:07 +01:00
Lukas Tönne
baeb4d7753 GPv3: Tint and Color modifiers
Implements the Tint and Color (aka. "Hue/Saturation") modifiers.

Pull Request: https://projects.blender.org/blender/blender/pulls/117297
2024-01-19 16:59:39 +01:00
Christoph Lendenfeld
5e28601d69 Anim: Separate keying flags
Splits the flag `..._FLAG_INSERTNEEDED` between autokey and
manual keying. The fact that this flag was shared between the two
systems has been the cause of issues in the past. It wouldn't
let you insert a keyframe even though you explicitly used an operator
to do so.

In order to be clearer what options are used where, the user preferences
have been reordered.

By default "Only Insert Needed" will be enabled for auto-keying, but not for manual keying.
The versioning code will enable both if it was enabled previously.

# Code side changes

The keying system has flags that define the behavior
when keys are inserted. Some of those flags were shared
between keying and auto-keying. Some were only used for
auto-keying.
To clarify that, prefix flags that used exclusively in one or the other
system with `AUTOKEY`/`MANUALKEY`

Also the flag name on the user preferences and the tool settings was renamed.
Previously it was called `autokey_flag`. To indicated that it is not only used
for autokeying, rename it `keying_flag`.

Fixes: #73773

Pull Request: https://projects.blender.org/blender/blender/pulls/115525
2024-01-19 16:26:10 +01:00
Omar Emara
2bff75c303 Tests: Enable blacklisted GPU compositor tests
Those tests are now expected to work.
2024-01-19 16:36:31 +02:00
Hans Goudey
e0202a6e42 Cleanup: Use C++ vector types in paint stroke struct 2024-01-19 09:27:56 -05:00
Hans Goudey
75b5ef3270 Cleanup: Remove unused paint stroke field 2024-01-19 09:27:56 -05:00
Hans Goudey
61692370d2 Cleanup: Use C++ random number generator for paint stroke 2024-01-19 09:27:56 -05:00
Hans Goudey
d7cca9f1d8 Cleanup: Move paint stroke code to C++ namespace 2024-01-19 09:27:56 -05:00
Hans Goudey
8c6e763fd0 Cleanup: Remove unused BLI_time.h includes 2024-01-19 09:27:56 -05:00
Hans Goudey
490c50c718 Cleanup: Use camel case for file tooltip struct name 2024-01-19 09:27:56 -05:00
Hans Goudey
6abf43cef5 Cleanup: Use std::string to store and pass tooltip text
Store temporrary tooltip text as `std::string` instead of
manually allocated C strings. Use `fmt` to format instead
of our own formatting utilities that return an allocated C
string.
2024-01-19 09:27:56 -05:00
Hans Goudey
90c4e2e6ec Cleanup: Replace UI button "string info" function
Instead of a single function with variadic arguments, a special enum
type containing which string to request, and a special struct to
contain the request and the result, just use separate functions for
each request, and return a std::string by value. Also change the enum
item string access to just give access to the enum item itself and add
const in a few places as necessary.

The callers of the API function get much clearer this way, and it's
much easier to see which information is used to create certain tooltip
strings.
2024-01-19 09:27:56 -05:00
Brecht Van Lommel
cb787a458b Build: use C++17 for CUDA kernels when supported
This helps with compatibility with recent clang versions as host compiler.

Pull Request: https://projects.blender.org/blender/blender/pulls/117311
2024-01-19 15:19:33 +01:00
Falk David
c5dff902a6 GPV3: Modifiers: Add get_drawing_infos_for_write
This API returns a vector with a pointer to each drawing as well
as the starting frame for the keyframe that the drawing came from.
2024-01-19 14:58:07 +01:00
Falk David
b6ed5eea8d GPv3: Return std::optional from frame_key_at
Previously, `frame_key_at` would return `-1` for when it couldn't find
a key for the given frame.
This could lead to issues though, because `-1` is a valid key (it is a valid scene frame number).

This changes the API to return an optional instead. This makes it very clear
when no key was found, and should make it less error prone.
2024-01-19 14:58:07 +01:00
0602683ec2 Cleanup: Anim, add missing #pragma once
No functional changes.
2024-01-19 14:54:45 +01:00
Philipp Oeser
8189e2266b Revert "Fix #68436: External Particle Disk Cache Playback Is Broken"
this broke the dynamic paint test

This reverts commit ab9c0af1ceb0fed54a08c21467ad0ceeea515c8a.
2024-01-19 14:53:43 +01:00
Sergey Sharybin
f8c283d2b7 Fix: Assert in geometry nodes in specific files
Possibly also fixes write past array boundaries.

Happens with the mikassa-shading.blend file, by simply opening
the file in debug mode. The fix is suggested by Jacques.

Pull Request: https://projects.blender.org/blender/blender/pulls/117331
2024-01-19 14:52:43 +01:00