Blender Git Loki

Blenderin Git "master"-kehityshaaran kommitit.

1 hour 19 min ago
Cleanup: spelling in comments
1 hour 19 min ago
Fix custom property editing with Python 3.10
1 hour 37 min ago
BlenLib: Add JSON Serialization/Deserialization Abstraction Layer.

Adds an abstraction layer to switch between serialization formats.
Currently only supports JSON. The abstraction layer supports
`String`, `Int`, `Array`, `Null`, `Boolean`, `Float` and `Object`. This
feature is only CPP complaint.

To write from a stream, the structure can be built by creating a value
(any subclass of `blender::io::serialize::Value` can do, and pass it to
the `serialize` method of a `blender::io::serialize::Formatter`. The
formatter is abstract and there is one implementation for JSON

To read from a stream use the `deserialize` method of the formatter.

{D12693} uses this abstraction layer to read/write asset indexes.

Reviewed By: Severin, sybren

Maniphest Tasks: T91430

Differential Revision:
1 hour 57 min ago
Geometry Nodes: don't log full fields when not necessary

Previously, the field on every socket was logged for later use. This had
two main negative consequences:
* Increased memory usage, because the fields may contain a lot of data
under some circumstances (e.g. a Ray Cast field contains the target geometry).
* Decreased performance, because anonymous attributes could not be
removed from geometry automatically, because there were still fields that
referenced them.

Now most fields are not logged anymore. Only those that are viewed by a
spreadsheet and constant fields. The required inputs of a field are still
logged in string form to keep socket inspection working.
2 hours 49 min ago
Animation UI: Make Ctrl+F use textbox instead of pop-up

Avoid blocking the UI when searching for animation channels with Ctrl+F.

Instead of showing a single text input in a blocking popup, Ctrl+F now
just focuses the search box above the channel list. It feels nicer to
use and has the niceties that come from using that textbox, like
searching per keystroke, compared to the old pop-up method.

As the behaviour of the operator has changed considerably, this also
changes the operator name from `anim.channels_find` to
`anim.channels_select_filter` and updates the keymaps.

Reviewed By: ChrisLend, sybren

Differential Revision:
2 hours 59 min ago
CMake: expand instructions for accidental 'cmake' run in source dir

Our CMake setup refuses to run from the source directory (i.e. Blender does
not support in-source builds). Instead, it shows instructions on how to
clean up after an accidental `cmake` invocation. These instructions missed
one directory that should also be removed (`CMakeFiles`), so that's been
added to the message now.

No functional changes to Blender or the build.
3 hours 20 min ago
Geometry Nodes: support viewing field values in spreadsheet

The viewer node has been expanded to have a field input next to the
geometry input. When both are connected (by ctrl+shift clicking on a node)
the spreadsheet will show the evaluated field on the geometry.

The operator to link to the viewer has become a bit smarter. It automatically
detects if it should link to the geometry or field input. In the future some more
smartness could be added, such as automatically relinking the "right" geometry
when viewing a field.

Internally, there are two major changes:
* Refactor of what happens when ctrl+shift clicking on a node to link to
a viewer. The behavior of the geometry nodes viewer is a bit more complex
than that of the compositor viewers. The behavior in compositing nodes
should not have changed. Any change should be reported as a bug (and then
we can decide if it's worse than before or if it needs fixing).
* Evaluation, display and caching of fields in the spreadsheet editor.

Differential Revision:
Revision fee2ced by YimingWu
3 hours 34 min ago
GPencil: Fix(unreported) Dash modifier wrong logic.

When the modifier iterates to an empty layer with no frame it will return,
while the correct logic is to continue.
4 hours 5 min ago

More in-line name with the rest of that macro-based API, especially
since this will be extended in the future.
4 hours 17 min ago
Cleanup: `else` after `continue`.
4 hours 32 min ago
Fix crash in liboverride/pointcache handling code after recent changes.

In some cases code would try to access NULL pointer.

Reported by @dfelinto, thanks.
4 hours 48 min ago
Cleanup: forgot to remove empty line in previous commit.
4 hours 54 min ago
Cleanup: build warnings.

`NULL` instead of `nullptr` in cpp code, and `else` statements after
Revision 5f9b00a by Peter Kim
6 hours 40 min ago
Cleanup: Remove unused parameter
Revision 89637f4 by Peter Kim
8 hours 4 min ago
Cleanup: Improve description for XR absolute tracking
Revision 9dbfa05 by Peter Kim
8 hours 5 min ago
XR: Only show ref space warnings in debug-xr mode

This avoids spamming the console for users who have not set up a
tracking space/boundary for their headsets.
Revision 9db13c8 by Peter Kim
8 hours 7 min ago
XR: Fix potential crash when toggling session
Revision 4c0512b by Peter Kim
8 hours 8 min ago
XR: Versioning for session draw flags, base scale
Revision 7ae2810 by Peter Kim
8 hours 11 min ago
XR: View adjustments for variable viewer scale

This adjusts some calculations and visibility flags for XR viewports in
order to account for a possible scale factor in the XR view matrix.

This scale factor can be introduced via the XR session settings base
scale, which allows a viewer to begin their session at a specific
reference scale, or the XR session state navigation scale, which allows
a viewer to adjust their scale relative to the reference scale during
the session.

Reviewed by Severin as part of D11501, but requested to be committed
Revision 3434a99 by Peter Kim
8 hours 11 min ago
XR Controller Support Step 5: Navigation

Adds navigation transforms (pose, scale) to the XR session state that
will be applied to the viewer/controller poses. By manipulating these
values, a viewer can move through the VR viewport without the need to
physically walk through it.

Add-ons can access these transforms via Python
(XrSessionState.navigation_location/rotation/scale) to use with custom

Also adds 3 new VR navigation operators that will be exposed to users
as default actions in the VR Scene Inspection add-on. While all three
of these operators have custom properties that can greatly influence
their behaviors, for now these properties will not be accessible by
users from the UI. However, other add-ons can still set these custom
properties if they desire.

1). Raycast-based teleport
Moves the user to a location pointed at on a mesh object. The result
can optionally be constrained to specific axes, for example to achieve
"elevation snapping" behavior by constraining to the Z-axis. In
addition, one can specify an interpolation factor and offset.

Credit to KISKA for the elevation snapping concept.

2). "Grab" navigation
Moves the user through the viewport by pressing inputs on one or two
held controllers and applying deltas to the navigation matrix based on
the displacement of these controllers. When inputs on both controllers
are pressed at the same time (bimanual interaction), the user can scale
themselves relative to the scene based on the distance between the

Also supports locks for location, rotation, and scale.

3). Fly navigation
Navigates the viewport by pressing a button and moving/turning relative to
navigation space or the VR viewer or controller. Via the operator's
properties, one can select from a variety of these modes as well as
specify the min/max speed and whether to lock elevation.

Reviewed By: Severin

Differential Revision:
Tehnyt: Miika HämäläinenViimeksi p?ivitetty: 07.11.2014 14:18 MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021