Age | Commit message (Collapse) | Author |
|
I didn't do this earlier because I was afraid it would make reading of asset
data (and asset data only!) difficult. Mainly because custom properties could
store pointers to other data, that would have to be read too then (e.g. an
object). But turns out, we can easily disable custom pointers to other
data-blocks, so reading stays simple :).
|
|
|
|
Just a beginning of tests coverage, related on the planned upcoming
development.
|
|
|
|
Make unit more explicit.
Ideally would be "embedded" into the field name itself, but this will be
more involved change.
|
|
The caller is still responsible for allocating list of markers,
but the track allocation and initialization can now be reused.
Currently no functional changes, preparing for an upcoming
development.
|
|
Use a dynamic name/description based on the set properties. This makes it more
clear what's going on and avoids confusion, as explained in the report.
|
|
This makes it clear that only the final "r_data" is being changed.
Also rename a variable to be less vague.
|
|
Just a few minor improvements: declare variables where they are
initialized, decrease scope, expand some variable names, and use
LISTBASE_FOREACH.
|
|
Having up to nine levels of indentation make this function hard to
follow. Instead of indenting the rest of the loop for a simple special
case, just continue.
|
|
|
|
|
|
By using floating point filters, the speed improves by a factor of 2 to 10.
This will help speed up some cases of the Exact Boolean modifier.
Changed the interface of mpq2::isect_seg_seg to not return mu, as it was
not needed and not calculating it saved 15% time.
|
|
|
|
The assert was when use segment selection mode.
|
|
Reduce variable scope, and in a few cases, use bool instead of int.
|
|
When lowering the wireframe opacity with sculpt overlays enabled, the
wireframe overlay was creating white artifacts along the edges.
Reviewed By: fclem
Differential Revision: https://developer.blender.org/D9607
|
|
|
|
Some checkboxes had nonessential spacing between rows which made the
popover taller than needed.
|
|
This adds an invert toggle for the outliner object state filters.
There are some cases where we want a filter for invertable states (Selected,
Unselected) and having a single toggle to invert the filter reduces the
number of separate filter types needed. This removes the "Hidden" filter
which can now be replicated with an inverted "Visible" filter.
Differential Revision: https://developer.blender.org/D9598
|
|
In case we do not use names, code adding new insert operations in
collections was broken.
Not a proble in practice so far, since this case was not yet in use, but
will be soon with NLA overrides.
|
|
Since add-ons now unregister on exit
(as of fa566157a5c351775d082b05b180c630665b4afc)
clearing functions in `bpy.app.handlers` caused an error on exit.
Resolve by restoring handlers before exiting.
|
|
|
|
Zoom with an orthographic view wasn't refreshing the preview plane.
|
|
When an projecting onto a plane that is orthogonal to the views Z axis,
project onto a view aligned axis then map it back to the original plane.
see: ED_view3d_win_to_3d_on_plane_with_fallback
Since the depth can't be properly visualized in 3D, display a 2D so
it's possible to to tell the depth from the cursor motion.
|
|
When using surface orientation and nothing is under the mouse-cursor,
pick the axis that's closest to the view's Z axis.
Now by default default, drawing into empty spaces wont use a plane
orthogonal to the view.
|
|
Error in cleanup commit 0d93bd8d639. Currently floating panels
cannot be dragged, so the widget should not be displayed.
|
|
Generating the thumbnail left the view matrices set to values
that couldn't be used for cursor drawing.
Backup/restore the matrices for off-screen drawing.
|
|
Variables to temporarily override values was scattered,
making it harder to follow.
|
|
|
|
This was leftover from Blender internal, follow the naming
already used by the draw manager.
|
|
Some callers were passing in dummy values, this can be accessed from
`RegionView3D.is_persp` can be used to check this.
|
|
|
|
|
|
The Normal Map node was falling back to (0, 0, 0) when it was missing
the required attributes to calculate a new normal.
(0, 0, 0) is not a valid normal and can lead to NaNs when it is
normalized later in the shader. Instead, we now return sd->N,
the unperturbed surface normal.
|
|
The issue was that the same point cache was read by multiple
threads at the same time (the same object was evaluated for
render and for the viewport).
Both threads incremented PTCacheMem->cur which lead to the crash.
The fix is to remove the PTCacheMem->cur and store it on the
stack instead. This way every thread has its own cur.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D9606
|
|
Cover all atomic functions with unit tests.
The tests are quite simple, nothing special so far. The goal is to:
- Make sure implementation exists.
- Implementation behaves the same way on all platforms
(We had issue when MSVC and GCC were behaving differently in the
past).
- Proper bitness is used for implementation and non-fixed-size
function implementation.
The tests can be extended further to make sure, for example, that
CAS operations do not cast arguments to a more narrow type for
comparison. Considering it a possible further improvement, as it is
better be done being focused on that specific task.
There is an annoying ifdef around 64bit implementation, which uses
same internal ifdef as the header does. This check is aimed to be
removed, so is easier to simply accept such duplication for now.
The tests seems somewhat duplicate for signed/unsigned variants and
things like this. The reason for that is to keep test code as simple
as possible: attempting to do something smart/tricky in the test code
often causes the test code to be a subject of being covered with its
own unit tests.
Differential Revision: https://developer.blender.org/D9590
|
|
|
|
Previously the lock-free tests were actually testing guarded allocator
because the main entry point of tests was switching allocator to the
guarded one.
There seems to be no allocations happening between the initialization
sequence and the fixture's SetUp(), so easiest seems to be just to
switch to lockfree implementation in the fixture's SetUp().
The test are passing locally, so the "should work" has high chance
of actually being truth :)
Differential Revision: https://developer.blender.org/D9584
|
|
While it might not cover all possible abuse of API, it does provide
basic checks against most obvious usage mistakes.
|
|
Previously the only way to use lockfree implementation was to start
executable and never switch to guarded allocator.
Surely, it is not possible to switch implementation once any allocation
did happen, but some tests are desired to test lock-free implementation
of the allocator. Those tests did not operate properly because the main
entry point of tests are forcing guarded allocator to help catching
bugs.
This change makes it possible for those tests to ensure they do operate
on lock-free implementation.
There is no functional changes here, preparing boilerplate for an
upcoming work on the allocator tests themselves.
|
|
Don't refresh the list of sockets, so that when the .blend file is restored the
links remain valid. Also display such nodes in red to indicate an error, same
as when the node type info is missing.
|
|
|
|
The seam check was missed in 9296ba867462f7ff3c55bc0c9129af4121243bed
which calculates islands from the BMesh.
|
|
Some DNA headers already did this, most did not. Even though many of them would
be included in C++ files and thus compiled as C++. This would be confusing and
developers may think they have to add `extern "C"` too a whole lot of
(indirect) includes to be able to use a C header in C++.
However, this is a misconception.
`extern "C"` does not cause code to be compiled with C rather than C++! It only
causes the linker to not use C++ function name mangling. See
https://stackoverflow.com/a/1041880.
Because extern DNA headers don't have function declarations, using `extern "C"`
actually should not have any effect. On the other hand, adding it causes no
harm and avoids confusion. So let's just have it consistently in C header
files.
Differential Revision: https://developer.blender.org/D9578
Reviewed by: Bastien Montagne, Sybren Stüvel
|
|
Don't allocate StripElem for movieclip, scene and mask strips. This
struct is not handled in seq_dupli function. This caused field to be
uninitialized in COW datablock.
StripElem is not allocated when adding strip with operator and it is
not needed for these strip types.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D9600
|
|
Move RNA enums and utility functions closer to operator definition.
No functional changes.
|
|
No functional changes.
|
|
Split up the Euler filter function into two more functions. The Euler
filter operator works in two stages (find channels that define the X/Y/Z
Euler rotations, and perform filtering on those channels), and each
stage now has its own function. This makes it clearer which data are
used in which part of the code, and makes future improvements easier.
No functional changes.
|
|
|