Age | Commit message (Collapse) | Author |
|
|
|
Creating some primitives allows for a scale value (via python) that will
scale the object accordingly. For objects with a radius parameter
(like cylinders, spheres, etc.) passing a scale different to (1,1,1)
would result in unexpected behavior.
For example:
`>>> bpy.ops.mesh.primitive_uv_sphere_add(radius=2, scale=(1,1,2))`
We would expect this to create a sphere with a radius of 2
(dimensions 4,4,4) and then be scaled *2 along the z-axis
(dimensions 4,4,8). But this would previously create a scaled sphere
with dimensions (2,2,4).
The scale was simply divided by two. Maybe because the "radius"
parameter for creating the primitives was confusingly named "diameter"
(but used as the radius).
The fix adds a scale parameter to `ED_object_new_primitive_matrix`
and also renames the wrongly named "diameter" parameters to "radius".
Reviewed By: campbellbarton
Maniphest Tasks: T84638
Ref D10093
|
|
|
|
Added optional `name` argument to `GPUShader` constructor
(defaults to `pyGPUShader`), and added `name` getter to `GPUShader`.
Ref D12393
Reviewed By: campbellbarton, jbakker
|
|
|
|
|
|
|
|
With this commit, curve objects support the geometry nodes modifier.
Curves objects now evaluate to `CurveEval` unless there was a previous
implicit conversion (tessellating modifiers, mesh modifiers, or the
settings in the curve "Geometry" panel). In the new code, curves are
only considered to be the wire edges-- any generated surface is a mesh
instead, stored in the evaluated geometry set.
The consolidation of concepts mentioned above allows remove a lot of
code that had to do with maintaining the `DispList` type temporarily
for modifiers and rendering. Instead, render engines see a separate
object for the mesh from the mesh geometry component, and when the
curve object evaluates to a curve, the `CurveEval` is always used for
drawing wire edges.
However, currently the `DispList` type is still maintained and used as
an intermediate step in implicit mesh conversion. In the future, more
uses of it could be changed to use `CurveEval` and `Mesh` instead.
This is mostly not changed behavior, it is just a formalization of
existing logic after recent fixes for 2.8 versions last year and two
years ago. Also, in the future more functionality can be converted
to nodes, removing cases of implicit conversions. For more discussion
on that topic, see T89676.
The `use_fill_deform` option is removed. It has not worked properly
since 2.62, and the choice for filling a curve before or after
deformation will work much better and be clearer with a node system.
Applying the geometry nodes modifier to generate a curve is not
implemented with this commit, so applying the modifier won't work
at all. This is a separate technical challenge, and should be solved
in a separate step.
Differential Revision: https://developer.blender.org/D11597
|
|
Calms warning for unused variable in `constraint_copy_to_selected_poll`
by using UNUSED_VARS.
See D12453 for further details
Differential Revision: https://developer.blender.org/D12453
Reviewed by Campbell Barton
|
|
Adds full frame implementation to PreviewOperation.
Part of T88150.
|
|
It was causing some tests to fail when enabling Full Frame mode.
|
|
Since fields were committed to master, socket inspection did
not work correctly for all socket types anymore. Now the same
functionality as before is back. Furthermore, fields that depend
on some input will now show the inputs in the socket inspection.
I added support for evaluating constant fields more immediately.
This has the benefit that the same constant field is not evaluated
more than once. It also helps with making the field independent
of the multi-functions that it uses. We might still want to change
the ownership handling for the multi-functions of nodes a bit,
but that can be done separately.
Differential Revision: https://developer.blender.org/D12444
|
|
|
|
Now an instruction knows the cursors where it is inserted instead
of just the instruction that references it. This has two benefits:
* An instruction knows when it is the entry instruction.
* The cursor can contain more information, e.g. if it is linked to the
true or false branch of a branch instruction.
This also simplifies updating the procedure in future optimization
passes.
|
|
Mostly renaming the variables to improve line wrapping.
But also the "foreach_attribute" loops look simpler now.
Also use `Spline::copy_base_settings` and don't bother
with an extra call to reallocate the attribute arrays.
|
|
Just like the curve to points node, this mode outputs point locations
based on the input curve's evaluated points (the points you see in the
viewport). This is expected to be faster, since it doesn't have to
sample equal positions on the result, and it's also consistent with
the existing choices in the curve to points node.
|
|
Also use it to fix an incorrect min and max in the cube mesh
primitive node.
|
|
Improvements to Quad View options' titles and descriptions.
See D12381 for more details.
Differential Revision: https://developer.blender.org/D12381
Reviewed by Hans Goudey and Campbell Barton
|
|
|
|
rBe2f99c338bd57 should have used the subversion currently defined
in Blender, instead it used one lower, so some files didn't have the
versioning applied.
|
|
It appears an old version of this file was committed by accident. The
intended change to remove sculpt layers was done in versioning code and
does not require a modified startup.blend.
|
|
Flag the changed object and its bones to update after moving a
constraint in the stack up or down. The two operators for move up and
move down seem to be unused, but I notices they had the same problem, so
I added the update there as well.
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D12174
|
|
Refactor of our Vfont check for font validity.
See D12068 for further details.
Differential Revision: https://developer.blender.org/D12068
Reviewed by Campbell Barton
|
|
Recently we have decided to avoid fancier versioning for nodes with
string inputs for attribute names when updating the attribute workflow
for 3.0. In that case we would just duplicate any node that will
have an updated version to work with fields.
We want to be able to use the "proper" ID names for the new versions
of the nodes though, so this patch adds "Legacy" to the IDs of all
nodes that will be replaced in 3.0. This commit also removes the nodes
from the add menu when the fields experimental preference is enabled,
in order to make it clear what has been updated and what hasn't.
Nodes in the "Maybe" categories in versioning_300.c can be renamed
later if necessary. For now it's probably better to be conservative,
and to keep the list complete.
Differential Revision: https://developer.blender.org/D12420
|
|
Previously fluid simulation and Alembic modifiers had a dedicated function
to query the velocity for motion blur. Now use a more generic system where
those modifiers output a velocity attribute.
Advantages:
* Geometry and particle nodes can output velocity through the same mechanism,
or read the attribute coming from earlier modifiers.
* The velocity can be preserved through modifiers like subdivision surface or
auto smooth.
* USD and Alembic previously only output velocity from fluid simulation, now
they work with velocity from other sources too.
* Simplifies the code for renderers like Cycles and exporters like
Alembic and USD.
This breaks compatibility:
* External renderers and exporters accessing these velocities through the
Python API now need to use the attribute instead.
* Existing modifier node setups that create an attribute named "velocity"
will render differently with motion blur.
Differential Revision: https://developer.blender.org/D12305
|
|
Leave current test result unchanged and stop executing immediately,
so it can be continued.
|
|
Amendment to 7a5216497cc3.
Removed this before committing, because I thought it wasn't needed. Of
course it was...
|
|
Use `_PyThreadState_UncheckedGet()` to check that the current thread is
tracked by Python before checking whether it has the GIL. The latter
will abort when the former is false.
|
|
A task is created for each item in a list base. It used to say that a
thread was created for each item.
|
|
For some reason the asset preview isn't created or loaded correctly in
some instances. This could be addressed with D9974, but hard to tell
since I only have a failing .blend file, no steps to recreate it from
scratch.
Would crash when opening an Asset Browser, selecting an object asset
(that has an invalid preview stored) and opening the Asset Browser
sidebar, so that the preview is visible there.
|
|
This enabled multithreaded building of the keys that needs to be drawn
in the timeline (and other action editors).
On an AMD Ryzen 3800 using a mocap data test file (available in patch)
the performance went from 2fps to 8fps. The performance increase depends
on the number of rows of keyframes that is shown in for example the
timeline editor.
Each row will be using a different thread. Currently the bottleneck is
the summary channel that we could split up in the future even more (
although that is a complex refactoring work).
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D12198
|
|
This patch adds new Perlin noise functions to BLI. The noises are compatible
with the shading texture noises in EEVEE, SVM, and OSL.
The existing Jenkins hash functions couldn't be used because they are not
compatible with the shading implementations and an attempt at adjusting the
implementation will break compatibility in various areas of Blender. So the
simplest approach is to reimplement the relevant hashing functions inside the
noise module itself.
Additionally, this patch also adds a minimal float4 structure to use in the
interface of the noise functions.
Reviewed By: JacquesLucke
Differential Revision: https://developer.blender.org/D12443
|
|
Change data structure of keylists. Reducing the balancing overhead and therefore increases performance.
| **Function** | **Master** | **Patch** |
|`draw_summary_channel`| 0.202105s| 0.083874s |
When adding items to the keylist it will store it in a linked list. This linked list is
accompanied with the length (key_len) and a `last_accessed_column`. last_accessed_column is a cursor
that improve the performance when adding new items as they are mostly ordered by frame numbers.
last_accessed_column is reset when a new fcurve/mask/... is added to the keylist.
Before searching or array access. the listbase needs to be converted to an array.
`ED_keylist_prepare_for_direct_access`. After that the caller can use
`ED_keylist_find_*` or `ED_keylist_array*` functions.
The internal array can also be accessed via the `ED_keylist_listbase` function.
The items inside the array link to the previous/next item in the list.
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D12052
|
|
Remove sculpt mask layer from the default cube, added in
444934632a8d8e239bc0c6d79a638ec0943152a6.
|
|
Evaluating the dependency graph potentially executes Python code when
evaluating drivers. In specific situations (see T91046) this could
deadlock Blender entirely. Temporarily releasing the GIL when evaluating
the depsgraph resolves this.
This is an improved version of
rBfc460351170478e712740ae1917a2e24803eba3b, thanks @brecht for the diff!
Manifest task: T91046
|
|
by linked/appended data.
Do not instantiate obdata when it is not actually loose.
|
|
|
|
Changed doc string for Blender `--addons` command line argument
to explain what it does rather than just describing what it expects.
Reviewed By: Blendify
Ref D12445
|
|
Addresses T76082.
Since the DirectX backend does not work for AMD gpus
(wglDXRegisterObjectNV() fails to register the shared OpenGL-DirectX
render buffer, displaying a pink screen to the user), the original
solution was to use SteamVR's OpenGL backend, which, as tested
recently, seems to work without any issues on AMD hardware.
However, the SteamVR OpenGL backend (on Windows) was disabled in
fe492d922d6d since it resulted in crashes with NVIDIA gpus (and still
crashes, as tested recently), so SteamVR would always use the
AMD-incompatible DirectX backend (on Windows).
This patch restores use of the SteamVR OpenGL backend for non-NVIDIA
(AMD, etc.) gpus while maintaining the DirectX workaround for NVIDIA
gpus. In this way, issues are still resolved on the NVIDIA side but
AMD users can once again use the SteamVR runtime, which may be their
only viable option of using Blender in VR.
Reviewed By: Julian Eisel
Differential Revision: https://developer.blender.org/D12409
|
|
VS2019 had a compiler update moving it into the
range that was used to detect VS2022. This patch
updates the detection to the current VS2022
preview compiler version.
Reported by Jesse Y on chat.
|
|
With D12436 two File Browser properties were renamed but two references
not changed in space_filebrowser.py
See D12449 for details.
Differential Revision: https://developer.blender.org/D12449
Reviewed by Hans Goudey
|
|
It is causing crashes in rendering, when releasing the GIL in render threads
while the main thread is holding it.
Ref T91046
This reverts commit fc460351170478e712740ae1917a2e24803eba3b.
|
|
Preferences / File Browser section made less confusing.
See D12436 for details and comparisons.
Differential Revision: https://developer.blender.org/D12436
Reviewed by Campbell Barton and Julian Eisel
|
|
Reuse temporary windows when they share the same single area type, not
because they share the same title.
See D12401 for more details.
Differential Revision: https://developer.blender.org/D12401
Reviewed by Campbell Barton
|
|
|
|
This can be useful for better forward compatibility.
|
|
This commit allows connecting color sockets to the group input and
changing the input values in the modifier. Before there was an error
since this was more complicated to support with the previous IDProperty
UI data storage method.
Differential Revision: https://developer.blender.org/D12437
|
|
This prevents copying the arrays when setting new values in the sockets.
No functional changes.
|
|
07c6af413617 was missing include.
|
|
This adds support for two Varjo specific OpenXR vendor extensions:
1) XR_VARJO_QUAD_VIEWS
2) XR_VARJO_FOVEATED_RENDERING
Together these enable human eye resolution rendering on supported
devices (currently mainly Varjo XR-3 and VR-3).
In addition, there's a detection for Varjo OpenXR runtime.
This has been tested on real Varjo XR-3 hardware and Varjo Simulator
and confirmed to function correctly. Foveation works, and the views are
rendered correctly for all the four views.
Reviewed By: Peter Kim, Julian Eisel
Differential Revision: https://developer.blender.org/D12229
|