The property label on the Timeline for showing only channels
from selected objects was wrong,
indicating it shows only keyframes from selected channels.
This fixes it by using the same label and description as the dope sheet uses.
Pull Request: https://projects.blender.org/blender/blender/pulls/110569
Instead of using pointers for these functions, they should be using
references (in most cases) and let the caller make sure that the
layer actually exists.
There were two separate issues occurring here:
With some other recent changes to curve handles, an early exit was
added when the handles should not display, however, this early exit
was not discarding geometry in the Metal implentation, but leaving
values undefined. Resulting in random geometry flickering on screen.
This may not previously have happened in certain modes if the vertex
buffers were zero-initialised up-front (which only happens with certain
debug flags).
Curve handle geometry generation would render incorrectly when
outputting triangleStrips IF the transparent border was disabled.
Authored by Apple: Michael Parkin-White
Pull Request: https://projects.blender.org/blender/blender/pulls/110719
Adds support for generating curve primtiives avoiding the
use of primtiive restarts. This maixmises geometry performance
when using Metal.
Also ensure that the existing index buffer optimization path is
skipped for indirect draw calls where counts are not known at
submission time.
Authored by Apple: Michael Parkin-White
Pull Request: https://projects.blender.org/blender/blender/pulls/109972
PixelBuffer required addition of buffer re-allocation during mapping
to avoid host updates over-writing previous in-flight data as required
by the GPU. Changes allow multiple copies of existing pixel data to
be in-flight simultaneously.
Authored by Apple: Michael Parkin-White
Pull Request: https://projects.blender.org/blender/blender/pulls/110305
In `Layer::remove_frame` there is a case where the frame is not removed,
but overridden by a null-frame. In this case, the frames map was not
tagged, when it should have been.
Changing the frames map would lead to a crash later in undo.
This was because the `frames_storage` was not written to file corectly.
When the `frames_storage` was tagged dirty, it recreated the
`frames_storage.num` as well as the `keys` and `values` pointers.
The `keys` and `values` pointers were written after the update, but
since the `num` is just an `int` in the embeded struct, it was written
before being updated. This lead to an out-of-sync state and later
to the crash.
The fix makes sure we write the struct *after* updating it.
The issue was an out-of-bounds read access when checking whether
the world volume emission needs to be accumulated.
Solution is to check for this case. Done in the generic place, so
that the shade_volume kernel is more readable and no branching
added there, and there is no impact on scenes without the light
linking.
Assume that the world emissive volume belongs to the default light
linking group, as there is no way to link it explicitly to anything.
Pull Request: https://projects.blender.org/blender/blender/pulls/110733
Use `parallel_for` instead of the C threading API, extract some
constant checks from hot loops, and use `EnumerableThreadSpecific`
for thread-local storage.
Pull Request: https://projects.blender.org/blender/blender/pulls/105940
Text of preview-tile widgets would change color while pressing the mouse
button on them, this wasn't useful and just made the UI feel glitchy.
The widget background already indicates the state well.
Preview-tile widgets are currently only used in the asset view template.
More usages will be introduced in the asset-shelf patch (#104831).
Caused by 5ed14e9269.
That commit accidentally removed the `copy_v2_v2_int(t->mval, mval);`
line which was responsible for initializing the value of `mval`.
This was because the `ob->runtime.geometry_set_eval` was populated
with the new `GreasePencilComponent` but
`GeometrySet::compute_boundbox_without_instances()` did not compute
the bounding box of the grease pencil geometry.
Thus the bounding box was not correctly set and the object not
correctly rendered.
functions imported from creator.cc still had extern the "C"
attribute causing a linker error due it it looking for the
undecorated symbol for these functions.
Whenever `grow_array` in
`blender/source/blender/blenkernel/intern/grease_pencil.cc` was called,
it would not free the original array after relocating the data to the
newly allocated memory. This fixes the memory leak.
functions imported from creator.c were missing the extern "C"
attribute causing a linker error due it it looking for the
decorated symbol for these functions.
PR adds support for the selection of grease pencil layers in
animation editor.
- selection status is stored in `GreasePencilLayerTreeNode`
- Existing `GP_LAYER_TREE_NODE_SELECT` flag is used for selection
- selection of channel updates the active layer in object properties
Part of #110056
Pull Request: https://projects.blender.org/blender/blender/pulls/110133
Adaptation of the operator `ACTION_OT_keyframe_insert` to take into account grease pencil channels.
Grease pencil keyframes can now be inserted in blank mode, or in additive mode (duplicate the current frame in the new keyframe).
Two API functions were added :
* `add_duplicate_drawings` which copies the data of a drawing to creates a duplicate, and
* `insert_duplicate_frame` which creates a duplicate frame of an existing one either by copy or instance.
The additive mode option is also added to the UI.
The Layer method `frame_key_at` previously private was set to public.
Pull Request: https://projects.blender.org/blender/blender/pulls/110649
Replace `BKE_mesh_face_flip_ex()` with `bke::mesh_flip_faces()`.
This gives better performance since it avoids custom data name
lookups for every face index, and processes data in a more cache
friendly way. Also remove the `CustomData_swap` API function
as mentioned in 09b6eac5c4.
Flipping 16 million faces, I observed a 3.25x speedup, from 760 to 230 ms.
Pull Request: https://projects.blender.org/blender/blender/pulls/110702
The C-style API is still in place, but the implementation
is moved to a virtual method.
This is part of unification of viewport and final render
structure.
Should be no functional changes.
Ref #108618
Pull Request: https://projects.blender.org/blender/blender/pulls/110696
Caused by 91b27ab637, which caused the final position
arrays to be returned in more situations (in this case, when the final
result is a non-wrapper mesh). Instead, use the cage mesh, which
is more correct anyway-- it just wasn't always available before.
Face set code modifies visibility of faces, then flushes those changes
to vertex and edge visibility. However, then it did an extra flush back
from vertices to faces and edges, which shouldn't be necessary.