This adds support for incremental updates in the sculpt transform
code. Now tools can define if they need the displacement applied
for the original coordinates or incrementally.
This is needed for features like elastic transform or cloth deformation
target in the transform tool.
No functional changes.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D9547
This was reported in the form of the eyedropper of the 'Parent' property
creating a custom property 'parent' if self was picked.
Problem arises when certain checks for setting rna pointer properties
failed (for example: the PROP_ID_SELF_CHECK check) and then a different
code path was entered (which was only meant for IDProperties).
Problem was introduced in rBa7b3047cefcb.
To solve, now first enter the branch for rna-based pointer properties,
then perform the sanity-checks (and if these fail: dont enter the other
unrelated codepath but instead do nothing)
Maniphest Tasks: T83055
Differential Revision: https://developer.blender.org/D9652
dynamic paint modifiers
Looks like prior to the introduction of mantaflow, the former
SmokeModifierData always had a domain initialized (even if its type was
set to None). Since mataflow, the FluidModifierData type needs to be set
to MOD_FLUID_TYPE_DOMAIN (otherwise domain is invalid)
Maniphest Tasks: T82729
Differential Revision: https://developer.blender.org/D9644
Code was actually not applying any override operation over linked data.
Reasonn behind that was that if library file is saved with latest
override applied then this is not needed, since data saved for the
override in the lib file is already up to date.
But this is actually fully breaking in case someone update the lib file
of the lib file, without re-saving the libfile itself.
So now we alwaya apply overrides also on linked data.
Note that this will not fix the case where a resync is needed.
The panel title text intersected any buttons in the header because
the label offset retrieved from the layout code was not scaled by
the block's zoom level. Error in rB0d93bd8d63980.
The transform modifiers are confirmed by releasing any button.
Thus, the operation can be falsely confirmed if the button that launched
the operation is released after the modifier has been activated.
Previously the events that confirmed the modifiers were hardcoded.
An option to fix this would be to add custom confirmation keyitens for
specific modifiers. But this can be a bit confusing and would make the
modal keymap even bigger.
So the solution here is to skip the button that launched the operation
when confirming the modifier.
Orthogonalize the constraint target's matrix before decomposing it into
Euler angles. This removes sheer, and is actually a requirement for
correct decomposition.
It's conceivable that someone has used the incorrect behaviour in a rig.
As the shear caused unpredictable flipping of the constrained object,
this is unlikely.
Reviewed By: angavrilov, sybren
Differential Revision: https://developer.blender.org/D8915
Previously, the alternate row color in the Video Sequence Editor was
just a shaded version of the editor's background color. This makes it
theme-able just like in the file browser and outliner, although the
default color is very slightly different.
Differential Revision: https://developer.blender.org/D9634
If the cursor is not over the mesh, the operator was still using the
last Face Set ID updated by the drawing cursor code when the cursor was
over the mesh.
This now cancels the operator instead of modifying a Face Set that will
look random to the user.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D9545
The original name was chosen because symmetry was a property of
the Paint struct. Now symmetry is a property of meshes, which
also makes the name of the property easier to understand.
Reviewed By: sergey, dbystedt
Differential Revision: https://developer.blender.org/D9618
Since D6133 fluid particle code uses thread local storage to collect
springs created during a time step before adding them to the actual
spring array.
Prior to the switch to TBB there was a single finalize callback which
was called on the main thread, so it could use psys_sph_flush_springs
and insert the new entries into the final buffer. However in D7394 it
was replaced with a reduce callback, which is supposed to be thread
safe and have no side effects. This means that the only thing it can
safely do is copy entries to the other temporary buffer.
In addition, careful checking reveals that the 'classical' solver
doesn't actually add springs, so reduce isn't needed there.
Differential Revision: https://developer.blender.org/D9632
The roll value may not be as expected when a matrix is not orthogonal
or has a negative determinant.
This can lead to confusion as seen in T82930.
Therefore, make it clear that this is a limitation and that a value for
the roll is somewhat indeterminable in these cases.
This fixes T82930
In `calc_curve_deform` a factor is calculated without checking if
the divisior is zero or close to zero. This patch adds the missing
checks and sets the factor to zero if the division shouldn't be
computed.
Reviewed By: mont29
Differential Revision: https://developer.blender.org/D9645
The logic was duplicated.
Should be no functional changes. The modified function is expected
to give same exact results for all inputs.
On the "caching last-used track" topic. The code was using last_marker
to allow faster lookup of marker closest to the frame. With this
change it is still the case since the BKE_tracking_marker_get() does
cache last used marker.
Selecting an object by clicking on its instances only worked,
when the object itself is visible. However, it is possible to hide
the object and still keep the instances visible.
The solution is to give every object the correct `select_id` in the
depsgraph object iterator right before rendering.
Reviewers: fclem, brecht
Differential Revision: https://developer.blender.org/D9640
This change will use the image engine to draw the backdrop of the compositor. With this patch the alpha blending will be done in Linear Scene Reference space and shows pure emissive colors.
See differential for an example image.
**Technical changes**
As only the backdrop drawing is done using the draw manager there are some technical changes.
1. The overlay buffer is partly drawn outside the draw manager. When drawing the backdrop image the overlay buffer needs to be masked to simulate premultiplied alpha under.
2. The backdrop of the node editor is done in region pixel space. A `DRWView` is constructed with this space.
3. UDIM textures uses world position to generate the UV coordinates. This has been implemented more strict by the `IMAGE_DRAW_FLAG_USE_WORLD_POS`. When the flag isn't used the local coordinates are used to generate the UV coordinates what is image space.
4. The draw manager now checks the actual `eSpaceType` of the space data to use different code paths. In the future the movie clip editor will be added.
NOTE: The preview images in nodes are drawn in display space and cannot show pure emissive colors. As preview images are used on more locations it is best to fix this in a separate patch.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D9451
The spikes were caused by non-initialized tangent matrix used during
smoothing process. The reason tangent matrix was not initialized was
because wrong usage of API: n-gons should pass corner of 0 to the
matrix construction function.
Corrected usage of the API and added assert() to help catching such
kind of non-initialized issues easier.
When clicking on an already-selected keyframe, mark it as active if the
click caused the previously-active keyframe to become deselected.
When clicking on a key in the graph editor, it is selected and all other
keys are deselected. If that key was already selected before the click,
it would not become the active keyframe. This is now fixed.
Reviewed by: Severin
Differential Revision: https://developer.blender.org/D9639
Regression introduced by {rB042143440d76}. The deform group lookup was
performed on the wrong object. Before the lookup was performed on
the lattice object. This patch changes this back.
Reviewed By: Bastien Montagne
Differential Revision: https://developer.blender.org/D9638
According to feedback the outliner to properties editor tab switching
was annoying when it always changed tabs on selection, especially for
selecting individual objects. This limits the tab switching behavior to
only when the icons in the outliner are selected.
Adds smooth scrolling with the trackpad for popovers. Also fixes the position of the scroll arrows on high-DPI.
Differential Revision: https://developer.blender.org/D9533
Reviewed by Brecht Van Lommel
Layout block safety sizes were not scaled correctly with interface scale.
Differential Revision: https://developer.blender.org/D9569
Reviewed by Brecht Van Lommel
The existing hash function didn't work well with Set's method of
masking to the lower bits, because many verts have zeros in the
lower bits.
Also, replaced VectorSet with Set for Vert deduping.
Split some of the code of `graph_edit.c` into:
* `graph_view.c`: preview range, view all, view selected etc.
* `graph_slider_ops.c`: the decimate modal operator code.
The latter file will be extended later with more slider-based operators.
Maniphest Tasks: T81785
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D9312
This new discontinuity filter performs actions on the entire Euler
rotation, rather than only on the individual X/Y/Z channels. This makes
it fix a wider range of discontinuities, for example those in T52744.
The filter now runs twice on the selected channels, in this order:
- New: Convert X+Y+Z rotation to matrix, then back to Euler angles.
- Old: Add/remove factors of 360° to minimize jumps.
The messaging is streamlined; it now reports how many channels were
filtered, and only warns (instead of errors) when there was an actual
problem with the selected channels (like selecting three or more
channels, but without X/Y/Z triplet).
A new kernel function `BKE_fcurve_keyframe_move_value_with_handles()` is
introduced, to make it possible to move a keyframe's value and move its
handles at the same time.
Manifest Task: T52744
Reviewed By: looch
Differential Revision: https://developer.blender.org/D9602
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.
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.
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
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.
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.
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.
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
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.
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
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.
This is actually a user interface issue, introduced on 0688309988.
but->tip is checked for NULL in other parts, and rightly so, since here
it crashes Blender.
On a side note I don't know how to reliably reproduce the original bug
whose fix introduced this issue. That got on the way of seeing whether
this is the correct fix, if it happens outside greasepencil operators.
Maybe it is an operator that is missing a tooltip? Impossible to tell
without more information from said commit. That said since this happened
during the end of bcon3 and we are not in bcon4 I'm going ahead with
this NULL check commit.
Patch reviewed by Philipp Oeser and Sergey Sharybin.
Code was rewritten to work on per-sequence basis returning reference to
created strip.
There should be no functional changes.
Selection logic is left as is for now. I could simplify it, but it
belongs to operator, not split logic.
Reviewed By: sergey
Differential Revision: developer.blender.org/D9592
My last cleanup commit for this function missed this case. It likely
happens because the panel's block size doesn't update properly somewhere.
Short of investigating that right now, it makes sense to return early
in this case anyway.
This option joins any stroke with an end near the actual stroke. Now it is not limited to the last stroke, any stroke in the same layer for the actual frame can be joined. The join can join two strokes drawing a third stroke.
If the end and the start of the result stroke are very small, the stroke is changed to be cyclic automatically.
There is a limit distance to join the stroke, if the distance is greater than this value, the strokes are not joined. Actually, a constant, threshold distance is used, but we could expose
as a parameter in the UI in the future.
The tool can be used with freehand drawing or with primitives.
Note: Great part of the patch is just a refactor of the old code to make it accessible and to keep code organized.
Reviewed By: mendio
Maniphest Tasks: T82377
Differential Revision: https://developer.blender.org/D9440
The existing panel drawing function was a bit convoluted with dependent
conditions in different scopes, redundant and unecessary computations,
and un-helpful naming.
This commit separates the function into two parts, the backdrop and the
widgets. It also improves naming and uses const where possible, and in
general cleans up the code.
There are some slight visual changes, mostly with the placement of the
drag icon, which moves a bit downward to be centered with the triangle
icon. The black rectangle displayed while dragging is also removed.
The logic for separator-spacers (used here for right-alignment) didn't take
region scaling into account. Usually that's not an issue because they are
otherwise only used in headers which can't zoom.
The logic for separator-spacers (used here for right-alignment) didn't take
region scaling into account. Usually that's not an issue because they are
otherwise only used in headers which can't zoom.
During some operators like rotate in grease pencil edit mode the
hierarchy lines in the outliner would draw twice as thick. Set the width
before drawing the lines in the outliner.
Differential Revision: https://developer.blender.org/D9589
This is an addendum to previous boolean fix, where the object
transformation was "cleaned". Now the operand one is too.
This fixes the issue shown in the video in T82301 when you move
a column around the XY plane with the top and bottom faces
supposedly coplanar with a cube. The transformation matrix when
you do that has a tiny offset in the z component.
Scaling of forces needs more work. Before making changes to them it would be nice to have a setup, that works physically correct across multiple modifiers (cloth, rigid bodies, fluid).
This will be a to do for 2.92.
Active tile could be NULL when it was on the second tile before
switching back and forth between the Image/UDIM.
In the future we might also check that the active_tile_index is always
valid.
The root cause of this bug is that the function that updates the PBVH
normals is drw_sculpt_generate_calls. As now both the overlays and
mesh can be drawn without using pbvh drawing, the normals were not
updating. This patch forces a normals updates also in the no PBVH
drawing code path of the overlays. This was affecting both shading and
sculpt surface sampling in both flat and smooth shading modes.
Having the sculpt normals being updated by the drawing code is a wrong
design which also causes other issues like:
Brushes that sample the surface and do multiple stroke steps between
redraws will sample invalid normals, creating artifacts during the
stroke clearly visible in some brushes.
Brushes that do not need to sample the surface update the normals on
each redraw. This affects performance a lot as in some cases, updating the
normals takes more time than doing the brush deformation. If flat shading
is being used, this is only necessary to do once after the stroke ends.
Reviewed By: fclem
Differential Revision: https://developer.blender.org/D9535
Pie menu had inconsistent behavior for dragging & releasing the key
compared to clicking on the button.
This was caused by the `onfree` argument being set to true,
preventing the button from running callbacks such as setting
up undo data & auto-keyframe
This argument should only be used when freeing the button,
set this to false as is done for regular menus.
This brush needs to be disabled for dyntopo as it stores its custom data
and deforms from original coordiantes.
Reviewed By: sergey
Maniphest Tasks: T82542
Differential Revision: https://developer.blender.org/D9516
Panels for active uiBlocks always have a type, because the process that
makes them uses the types. Add an assert just to make it clear that the
assumption is purposeful.
Regression introduced by {b17cca6966}. When centralizing the gpu texture
premultiplication setting it was assumed that generated images
(`IMA_TYPE_UV_TEST`) were stored as premultiplied. That assumption was
totally wrong as the alpha association is determined by the existing of
the float/byte buffer.
NOTE: This change will render generated images with pure emissive
colors (show colors when alpha=0.0) what might add more reports. Any
reports could be merged in the next report {T82790}.
Reviewed By: Clément Foucault, Philipp Oeser
Differential Revision: https://developer.blender.org/D9585
After recent changes to the context panel layout (rB187cc5e26d28b1a8),
there has been an error printed when running propery search:
> Error: separator_spacer() not supported in popups.
The layout code thinks it's drawing in a menu because region->visible
isn't properly set for the other tab searches. This patch sets that field
for the temporary searching region, but it also disables searching in the
context breadcrumbs panel, because at best this will just give results
for the names of the active object, etc. This isn't helpful since
those labels are mostly in every tab anyway.
Differential Revision: https://developer.blender.org/D9425
Logic was incorrect, mistake in f3b8792b96.
Updated comment to make intent more clear.
Same as fd78f8699e, but needed conflict resolution as the panel-type
flags where renamed in master.
Edges with 3 or more connected UV's caused UV pack to fail.
Instead of using functions from uvedit_parametrizer.c which are intended
specifically for ABF/LSCM unwrapping, use a simpler method for packing
which stores arrays of BMesh faces.
The clone tool in the image editor can show a second texture on top
of the image. This wasn't ported and now results into alpha and depth
issues. This fix adds the clone tool drawing to the overlay engine.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D9352
Remove redundant call to `ofstream::close()` from `~PSStrokeRenderer`
and `~TextStrokeRenderer`. ofstream will be destructed automatically.
- For `~Depsgraph`, `std::function`'s constructor can throw.
- Passing throwing statements in the lambda will not be detected by
clang-tidy.
Fix these issues by using lambda as function argument.
Reviewed By: sergey, sybren
Differential Revision: https://developer.blender.org/D9497
In 8d1978a8e0 bmain entry is updated when prefetching is started,
but this must be done before seq_prefetch_update_context(). Otherwise
created cache keys will be incorrect.
This happens immediately after prefetch is started. When it's refreshed
problem goes away.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D9581
Some RNA structs, like operators or keymaps, are not allowed to have ID
pointer properties. now this check will ignore those, and report an
error message in the console.
Related to T82597.
Notes: While a bit more involved than rBf39fbb3e6046, this commit
remains fairly localized and non-intrusive.
It relies on some rather obscure and weird behaviors of our RNA code
though, a cleaner solution could be e.g. to add a tye to
`StructOrFunctionRNA`, so that we could properly 'rebuild' (re-cast) the
pointer to either `StructRNA` or `FunctionRNA` when needed in internal
code...
When offsetting strips to the left, to make space when syncing strip
length, move the preceding NLA strips instead of the succeeding strips.
The bug seems to be from a copy/pasting typo.
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D9583
Select only editable keys on selected curves when "Only Show Selected
Curves" is enabled in the Graph Editor's View menu.
This prevents selecting invisible keys with box, circle, and lasso
select in the Graph Editor.
Reviewed By: looch
Differential Revision: https://developer.blender.org/D9580
Crash is related to the definition of the GL_MAX_TEXTURE_SIZE. OpenGL does not clearly
defined `GL_MAX_TEXTURE_SIZE` exactly means. Both on AMD and NVIDIA we have issues with
huge textures that they don't get created even if they are smaller. (See {D9530} for
research).
This patch will try to create the texture in a smaller size when the texture creation
failed.
Final implementation by: Clément Foucault
We should create a solution that doesn't need downscaling. For this specific case ARB_sparse_texture might help to create cleaner code, but you still have to commit the whole image what introduces several draw calls. Other improvement is to optimize the scaling; current implementation isn't optimized for performance.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D9524
This is was caused by incorrectly set preview_render_size in VSE
rendering context. Value was set to SEQ_PROXY_RENDER_SIZE_FULL, but
it should be SEQ_PROXY_RENDER_SIZE_SCENE as scene render size is
being used.
This is same fix as 0d7036b40e, but I did not checked openGL
render pipeline.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D9562
Use either scene render size or fixed preview scale factor.
Previously scene render size was used as baseline value for text size
correction. This is incorrect.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D9563
The icons originally chosen for the collection colors were selected
during development and had a few issues with contrast in the light
theme, and the gray color was not a good choice against the default gray
backgrounds.
The new colors are more readable in both default Blender themes. Gray
was replaced with pink.
Differential Revision: https://developer.blender.org/D9504
Coalescing on macOS overwrites a singular unprocessed mouse event. To
receive all mouse and tablet events coalescing is disabled.
Disabling coalescing for macOS disables coalescing for trackpad
gestures. Repeat trackpad events are unnecessary and found to
negatively impact performance thus are re-coalesced in Window Manager.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D9574
This was introduced by rBdb7d8281c5a2.
The color needs to be premultiplied as there is no blend mode and
the output color is replacing the framebuffer color & alpha.
X axis panel dragging traces back to Blender versions before 2.5,
where panels could be aligned horizontally. But for many years now
panels have been vertically aligned. Considering this, keeping the
X axis dragging around is a bit odd. It makes interaction confusing,
or at least more complicated. It also looks bad, since any part of
the panel outside the region is cropped.
Differential Revision: https://developer.blender.org/D9549
This reverts commit f39fbb3e60.
Code is not valid, `DefRNA.laststruct` does not always point to the
proper struct when defined from Python, need to be done differently.
The original code for viewlayer collection flag syncing across moves
from D9158 didn't consider the case where the collection could no longer
be found in its original view layer (moving a collections betwen scenes).
The fix is to just check if the collection starts in the same scene as
it will be moved to before trying to do the flag syncing. I thought about
this for a while and tried a couple other solutions, but I couldn't come
up with a proper way to support syncing the layer collection flags across
scenes without making too many changes.
Differential Revision: https://developer.blender.org/D9568
Root of the issue is that point caches are added to the object's list
on-demand, which often ends up with them being added only during
depsgraph evaluation, i.e. on COW objects.
This could result in having 'orig' data caches with invalid/unset stack
index at some points (e.g. when reading a file and applying
liboverrides), leading to discarding valid existing disk cache files.
Fact that one of those index is signed, and the other not, does not
help...
While this is very weak, fixing broken PointCache code is out of the
scope of a bug fix, so this patch merely:
* Simplifies and factorizes the code generating the 'extension' part of
caches filenames;
* Ensures `BKE_object_insert_ptcache` is called when needed so that we
always have a valid stack index to generate that filename extension.
This is only a bandaid, but it is simple and should be safe enough for
now.
Related to T82503.
Some RNA structs, like operators or keymaps, are not allowed to have ID
pointer properties. now this check will ignore those, and report an
error message in the console.
Related to T82597.
Remove `return` from for-loop which blocked the recalculation of driven
values when it found the first driver.
Reviewed By: sybren, sergey
Differential Revision: https://developer.blender.org/D9515
Previously the return value of `ufopen` wasn't checked and if it failed,
`NULL` was passed into `fclose()` which resulted in a crash. This patch
avoids this by returning from `BLI_gzopen` when the file cannot be created.
Reviewed By: sebbas, iss
Differential Revision: https://developer.blender.org/D9576
is present
Caused by rB4212b6528afb.
'updateGLSLCurveMapping()' compares cacheIDs and in certain scenarios,
these are the same when they should not.
- whenever we had multiple viewports that are colormanaged with
curvemappings this worked right (cacheIDs were different)
- for example, this also worked right when the ImageEditor displays a
Render Result or a Compositor Viewer
- but it worked wrong when the Image Editor displays any other Image (or
no Image at all)
- it also worked right if there were multiple Image Editors [and one of
them displays a Render Result e.g]
Now why is this so?
For comparison, the curve mapping's pointer/address is used.
- update_glsl_display_processor frees the curve_mapping, see
BKE_curvemapping_free(global_glsl_state.curve_mapping)
- similar, update_glsl_display_processor creates a new curvemapping, see
BKE_curvemapping_copy(view_settings->curve_mapping)
- now for the situation that a viewport with curvemapping and a viewport
without curvemapping is present and you make changes to the curvemapping
the following happens:
-- curve_mapping_settings->cache_id is set once [to the memory address
of curvemapping before change]
-- change happens
-- viewport 1 frees curvemapping
-- viewport 2 duplicates using BKE_curvemapping_copy, but this one gets
the same address like before the change
-- this means we have different data on the same address with the same
cacheID...
Solution: to really make the cache ID unique we can combine the pointer
with its 'changed_timestamp' [which increases on every change].
Reviewers: jbakker
Maniphest Tasks: T82460
Differential Revision: https://developer.blender.org/D9559
The issues was that Blender was trying to refresh the
splash screen region. However, opening the file browser
closed the splash screen and freed the region.
The fix is to simply not refresh the region.
Has been approved in T81817.
First detect the other selected object, then check it can be written to.
Otherwise the target object could be the first one found when
looping over objects which is random from the user perspective.
Move the type check to the operator, which also checks the data isn't
library data which was being ignored.
Move most functions into separate files.
File sequencer.c is reserved for alloc, free and duplicating functions.
There should be no functional changes.
Two problems were fixed. One, the code for dissolving vertices
left a face around if dissolving a vertex would leave less than
three vertices. Instead, the face should be deleted.
Two, with transformations like "rotate 180 degrees", this should
be no problem with exact, but the current transformation matrix
has very small non-zero entries where it shouldn't. Cleaning the
transformation matrix makes it more likely that user expectations
about coplanar faces will be fulfilled.
It should not be possible to set the scene collection's color tag
through rna. Also adds a missing notifier for setting the collection
color tag from python.
After rB452a1c7b3838 there were still a few cases where the old
collection icon was used in the interface. Replace these with the new
filled collection icon.
Differential Revision: https://developer.blender.org/D8660
This patch is the result of the GSoC 2020 "Editing Grease Pencil Strokes
Using Curves" project. It adds a submode to greasepencil edit mode that
allows for the transformation of greasepencil strokes using bezier
curves. More information about the project can be found
here: https://wiki.blender.org/wiki/User:Filedescriptor/GSoC_2020.
The overlap with the `Panel` flags that start with "PNL" was quite
confusing because wasn't clear which enum a flag was from. The
new names are a bit longer, but the clarity is worth it.
Instead to use the ID of the object, now the parameter is an Enum with Selected object or New.
If use selected mode, the first grease pencil object selected is used. If none of the selected objects is a grease pencil object, a new object is created.
Small cleanup changes to the original patch.
Differential Revision: https://developer.blender.org/D9529