Age | Commit message (Collapse) | Author |
|
OSSplinLock is a deprecated API, os_unfair_lock is its successor.
This reduces the number of warnings when building on macOS.
|
|
Picked up while investigating a build error on the functions branch
which seems to use this specific header in a way master doesn't.
The problem:
The MSVC headers define a `_CONCAT` macro, so does BLI_kdtree_imp.h
however at the end `BLI_kdtree_imp.h` undefines the macro making the
MS headers that still rely on it "unhappy".
Who's fault is this:
Ours, C99 Spec says
```
7.1.3 Reserved identifiers
- All identifiers that begin with an underscore and either an uppercase letter or another underscore are always reserved for any use.
...
if the program removes (with #undef) any macro definition of an identifier in the first
group listed above, the behavior is undefined.
```
So we should not have defined it, and we definitely should not
have undefined it.
We have *tons* of these violations, although fixing them would be great
at one point lots of them are in /extern or in the 3rd party deps,
I'd rather deal with them on a case by case basis when it actually
causes issues.
Differential Revision: https://developer.blender.org/D5790
Reviewers: campbellbarton, JacquesLucke
|
|
|
|
|
|
The compiler was warning that it assumed that
crfa - 4 < cfra is always true even though that might not
be the case due to overflow. This patch just removes
the condition that caused the assumption.
|
|
The function now allows custom return types defined
by the callbacks. This can be useful when a user of the
data structure has to implement some custom behavior.
|
|
|
|
|
|
With this the values could have been changed without
updating the hash table.
|
|
|
|
The structure is a set built on top of a vector and not the other
way around.
|
|
This makes it possible to use e.g. `std::unique_ptr` in a map.
|
|
Functions that utilize glyph cache should lock and unlock cache by
calling `blf_glyph_cache_acquire()` and `blf_glyph_cache_release()`.
Function `blf_glyph_cache_acquire()` will create glyph cache, if it doesn't exist.
Locking mutex is global and shared by all fonts.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D5701
|
|
When enabled prefetching(preview panel>view settings), a pernament running job
is created, that will render frames in the background until the cache is full.
If the cache is not filled fast enough, prefetch job suspends itself
at the last moment and will wait until it has chance to "catch up".
Effectively this will decouple rendering to separate thread, so rendering
itself is a bit faster.
Cache recycling behavior will be changed to "free furthest frame to the left
of playhead if possible, otherwise rightmost frame".
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D5386
|
|
|
|
|
|
Broke after recent changes for DNA default initialization.
|
|
This reverts commit ce34a6b0d727bbde6ae373afa8ec6c42bc8980ce.
|
|
paint mask selection
followup to rBr27bbe7cbd9b, might as well make this consistent across
all the color operations [with the exception of 'Dirty Vertex Colors'
which is python]
Reviewers: brecht
Differential Revision: https://developer.blender.org/D5786
|
|
without a valid target
rB95b9680597f5 introduced code that would skip creation of GPUVertBuf
for ParticlePointCache if the keyed physics would not have a valid
target. Missing vertex buffer would lead to assert/crash.
This code is now removed (dont see a reason why this was done? afaict
2.79 also just displayed the particles without physics in this case and
this seems to be working just fine in 2.8 as well)
part of T69741
Reviewers: fclem
Maniphest Tasks: T69741
Differential Revision: https://developer.blender.org/D5781
|
|
|
|
|
|
|
|
When added to quick-favourites, these names are used which
didn't make much sense out of the panel context.
|
|
Support per-viewport collection visibility options.
Note 1: There is no way to show a collection that was not visible before
due to depsgraph. Otherwise we would risk having all the collections in
the depsgraph and I believe this is not the idea.
An alternative would be to have a new depsgraph for viewports that are
not local. Something to keep in mind if we do per-viewport current frame
in the future.
So for now what we do is to only allow collections visibility to be
disabled/hidden in this mode.
Note 2: hide_viewport (the eye icon) doesn't really matter for
depsgraph. So after the merge we can still ignore it to show the
collections locally in a viewport with no problems for the depsgraph.
Reviewers: brecht, sergey
Subscribers: billreynish
Related task: T61327
Differential Revision: https://developer.blender.org/D5611
|
|
Reviewers: brecht
Differential Revision: D4997
|
|
|
|
Correct the code to actually do what the comment says.
This fixes an issue where the curve would flip 180 degrees under certain
conditions.
|
|
|
|
activated crashes Blender
Reviewed By: jbakker
Maniphest Tasks: T69816
Differential Revision: https://developer.blender.org/D5779
|
|
Reviewed By: mano-wii
Maniphest Tasks: T69804
Differential Revision: https://developer.blender.org/D5777
|
|
|
|
The problem was when the material slot had something, but the material was NULL.
|
|
|
|
mask selection
for 'Invert', 'Levels', 'Hue saturation Value' and 'Bright/Contrast',
face mask was respected, but vertex mask wasnt...
Same code as done in 'Set Vertex Colors'.
reported in T69835
Reviewers: brecht
Maniphest Tasks: T69835
Differential Revision: https://developer.blender.org/D5783
|
|
|
|
|
|
|
|
Differential Revision: https://developer.blender.org/D5582
|
|
|
|
|
|
Solves stability issues with possibly doing destructive changes to the
tracking setup. Locking interface is the simplest and most reliable way
to avoid crashes.
It is still possible to run non-destructive changes such as clip view
navigation. More operations can be marked as safe if needed.
Fixes T67012: Software closes when a processing marker is deleted
|
|
There are no functional changes as far as users are concerned,
just allows to mark operator as safe to be run from a locked
interface.
|
|
|
|
|
|
As the total of points was changed before free memory, if the total was lower than before, the remaining points were not released.
|
|
|
|
|
|
|
|
This commit adds some new hashing based data structures to blenlib.
All of them use open addressing with probing currently.
Furthermore, they support small object optimization, but it is not
customizable yet. I'll add support for this when necessary.
The following main data structures are included:
**Set**
A collection of values, where every value must exist at most once.
This is similar to a Python `set`.
**SetVector**
A combination of a Set and a Vector. It supports fast search for
elements and maintains insertion order when there are no deletes.
All elements are stored in a continuous array. So they can be
iterated over using a normal `ArrayRef`.
**Map**
A set of key-value-pairs, where every key must exist at most once.
This is similar to a Python `dict`.
**StringMap**
A special map for the case when the keys are strings. This case is
fairly common and allows for some optimizations. Most importantly,
many unnecessary allocations can be avoided by storing strings in
a single buffer. Furthermore, the interface of this class uses
`StringRef` to avoid unnecessary conversions.
This commit is a continuation of rB369d5e8ad2bb7.
|