1
1
Commit Graph

120102 Commits

Author SHA1 Message Date
c81d830ba0 Merge branch 'master' into temp-image-engine 2022-12-07 15:04:39 +01:00
3255ddc2f8 Rename some methods to represent their internal flag. 2022-12-07 15:03:36 +01:00
8db9d6bd6b Add back UDIM support. 2022-12-07 15:01:17 +01:00
2dc51fccb8 Fix T101787, T102786. Cycles: Improved out-of-memory messaging on Metal
This patch adds a new `max_working_set_exceeded()` check on Metal so that we can display a "System is out of GPU memory" message to the user. Without this, we get obtuse "CommandBuffer failed" errors at render time due to exceeding the size limit of resident resources.

Likely fix for T101787 & T102786.

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D16713
2022-12-07 13:56:21 +00:00
4d05a000cb Fix light tree header file included while feature disabled 2022-12-07 14:47:11 +01:00
f8ddf16e5a Cleanup: Typo in comment 2022-12-07 14:44:45 +01:00
6df6e537a3 Recalculate bounds when textures go offscreen. 2022-12-07 14:28:39 +01:00
cc1ba74ce2 Fix T102966: Curves editmode selection drawing not stable / flickering
Issue was the lifetime of GPUVertFormat & GPUVertAttr.
Both need to be static in the function to be persistent here (and
handled appropriately).

Was an error in rB319ee296fd0c.

Maniphest Tasks: T102966

Differential Revision: https://developer.blender.org/D16704
2022-12-07 09:40:54 +01:00
38f793d349 Remove visible flag. all textures are visible at all moments. 2022-12-07 08:53:26 +01:00
0ba5e6a8dd Rename dirty to need_full_update. 2022-12-07 08:45:48 +01:00
ff280aba1b Cleanup: renamed ensure_float_buffer to cached_float_buffer and remove wrapper function. 2022-12-07 08:41:43 +01:00
7ccb299fb7 Make sure textures are drawn in the right place. 2022-12-07 08:28:26 +01:00
0b85d6a030 3D View: support canceling viewport operations
Support Esc / RMB to cancel dolly, move, rotate & zoom.
Previously only roll could be canceled.

This can be useful to temporary orbit away from the camera or an
orthographic view without having to manually set it back.
2022-12-07 17:45:24 +11:00
dcd4eb4c25 Cleanup: minor refactor to view operator event handling
- Add VIEW_CANCEL event_code.
- De-duplicate operator freeing logic for the roll operator.
- Structure checks so adding cancel is is simplified.
- Split event checks into two blocks, one for model events, another
  for all other events.
2022-12-07 17:45:24 +11:00
0e90896cba Cleanup: simplify udim parameters when uv packing
Migrate (some) of the UDIM offset calculation from inside one
of the packing engines (where it's consumed) to the packing
operator (where it's produced).

This change (and others) will help simplify the future migration
of the packing engine inside editors/uvedit/uvedit_islands.cc
to the Geometry module, so it can eventually replace the other
packing engine in geometry/intern/uv_parametrizer.cc
2022-12-07 15:30:13 +13:00
a5f9f7e2fc OBJ: Avoid retrieving mesh arrays, improve const correctness
Store the potentially owned mesh separately from the original/evaluated
mesh which is now stored with a const pointer. Also store mesh spans
separately in the class so they don't have to be retrieved for every
index.
2022-12-06 15:26:42 -06:00
a459018a99 Cleanup: Simplify naming in UV sphere primitive
It's obvious that these are indices, no need for it to be part of names.
2022-12-06 14:25:43 -06:00
c1d4105005 Cleanup: Remove unnecessary indentation in cone primitive
The loop is skipped if there are zero iterations anyway.
2022-12-06 14:25:43 -06:00
ff324ab716 Cleanup: Make mesh primitive topology building more parallel
Avoid using an incremented "loop index" variable which makes the whole
data-filling necessarily sequential. No functional changes expected,
this just simplifies some refactors to face corner storage.
2022-12-06 14:25:43 -06:00
fd9b197226 GPU: Fix using FLOAT_2D_ARRAY and FLOAT_3D textures via Python.
Translation from python enum values were incorrect and textures created
in python using those types would result in faulty textures. In
renderdoc those textures would not bind.
2022-12-06 20:16:39 +01:00
3124241256 Fix Cycles SSE4 define for fast math rint function.
Differential Revision: https://developer.blender.org/D16708
2022-12-06 19:06:43 +01:00
48b5dcdbe8 Animation: Removal of most of the old pose library
Remove most of the old (pre-3.0) pose library:

- Remove The entire `editors/armature/pose_lib.c` file
- Deprecate `Object::poselib` in DNA
- Remove Operators marked as deprecated in T93405
- Remove RNA property `Object.pose_library`
- Add comment to clarify that the call `BLO_read_id_address(reader,
  ob->id.lib, &ob->poselib);` handles deprecated data.

Note that this functionality has been documented as deprecated since
Blender 3.2.

What remains of the old pose library: The DNA for action markers
(`bAction::markers`) and the corresponding Python API. This will allow
future versions of Blender to still convert old pose libraries to new
ones (via the Pose Library panel in the Action editor).

Manifest task: T93406
2022-12-06 18:37:10 +01:00
de9f32a666 Merge branch 'blender-v3.4-release' 2022-12-06 18:27:44 +01:00
38e1b92b7a Fix T102964: Key-map event type values changed for NDOF buttons
Regression in [0] changed NDOF key-map values.

Restore the previous values & add missing view buttons to
rna_enum_event_type_items.

[0]: ecda118be4

Differential Revision: https://developer.blender.org/D16701
2022-12-06 18:26:24 +01:00
7d99c51e17 Cycles: enable light tree again
Bugs that caused wrong renders should be fixed now, and tests that showed minor
floating point differences on platforms were tweaked to sidestep the problem.

Ref T77889
2022-12-06 18:18:53 +01:00
bc9548da80 Merge branch 'blender-v3.4-release' 2022-12-06 18:05:08 +01:00
Joseph Eagar
31ccf79011 Fix T102336: dynamic topology crash
Ensure there is always an active vertex when a face is hit.

Differential Revision: https://developer.blender.org/D16705
2022-12-06 18:03:26 +01:00
658220e815 Fix T101245: Allow Thumbnails of > 256:1 Images
Ensure that thumbnails of images with aspect greater than 256:1 have
dimensions of at least one pixel.

See D16707 for more details

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

Reviewed by Brecht Van Lommel
2022-12-06 08:17:50 -08:00
64541b242a Fix T102940: "Mask by Color" sculpt tool crash
We need to ensure the mask layer exists before running the operator.
I made the order of function calls here the same as in newer code later
on in this file for consistency.

Differential Revision: https://developer.blender.org/D16696
2022-12-06 08:17:50 -08:00
87582d95df Fix T101245: Allow Thumbnails of > 256:1 Images
Ensure that thumbnails of images with aspect greater than 256:1 have
dimensions of at least one pixel.

See D16707 for more details

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

Reviewed by Brecht Van Lommel
2022-12-06 08:15:05 -08:00
995f757049 Fix T102940: "Mask by Color" sculpt tool crash
We need to ensure the mask layer exists before running the operator.
I made the order of function calls here the same as in newer code later
on in this file for consistency.

Differential Revision: https://developer.blender.org/D16696
2022-12-06 10:00:12 -06:00
16b6116b9d Fix Cycles light tree render errors on Windows
Due to mistake in popcount implementation. Thanks to Weizhen for help
figuring this out.
2022-12-06 16:52:15 +01:00
8f213e7436 Merge branch 'blender-v3.4-release' 2022-12-06 16:39:51 +01:00
37b02b0432 Fix T102965: Crash when compiling shader tree with undefined mix nodes
node_set_typeinfo leaves the bNode::type value as-is for nodes with undefined types.
2022-12-06 16:39:21 +01:00
adea6681c0 Merge branch 'blender-v3.4-release' 2022-12-06 16:35:44 +01:00
212b054bb3 Update freedesktop file with Blender 3.4 features. 2022-12-06 16:34:53 +01:00
7a6630e5ce Enable other textures as well. 2022-12-06 16:23:16 +01:00
44748e6fe3 Initial transform from tile to texture. 2022-12-06 15:40:53 +01:00
6428c847fd Cycles oneAPI: clarify Linux Driver requirements in GUI
"Linux Driver" wasn't precise enough for users, the actual driver
requirement is on "Intel® Graphics Compute Runtime for oneAPI Level Zero
and OpenCL™ Driver", ie. https://github.com/intel/compute-runtime /
intel-level-zero-gpu package.

This follows-up the discussion on
https://developer.blender.org/rBff89c1793d8c75615ed43248def25812ec13e6e3
2022-12-06 13:21:19 +01:00
67dd652557 Tests: anim keylist test, avoid interaction between checks
Simplify checks so that one check doesn't influence the following one.

Checks no longer pass the last-visited frame number into the "start frame"
parameter of the next check. This way all test values are hard-coded and
easy to read, without having to understand how all the checks fit together.

No functional changes.
2022-12-06 12:27:16 +01:00
979930f8b6 Test: animation, avoid segfault in keylist unit tests
Replace `EXPECT_NE(column, nullptr)` with `ASSERT_NE(column, nullptr)` to
abort the test on failure. With `EXPECT_NE`, the test would continue onto
the next like, which accesses `column->cfra` and would segfault.

No functional changes to the tests. Just better reporting of failures.
2022-12-06 12:27:16 +01:00
997ff54d30 Fix: UI: broken texpaintslot/color attributes/attributes name filtering
rB8b7cd1ed2a17 broke this for the paint slots
rB4669178fc378 broke this for regular attributes

Name filtering in UI Lists works when:
- [one] the items to be filtered have a name property
-- see how `uilist_filter_items_default` gets the `namebuf`
- [two] custom python filter functions (`filter_items`) implement it
themselves
-- if you use `filter_items` and dont do name filtering there, the default
name filtering wont be used

So, two problems with rB8b7cd1ed2a17:
- [1] items to be listed changed from `texture_paint_images` to
`texture_paint_slots`
-- the former has name_property defined, the later lacks this
- [2] the new `ColorAttributesListBase` defined a `filter_items` function,
but did not implement name filtering

And the problem with rB4669178fc378:
- it added `filter_items` functions, but did not implement name filtering.

These are all corrected now.

Fixes T102878

Maniphest Tasks: T102878

Differential Revision: https://developer.blender.org/D16676
2022-12-06 11:09:28 +01:00
31943d1313 Fix T102937: "view3d.view_roll" operator conflicts with RMB invocation
When RMB is used to start the operator, don't use it for canceling.
2022-12-06 20:50:51 +11:00
ea14c48c09 Fix T102276: Hotkey conflict Alt D in Node Editor with Duplicate Linked and Detach
This unassign the Alt+D shortcut from the detach operator. Right now the
operator has to be accessed via the menu.

Alt+D is left for duplicate link, following the other editors.
2022-12-06 09:45:20 +01:00
979b295154 Fix incorrect cursor motion coordinates for WIN32
Cursor motion events on windows read the position from GetCursorPos()
which wasn't always the same location stored in `lParam`.

In situations where events were handled immediately this wasn't often a
problem, for heavier scenes or when updates between event handling was
slow - many in-between cursor events would be incorrect.

This behavior dates back to the initial commit, there doesn't seem to be
a good reason not to use the cursor coordinates from the event.

Noticed when investigating T102346.
2022-12-06 17:18:01 +11:00
d486f33d63 GHOST: OpenGL errors now use "file:line: " contention for errors
Make OpenGL errors match formatting used by GCC & clang
(as well as Blender's logging), so utilities that recognize this
convention can be used to quickly access this location.
2022-12-06 14:48:38 +11:00
f68e50a263 WM: operators that add their own undo pushes now clears the redo panel
Detect when the operator adds its own undo step and clear the panel.

An alternative fix for [0] which caused T101743.

Needed to prevent changing values in the last operator panel from
destructively undoing brush steps.

[0]: 11bdc321a2.

Reviewed By: mont29, joeedh

Ref D16523
2022-12-06 14:01:36 +11:00
7465aa8965 Merge branch 'blender-v3.4-release' 2022-12-06 13:47:40 +11:00
26f66e1423 Revert "Sculpt: Register sculpt brush op so it clears last operator panel"
This reverts commit 11bdc321a2.

This change caused T101743, in general OPTYPE_UNDO should not be used
to control the UI.

This also caused 2x undo pushes to be performed when sculpting,
although sculpt mode doesn't add a step for the second undo push
so it wasn't visible to the user.

An alternative fix will be applied separately as it's too risky this
close to a release.
2022-12-06 13:45:20 +11:00
db54b99ee1 BLI_path_util: support both forward and back slashes for WIN32
The following functions only supported back slashes on WIN32,
which can use both forward and back slashes.

- BLI_path_append
- BLI_path_append_dir
- BLI_path_slash_ensure
- BLI_path_slash_rstrip

Follow up to [0] which is a more limited bug-fix.

[0]: a16ef95ff6
2022-12-06 13:28:39 +11:00