These tests are only used by the delaunay, mesh_intersect,
and mesh_boolean files. At the suggestion of Brecht, moving
them into BLI_math_boolean.hh and math_boolean.cc.
The CPP Shader class does not initialize the interface attribute.
What will crash when deleting the shader.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8740
We need to have transforms from passive objects if they are animated or
driven by parent relations. This is not immediately obvious as the
object transform matrix will still be available, it is just one frame
behind in some cases.
Fixed dependency cycles if there is a constraint between two rigid
bodies. Because bullet keeps track of its simulated bodies, we do not
need to supply objects transforms as bullet should already have them.
I need combine these two fixes because otherwise we will get depsgraph
warnings that nodes are missing that it expects to be there.
Reviewed By: Sergey, Jacques
Differential Revision: http://developer.blender.org/D8732
Issue was with our dear posebones again... when applying overrides we
keep the same address/pointer for the IDs themselves, (which avoids us
the need to remap their usages), but their inner data is often
re-allocated.
Therefore, we need once again to go over armature objects and invalidate
their posebone pointers.
This should also be back-ported to Blender LTS 2.83.
Maniphest Tasks: T80078
Differential Revision: https://developer.blender.org/D8734
A test case that compiles all the GLSL shaders for workbench, gpencil, overlay and some
of eevee. Compilation is still platform dependent, but when run on a test-farm
with different hardware we will be able to detect GLSL compilation
errors early on.
The test will be compiled when `WITH_GTEST` and `WITH_OPENGL_DRAW_TESTS`
are On.
For eevee only the shaders inside eevee_shaders.c are included. EEVEE has some shaders
located inside the submodule. They aren't accessible to the outside and aren't added
to the test case. We should see how we want to add them. For the test cases it is better
to move them to eevee_shaders.c, but for eevee perspective it is better to keep them in
the submodule. Keeping them in the submodule could lead to situations that is harder to test.
as the shader could already have been initialized.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8667
There were some missing UBO bindings, what asserted in debug mode.
This patch fixes this by binding the missing UBO's
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8742
In recent refactoring {a9f2ebb21508} an issue was introduced that the
opengl rasterizer would be disabled when only writing to a stencil
buffer.
This fix adds stencil writing to the write mask and set it. This makes
the write map not evaluate to GPU_WRITE_NONE and the rasterizer will be
enabled in `GLStateManager::set_write_mask`.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8743
The CPP Shader class does not initialize the interface attribute.
What will crash when deleting the shader.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8740
Caused by rB49f59092e7c8: Curves: Implement Handles for selected points
only
Changes from deselecting all were not considered as changes anymore.
Maniphest Tasks: T80182
Differential Revision: https://developer.blender.org/D8744
This is part of T76372.
It adds the `blend_write`, `blend_read_data`, `blend_read_lib`
and `blend_read_expand` which correspond to the various
steps when reading and writing .blend files.
Having these callbacks allows us to decentralize the blenloader
code a lot more. This has the affect that code related to any
specific ID type is less scattered.
Reviewers: mont29
Differential Revision: https://developer.blender.org/D8670
We forgot to update this code as part of D3108. I'd like to include this in 2.90,
it's entirely broken now so can't really get any worse.
Differential Revision: https://developer.blender.org/D8738
More localized variables, avoid ugly 'offset by one' index usage in
favor of explicit `INDEX_UNSET` define, etc.
No behavior change expected from this commit.
Checks to preserve the active spline on duplication
required an active vertex too.
Now having no active vertex doesn't prevent duplicate
from keeping the spline active.
Reviewed by: @mano-wii
Ref D8729
Left walk navigation while the scene collection is active would collapse
the subtree which shouldn't be allowed. This adds another check to
`outliner_item_openclose` to prevent collapsing the scene collection.
Introduced in rBb077de086e14.
Because the subtrees in Data API mode are empty for performance reasons,
it was impossible to move through the tree with walk navigation. This
adds an exception to allow walk navigation to expand subtrees in that
mode.
custom split normals data
Clearing custom split normals would get rid of the CD_CUSTOMLOOPNORMAL
layer - but editing data `lnor_spacearr` would be kept.
Adding a CD_CUSTOMLOOPNORMAL layer (if none exists yet) should be done
in `edbm_average_normals_exec` / `BKE_editmesh_lnorspace_update` /
`BM_lnorspace_update` / `BM_lnorspacearr_store`. The thing is that if
the editing data `lnor_spacearr` would still be valid after `Clear
Custom Split Normals Data`, blender would happily call
`BM_lnorspace_rebuild` instead. Doing that without a CD_CUSTOMLOOPNORMAL
layer is asking for trouble.
Now clear lnor_spacearr on `Clear Custom Split Normals Data` as well.
Thx @mont29 for feedback here.
Maniphest Tasks: T80159
Differential Revision: https://developer.blender.org/D8730
Currently the panel handler loops through every block and every button
for every single panel. This commit moves that check to happen a single
time at the beginning.
We need to only collapse or expand the first panel under the cursor
rather than all of them. Note that whether the parent panel or
the subpanel is first depends on the order of the uiBlocks in the
region's list.
The code for handling panel events was much more complicated than it
needed to be. This commit removes some unecessary function calls and
variables, reduces indentation levels by returning early, and does
some other general cleanup.
Somehow the panel category drawing functions ended up in the middle
of the region event handling code. This commit moves them to their
own section next to the rest of the drawing code.
If a different object was active, clicking on a linked armature's pose
in the Outliner would enter Pose Mode for it.
This would actually cause a failed assert, but in release builds the
armature would just enter pose mode.
Steps to reproduce were:
* Link in armature object
* Activate a different object
* In the Outliner, un-collapse the armature object
* Activate Pose Mode by clicking on its pose there
MSBuild on windows currently spews a warning about
buildinfo.h_fake not being generated.
For build info we use a non existing file to trigger a
custom_command on every build, which has worked well for
years now, however in recent versions of MSBuild it has
started issuing warnings about files that should be
generated but are not.
CMake is actually aware of this being a problem and states
in the documentation that "If the output of the custom command
is not actually created as a file on disk it should be marked
with the SYMBOLIC source file property."
This change fixes the build warning by properly marking the
buildinfo.h_fake as symbolic resolving the warning.
Need to make sure node factories are initialized prior to the dependency
graph allocation.
The regression was initially introduced in 5b021dff41
Thanks Brecht for testing!
It is now possible to build against a shared embree library.
Before it was only possible to build against static Embree libraries.
Reviewed By: Brecht
Differential Revision: http://developer.blender.org/D8702
MSVC already builds with the /std:c++17 flag but for
'reasons' [1] MSVC still gives the wrong value for the
__cplusplus define.
This change sets an additional cxx flag on supported
compilers to allow the compiler properly identify
C++17 support.
This resolves 2 warnings coming out of bullet about
the register keyword being deprecated.
[1] https://devblogs.microsoft.com/cppblog/msvc-now-correctly-reports-__cplusplus/
OSL requires RTTI to be off, this is done with the /GR- flag for
MSVC, however /GR is in the default CXX flags leading to warning
D9025 : overriding '/GR' with '/GR-'
which cannot be suppressed.
/GR is on by default and this flag is not required, so removing
it from the default CXX flags makes it possible later use /GR-
without generating warnings.
The changes in rB70151e41dc02 broke subtree expansion in the Data API
display mode because the closed subtrees are empty lists. Move the empty
subtree check from `outliner_item_openclose` to the walk navigation
code to prevent the issue.
`IDTypeForeachCacheFunctionCallback` lists the `flags` parameter
as `uint`, having these functions use `eIDTypeInfoCacheCallbackFlags`
results in the following warning when building with MSVC:
warning C4028: formal parameter 4 different from declaration
This change resolves this warning by changing the parameter to
the appropriate type.
The outliner already uses the alternating row theme color as an
overlay for every other row. This uses the same color for the file
browser, instead of a hardcoded shading.
The file browser background color is slightly tweaked to match the
outliner, and the Blender Light theme is updated to use a lighter
background color like the outliner.
Reviewed by: Hans Goudey, Julian Eisel
Differential Revision: https://developer.blender.org/D8717
This adds a new `--debug-exit-on-error` flag. When it is set, Blender
will abort with a non-zero exit code when there are internal errors.
Currently, "internal errors" includes memory leaks detected by
guardedalloc and error/fatal log entries in clog.
The new flag is passed to Blender in various places where automated
tests are run. Furthermore, the `--debug-memory` flag is used in tests,
because that makes the verbose output more useful, when dealing
with memory leaks.
Reviewers: brecht, sergey
Differential Revision: https://developer.blender.org/D8665
when you call the BLI_array_free macro with a const pointer you get a
warning when the macro calls `MEM_freeN` (warning C4090: 'function':
different 'const' qualifiers)
This was warning originating from
`smart_uv_project_calculate_project_normals` in `uvedit_unwrap_ops.c`
Normally we resolve these with a non const cast at the callsite
but given BLI_array_free is a macro not a function this is not
an option here and it has to be resolved in the macro.
Since the switch to TBB, the threads value specificies the maximum number of
CPU cores used while rendering, it is not longer possible to use more threads
than cores. Change the tooltip to make this more clear.
The `ctrl` key was mapped to recursive bone selectable and visibility
toggling. This changes the key to `shift` to be consistent with objects
and collections. Also adds an explanation to the tooltip.
Part of T77408
Differential Revision: https://developer.blender.org/D8650
Previously the left and right arrow keys would close and open the active
tree element, but a subsequent key press would not select up or
down the tree as is common in tree-based interfaces.
Walking left and right now does a selection action after opening or closing
the active tree item. For example, a right key press on a closed element
will open it's subtree, and an additional right key press will select
the first child element.
A left key press anywhere in a subtree will first close the active
element if it's subtree is expanded. Walking left again will select the
parent element.
Part of T77408
Differential Revision: https://developer.blender.org/D8650
The main CMakeLists.txt specifies C++17, quadriflow tries to add C++14
flags leading to the following warnings when building with MSVC
Command line warning D9025 : overriding '/std:c++17' with '/std:c++14`
This change removes the C++14 flags, and fixes a build error caused
by the removal of `std::unary_function` in C++17 in the .obj loader
(which isn't used by blender)
Reviewed By: zeddb
Differential Revision: https://developer.blender.org/D8720
For bullet we compile at /W0 for MSVC but we did not
remove the standard /W3 flag. Leading to the following
warning:
Command line warning D9025 : overriding '/W3' with '/W0'
This change removes the W3 flag for bullet to get rid
of the warning.
When Blender is started in fullscreen mode from the command line,
or if the fullscreen state is saved in the startup file, all temporary windows
will also open in fullscreen mode. When closing the fullscreen File Browser,
Blender would either crash or parent window becomes black.
This does not happen if the Blender switches to full screen manually.
`NSWindowCollectionBehaviorFullScreenPrimary` should be set for windows that
can enter full-screen mode. Otherwise macOS will turn the wrong window into
full-screen.
Similar fix: rB4b39de677d20
Differential Revision: https://developer.blender.org/D8708
Reviewed by: Julian Eisel
This refactors Box Mask and Lasso mask making both functions share the
same code. After this change it should be easier to add new
functionality, new gesture tools or implement new gesture modes.
No functional changes.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8707
Use BKE_mesh_wrapper API access to access mesh coordinates
for modifier evaluation.
Call BKE_mesh_wrapper_ensure_mdata when binding
since it's a one off operation.
Regression from deaff945d0.
Reviewed by: @brecht
Ref D8709
This is a precursor to a big speed optimization in the "finding clusters"
code. Right now there is no speedup, maybe even a bit of a slowdown,
but following commits should lead to nice speed increases.
This was an oversight in rB83e3d25bcae3.
Basically we still have the "hair" and "point_cloud" entries for the
context. However they were ifdef'ed.
Note this would mostly happen in 2.90 since we always build without hair
and particles there.
Differential Revision: https://developer.blender.org/D8712
- Cycling between part of the boundary & the entire UV boundary.
- Include pole vertices in the selection.
Edge loop selection was rewritten to use BMesh connectivity data.
Further changes to interface_handlers.c to avoid a block of variable
declarations at the beginning of functions. Also use const in some
situations. I only made changes where the variable's intended scope
was obvious.
- Reduce variables scope
- Use some const prefixes
- Initialize variables at declaration
- Use comparison to boolean false instead of 0
Differential Revision: https://developer.blender.org/D8678
This fix a GL_INVALID_VALUE error on startup due to 0.0f max line width.
Also moves the max anisotropy filter to the sampler creation.
This reduces code fragmentation.
Grease pencil modifiers already had defined outliner icons, but had
never been included in the tree. This adds the modifiers and the shader
effects to the tree.
Part of T68498
The previous fix loaded the pixels so existing tiles were not overwritten.
However the Cycles render buffer is expected to be scaled by the number of
sample, which was not taken into account.
This is not ideal in that previews could have a mismatched number of samples
between multiple objects, though the result will be correct. The better solution
would be to bake all objects together per tile, rather than one after the other.
But that is a bigger change than we can do in 2.90.
Differential Revision: https://developer.blender.org/D8704
This prevents UV layer mix up in
MeshBatchCache.cd_used/cd_needed/cd_used_over_time which depends on the
extraction method.
One object's mesh can be accessed with MR_EXTRACT_MESH, another object
that uses the same mesh can use MR_EXTRACT_BMESH based on
(Object.mode & OB_MODE_EDIT), this causes a problem as the edit-mesh
and the mesh aren't always in sync, the custom data layers wont
necessarily match up, causing T77359.
Reviewed by @jbakker, @brecht
Ref D8645
This should not cause any problem since the depth test is required
in order to draw to the depth buffer and this is not altered by
this change.
To be on the safe side, we still restor the mask after altering it.
This workaround addresses T79533 and T79038 for Blender 2.90. The
solution isn't clear and needs more research and work. In order to
continue with blender 2.90 release it was proposed to add this work
around.
It has been tested with the test files provided in the reports.
Reviewed By: Dalai Felinto, Clément Foucault
Differential Revision: https://developer.blender.org/D8695
This workaround addresses T79533 and T79038 for Blender 2.90. The
solution isn't clear and needs more research and work. In order to
continue with blender 2.90 release it was proposed to add this work
around.
It has been tested with the test files provided in the reports.
Reviewed By: Dalai Felinto, Clément Foucault
Differential Revision: https://developer.blender.org/D8695
Use invert_m4_m4_safe_ortho when joining objects so zero scaled axis
doesn't cause all points to be scaled to zero.
Instead geometry is left un-scaled on degenerate axes.
Report a warning in this case since users may want to adjust the
active objects scale.
Unlike invert_m4_m4_safe, this calculates zeroed axes.
Useful when we need to use the inverse of an objects matrix,
keeping the valid axis, only filling in the zeroed ones.
This implements Snake Hook as a deform type for the cloth brush. This
brush changes the strength of the deformation constraints per brush step
to avoid affecting the results of the simulation as much as possible. It
allows to grab the cloth without producing any artifacts in the surface
and create more natural looking folds than any of the other deformation
modes.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8621
In 2.83 and previous versions there was a bug that was causing boundary
vertices to be detected incorrectly that was preventing the smooth brush
to work on boundaries if there was a pole on them.
In 2.90 the boundary vertex detection was fixed, but it was still using a
simplified version of the algorithm without any boundary smoothing. This
patch implements a similar smoothing algorithm to what I think it was
the intention of 2.83 and previous versions, but working correctly.
Reviewed By: sergey
Maniphest Tasks: T80008
Differential Revision: https://developer.blender.org/D8680
This is quite embarassing... it was returning the base instance instead of
the correct vao. No wonder that it was causing crash and at most drawing
issues.
This skips the subdivision operation if the mesh has no loops, avoiding
the crash.
Reviewed By: sergey
Maniphest Tasks: T80039
Differential Revision: https://developer.blender.org/D8696
The return value of scene_intersect must be checked, the isect struct members
can't be assumed to be initialized if that returns false.
Differential Revision: https://developer.blender.org/D8692
The problem occurs when a deforming modifier is added to the object
after the MeshSequenceCache modifier. We should only consider the cached
velocities if the MeshSequenceCache modifier is the last one on the
object and we also need to check for the correct vertex count before
adding the motion vertex attribute.
Ensure that time source always is in the dependency graph, allowing to
tag the graph for time update prior it was fully built.
Collaboration of Philipp Oeser, Jacques Lucke and myself.
Thanks everyone :)
`TH_UV_OTHERS` is a theme option that isn't hooked to anything since
blender 2.80. This patch will remove the option and related code.
Reviewed By: Campbell Barton
Differential Revision: https://developer.blender.org/D8669
The code uses OpenGL functionality, so is to be linked against
OpenGL libraries.
This makes it easier to integrate with cycles using CMake.
Differential Revision: https://developer.blender.org/D8371
This was caused by motion blur camera movement tagging the view as
invalid and thus resetting the temporal sampling.
Critical fix for 2.90. Need second look, but quite confident. This function
is only called once when Motion blur is off.
Reviewed by: jbakker
Differential Revision: https://developer.blender.org/D8676
This operator is dependent on mouse position (if the Use Cursor Position
option is used). The Channel property is irrelevant/unused in this case.
So it is not optimal displaying this property when calling this from the
menu (or even using the shortcut with default settings).
Now use a custom UI in the Adjust Last Operation panel in this case.
The properties are now drawn in relation to another then (Channel
underneath Use Cursor Position) next to some other minor layout
improvements.
Thx @HooglyBoogly for feedback (also providing UI code)
Maniphest Tasks: T79872
Differential Revision: https://developer.blender.org/D8625
This replace `GPU_clear()` by `GPU_clear_color()` and `GPU_clear_depth()`.
Since we always set the clear value before clearing, it is unecessary
to track the clear color state.
Moreover, it makes it clearer what we clear the framebuffer to.
When the OSL_ROOT variable is set this is ignored
by findpackage on cmake < 3.12. CMake 3.12 and up
also ignore it and warn about it. This change
tells cmake it is OK to use the variable and
stop warning
This changes the state of occlusion queries quite a bit. Now scissors is
explicitely disabled and we enabled color write.
I still don't understand why we now need this. This patch is just trial and
error on an affected setup. Note that on the same computer, renderdoc
was not able to capture the regression (the regression did not manifest
during capture).
Regression likely introduced by rB5f414234ddea
Mistake in b077de086e. I did the same fix for a few operators there,
but missed the object "Join" one.
The joining operator changes the layer content. So it must send a
notifier for that.
Before b077de086e that didn't cause a noticeable issue, because the
Outliner happened to listen to other notifiers (active/selection
changes) the operator sent and fully rebuilt its tree in response. Now
missing these notifiers can be more problematic, since we try to avoid
more rebuilds.
Added comments to the notifier types to avoid at least this pitfall.
Since stone age of lib_query, the code would iterate over the current
list of active sequences (from a meta strip e.g.), and not over the
whole list of those.
This is a critical issue as it means in some cases (editing a meta strip
typically), some ID pointers would be missed/ignored by this foreach
looper, which is now at the center of most of our ID management code.
This caused a bug here at the studio, leading to loss of all sound IDs
used by sound strips when editing and undoing inside a meta strip, since
ID refcounting would not happen properly on strips using sounds outside
the meta-strip context during file reading of the undo steps.
To be backported to 2.83.
Differential Revision: https://developer.blender.org/D8671
This matches what was done in a previous commit for the tool.
It makes it easier to associate a tooltip with each choice.
For this branch, I have the default solver be the Exact one;
when we merge to master, we will have to decide the best default.
Make format caught a coouple other files, sorr for not doing those
earlier.
This is in preparation of vulkan backend. We move all opengl
functionnalities behind an abstract class.
This also cleansup the "dynamic" ubo create and rename it to
`GPU_uniformbuf_from_list()`
Contains, no functional change.
Part of T68990 Vulkan support.
This follows the GPU module naming of other buffers.
We pass name to distinguish each GPUUniformBuf in debug mode.
Also remove DRW_uniform_buffer interface.
Remove `exec()` and `eval()` calls from `WM_OT_properties_edit` where
possible. This not only results in simpler, cleaner code, but also
removes the necessity for `repr(value)` to evaluate to a Python
expression that in turn evaluates to `value` again.
No functional changes.
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D8658
Split the depsgraph allocation into a separate function
`BKE_scene_ensure_depsgraph()`. Parameters are only passed to those
functions that actually need them. This removes the the "if that boolean
is `false` this pointer is allowed to be `NULL`" logic and more cleanly
decouples code.
No functional changes.
Reduce nesting by flipping conditions and returning early. It's now much
clearer that it's actually a linear function (rather than a nested one).
No functional changes.
For the sanity checks to work we don't actually need to check other
scenes. So this function can be simplified so that it does not require
a `Main *`.
Mistake in 5cc08510e0.
- Use const in some places where applicable
- Use consistent variable names in some places
- Use "r_" prefix for return arguments
- Declare variables in smaller scope where they are used
We can avoid the rather expensive outliner tree rebuilds and only redraw
if nothing but the selection or active item changes. This should give a
bit of speedup for heavy scenes.
For this to work I had to correct a few notifiers, some were only
sending selection/active change notifiers that actually did things like
adding objects. I also added a more precise notifier type for when the
active collection changes. At the notifier subtype/action level we're
not even close to running out of bits, so this should be fine.
Also had to correct a wrong notifier check (was using `&` rather than
`==`).
Code dealing with object copy of master collection was bugy in case one
of the new object copy would get a name lesser than the original object,
leading to new copy being inserted before original one in lists.
Maniphest Tasks: T79931
Differential Revision: https://developer.blender.org/D8656
Allow adding keys outside of the NLA strip, when Sync Length is
activated. Before this, an animator would have to exit tweak mode,
adjust the strip length, then enter tweak mode again.
Now the animator can freely insert and modify keys outside of the strip
bounds. They will never have to touch the strip bounds directly.
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D7533
This moves the allocation for filter to separate functions, removes all
repeated calls to RNA_enum_get an fixes some other code quality issues.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8639
This updates the view navigation origin after modifying the pivot
position.
Reviewed By: sergey
Maniphest Tasks: T79924
Differential Revision: https://developer.blender.org/D8632
Cloth deform brushes (both in cloth brush or other tools with cloth
simulation targets) should not have their spacing as a value relative
the brush radius to avoid affecting the simulation speed when changing
the brush radius.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8620
This adds the orientation modes to the Cloth Filter.
Similar to the mesh filter, they set the orientation of the axis when
limiting the forces.
When using the gravity mesh filter, the orientation also sets the gravity
direction. In world orientation, cloth will always fall towards the
ground plane. In view mode, cloth will always fall down relative to the
view.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8618
Change the way Sync Length works so that it keeps keyframes at the same
key as before the sync. Now when the user exits tweak mode, the overall
NLA result is unchanged.
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D7602
Popovers which are aligned with properties should turn themself
(and the panel they open) inactive when the corresponding property
toggle is turned off. A notable exception is the snap settings
popover, as snapping can still be used when the toggle is off.
Differential Revision: https://developer.blender.org/D8584
This reverts {rB1693a5efe91999b60b3dc0bdff727473b3bd00bb}
and implements an alternative solution.
The old patch had the problem that the depsgraph would always
evaluate at the current frame of the original scene (even when
`DEG_evaluate_on_framechange` was used). Now it is possible
to evaluate the depsgraph at a specific frame without having to
change the original scene.
Reviewers: sergey, sybren
Differential Revision: https://developer.blender.org/D8616
Add `-Wno-maybe-uninitialized` option to `CMAKE_CXX_FLAGS_RELEASE` and
`CMAKE_CXX_FLAGS_RELWITHDEBINFO` variables on GCC/Linux.
In Release builds GCC's `-Wmaybe-uninitialized` warning is unreliable,
and thus causes noise that can drown out other warnings. These warnings
are now silenced in release mode builds.a
Debug builds seem fine, so flags for debug builds are not touched by
this commit.
No functional changes.
Reviewed By: Sergey
Differential Revision: https://developer.blender.org/D8615
This reverts commit 52f40bcff2.
Apologies for the noise. I caught a problem with this that I hadn't before. I will
commit later after thorough testing.
This will re-link all usages of a library override data-block
(including all of its override dependencies) to its reference linked
IDs, and delete those liboverrides.
As usual, it is available in the ID sub-menu of the outliner context
right-click menu.
Part of T76555.
RNA update function would only update objects from 'main' instantiated
collection, not those from sub-collections.
This should be comitted to 2.90 (and backported to 2.83 too).
Maniphest Tasks: T79935
Differential Revision: https://developer.blender.org/D8654
RNA update function would only update objects from 'main' instantiated
collection, not those from sub-collections.
This should be comitted to 2.90 (and backported to 2.83 too).
Maniphest Tasks: T79935
Differential Revision: https://developer.blender.org/D8654
Continuing the work of eb9055a572, remove remaining unecessary
variables and arguments that were related tabbing and horizontal
alignment of panels. For example, "vertical" was always true, and
removing that exposed other unused variables.
Horizontal panel alignment hasn't been used for years, and we have no
plans to use it in the future. It adds a fair amount of complexity to
the panel code which makes adding features take longer.
This code removes the X closing flag, and all of the logic / variables
unused without it.
This commit includes a file subversion bump.
Differential Revision: https://developer.blender.org/D8601
Using C++ exceptions in Blender is difficult, due to the large
number of C functions in the call stack. However, C++ data
structures in blenlib should at least try to be exception safe,
so that they can be used if someone wants to use exceptions
in some isolated area.
This patch improves the exception safety of the Vector, Array
and Stack data structure. This is mainly achieved by reordering
some lines and doing some explicit exception handling.
I don't expect performance of common operations to be affected
by this change.
The three containers are supposed to provide at least the
basic exception guarantee for most methods (except for e.g.
`*_unchecked` methods). So, resources should not leak when
the contained type throws an exception.
I also added new unit tests that test the exception handling
in various cases.
Available from the usual ID submenu in the Outliner context menu.
The goal of this operator is to re-create the override from the linked
data, while preserving existing defined overrides.
This allows to update local opverrides when relations between datablocks
are changed in source library linked data.
Part of T76555.
This splits the volume related data (properties for rendering and attributes) of the Mesh node
into a new `Volume` node type.
This `Volume` node derives from the `Mesh` class since we generate a mesh for the bounds of the
volume, as such we can safely work on `Volumes` as if they were `Meshes`, e.g. for BVH creation.
However such code should still check for the geometry type of the object to be `MESH` or `VOLUME`
which may be bug prone if this is forgotten.
This is part of T79131.
Reviewed By: brecht
Maniphest Tasks: T79131
Differential Revision: https://developer.blender.org/D8538
Now by default the selection mode is All keyframes types.
Also removed the icon for All option and renamed from `All Types`to `All`.
UI review by @pablovazquez
Users may input an invalid scene/view-layer combination via Python. We
can easily detect that and fail gracefully.
Besides checking input parameters in RNA, also assert the
scene/view-layer combination is valid in lower level Depsgraph lookup
function (called by statistics query).
This RNA/BPY function was removed in c08d847488. For understandable
reasons really-- getting scene statistics from a string displayed in the
status bar is not exactly the best design. But we have committed to not
changing the RNA API too much for the 2.90 release, so we would like to
keep this functionality.
Differential Revision: https://developer.blender.org/D8604
Reviewd by: Julian Eisel
This RNA/BPY function was removed in c08d847488. For understandable
reasons really-- getting scene statistics from a string displayed in the
status bar is not exactly the best design. But we have committed to not
changing the RNA API too much for the 2.90 release, so we would like to
keep this functionality.
Differential Revision: https://developer.blender.org/D8604
Reviewd by: Julian Eisel
During alpha the user preferences > experimental featuers are available
to prevent merge issues and allow developers to seek feedback.
This needs to be manually turned off when we branch for beta, otherwise
the RNA of the incomplete features will be exposed.
I only skipped a few loops in the monstrous ui_handle_menu_event
function. Also, I only changed variable names where necessary to
prevent redeclarations.
Differential Revision: https://developer.blender.org/D8586
This make use of the GLStateStack functions for:
- `GPU_blend()`
- `GPU_blend_set_func()`
- `GPU_blend_set_func_separate()`
The goal is to unify them using an explicit state setting.
This will remove the need to use obscure blend functions
Now error printing only display the line related to the error.
We also put char marker if present.
Example:
```
-- Shader Compilation Errors : MAMaterial --
10414 | node_fresnel(, facingnormal, viewposition, tmp34);
| ^
| error: syntax error, unexpected ',', expecting ')'
----------------------------------
```
This mainly removes the bmain argument, which can be
retrieved from the graph itself.
Also, I removed some outdated/unnecessary comments.
Reviewers: sergey, sybren
Differential Revision: https://developer.blender.org/D8614
This adds a new brush property called "Deformation Target" which
controls how the brush deformations is going to affect the mesh data. By
default is set to Geometry, which makes the brushes displace the
vertices. When set to Cloth Simulation, the deformation of the brush is
applied to the cloth solver constraints, so the simulation is
responsible to apply the final deformation. This allows to add cloth
simulation effects to other sculpt tools with minor modifications to their
code.
This patch enables Cloth Simulation deformation target for Pose and
Boundary brushes, which are tools that are already designed to work in
low poly counts and produce large deformations. This allows creating the
most common cloth effects, like bending and compressing folds, without
relying on collisions.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8578
Same concept as the Multires Displacement Eraser Brush but implemented
as a mesh Filter. This allows to delete the displacement of an entire
area uniformly.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8608
This enables the invert mode in the smooth brush as Enhance Details.
The operation is similar to the Sharpen Filter intensify details parameter,
which consist in applying the laplacian smooth displacement in the opposite
direction calculated using the original coordinates.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8509
The evaluated mesh is now only recomputed when the required data layers
are missing. Previously the evaluated mesh was re-evaluated incorrectly,
which caused the stippled result and the failing assert.
Since now only the evaluated mesh is used, and never a temporary mesh,
there is also no more need to keep track of whether the mesh needs
freeing or not.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8574
Issue introduced on fe045b2b77.
Since the stereoscopy compositing (anaglyph, ...) is only done for
viewports the VSE preview and compositor need to use viewports.
Reviewed by: dfelinto
Differential Revision: https://developer.blender.org/D8472
Issue introduced on fe045b2b77.
Since the stereoscopy compositing (anaglyph, ...) is only done for
viewports the VSE preview and compositor need to use viewports.
Reviewed by: dfelinto
Differential Revision: https://developer.blender.org/D8472
Previously, the XYZ deform axis of the Mesh Filter were limited to
object space (which is the default for sculpt mode). Now it is possible
to limit the XYZ displacement in Local, Global or View space.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8582
For 2.90 release this should not be exposed in the RNA API.
In master this needs to be ON by default, that's all.
Differential Revision: https://developer.blender.org/D8589
The Pass struct is now a Node and the passes are moved from the Film
class to the Scene class.
The Pass Node only has `type` and `name` as sockets as those seem to be
the only properties settable by exporters (other properties are implicit
and depend on the pass type).
This is part of T79131.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8591
Final releases (including beta) should strictly show features that are
finalized to prevent loss of data, old API clanging around, and the
overall quality of the product (Blender) presented.
Note that rendering should never be affected by user preferences, so
this is only changing things in the UI level.
Development note: This is reset experimental UI on file load.
Also note: to hide RNA (needed for hair and particles) will be done as a
separate patch.
Differential Revision: https://developer.blender.org/D8606
After drawing, the batch could be reset and draw again using other
parameters.
Avoid having to track references by setting the batch pointer to NULL after
drawing.
This uses the same concept of the Mesh Filter but for applying the cloth
filter forces, so now it can be limited to a specific axis.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8567
This adds an option to the Multires modifier to sculpt directly on the
base mesh while previewing the displacement of a higher subdivisions
level. What this does it considering Multires as a regular modifier
without exposing the grid displacement to sculpt mode.
This allows to see the propagation happening in real time, which enables
to use complex tools like Cloth or Pose in much higher resolutions and
without surface noise and artifacts.
Reviewed By: sergey, Severin
Differential Revision: https://developer.blender.org/D8555
Functions `mesh_create_eval_final_view()` and
`mesh_create_eval_final_render()` were doing the exact same thing,
except for a hack introduced in d3eb9dddd6 (2012-10-08, Better fix for
T32846: dupligroup messes up particle instancing on rendering) that
appears to be no longer necessary. Besides that, these functions had
confusing names. Their functionality changed over time, and whether to
do for-render or for-viewport evaluation is now actually determined by
the depsgraph evaluation mode. This means that the `..._render` function
could evaluate a mesh with viewport settings, and vice versa.
The functions are now merged into `mesh_create_eval_final()`, and the
hack has been removed. The `OB_NO_PSYS_UPDATE` flag has been removed
entirely (instead of keeping it around as deprecated flag), because it
was always only temporarily set on objects during mesh evaluation and
thus not saved to the blend file.
No expected functional changes as far as users are concerned.
One should be able to edit overridable IDProps values, but never their
settings/definitions.
Note that being able to add new IDProps to overrides is still a TODO.
Reported by Josephbburg (@Josephbburg) over blenderchat, thanks.
Even the Cloth Brush grab works like a regular grab brush, it makes
sense to support spacing just in this brush in order to prevent creating
more brush steps that update the simulation. This way, it is possible to
create grab brushes that update the simulation constantly while grabbing
(using the dots stroke mode) or brushes that only update the simulation
when the cursor moves (using spacing).
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8568
This code was left here after the refactor, it was doing nothing and it
was causing an assert.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8579
The Face Set visibility operator was using the last active Face Set
updated by the paint cursor, so when the paint cursor is not used (when
using a filter or a transform tool), the active Face Set was not updating
and it was hidding the wrong Face Set based on the last cursor position
with a brush tool active. Now the Face Set Visitility operator has an
invoke callback wich forces a active vertex and face set update
regardless of the active tool, so it should always work correctly.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8580
This uses a single row for the three axis instead of a row per axis.
Reviewed By: sergey, Severin
Differential Revision: https://developer.blender.org/D8581
This was a TODO in the code. Previously the Face Set datalayer was
deleted and recreated with a constant ID of 0. Now the datalayer is
preserved and set to the SculptSession after slicing the mask and a new
ID is calculated for the new faces that the slicing operation produced,
so they can be easily isolated for further tweaking.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8583
This will be used for new features like supporting cloth deformation in
other brushes and tools outside of the cloth brush code.
No functional changes.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8602
This moves `Session::get_requested_device_features`,
`Session::load_kernels`, and `Session::update_scene` out of `Session`
and into `Scene`, as mentioned in D8544.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8590
Some constraint-specific operators, like set/clear inverse matrix of
childof constraint, are also valid on original, linked/overridden
constraints.
Similar change to what was done to modifiers poll function a few days
ago.
Reported by Josephbburg (@Josephbburg) over IRC, thanks.
The description is self-explanatory: enable SSE optimizations in the
FFmpeg library. They were disabled from the very beginning of the
dependency builder, possibly due to portability concerns.
FFmpeg does perform runtime check for available CPU microarchitectures,
so the codecs will still run on older hardware, but they will run way
faster on newer hardware.
For example, re-encoding 3405 2560x1376 frames on Xeon E5-2699 V4 CPU
went down from 313sec to 210.
Differential Revision: https://developer.blender.org/D8594
Changing line-width shouldn't scale cursor motion. Related to T79787.
Use dpi_fac for scaling curve error threshold & number button drag
threshold calculation.
Use 'dpi_fac' instead of 'pixelsize' to scale input sensitivity
based on the interface scale.
Also use dpi_fac for view zoom operator.
Thanks to @ISS for investigating.
Multithreaded implementation can provide significant performance gain
on CPU's that can handle more parallel tasks.
On my 8 core system I got about 3.5x faster processing speed.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8585
Define `RNA_def_property_ui_range` for head and tail transform properties.
Step of 10 should match original behavior when tweaking value.
Reviewed By: Severin
Differential Revision: https://developer.blender.org/D8513
Original sequence lookup failed, becase name changed in another thread.
Fix is same as 0471349c90 - stop prefetching before changing content
of seqbase.
I have covered more cases, and added assert so it is more obvious that
issue is in lookup, and it shouldn't fail.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8592
The fix for T75936 made it possible to export invisible objects to
Alembic. This commit applies the same approach to the USD exporter.
The USD and Alembic code is slightly different in terms of where in the
exported file the visibility attribute is stored. In USD the visibility
is used to prune the scene graph, and thus there are only two options:
"hidden" and "inherited". Setting the visiblity of a node in the scene
graph to "hidden" immediately hides all its children. To allow hidden
parents with visible children, the visibility is stored on the object
data (so the geometry/camera/lamp/etc) instead.
Add a test that checks invisible objects are iterated over by the
`IO::AbstractHierarchyIterator` class, when a suitable depsgraph is given.
No functional changes.
Add a new depsgraph builder class that includes invisible objects and
use that in the Alembic exporter.
Alembic supports three options for visibility, "visible", "inherited",
and "hidden". This means that parents can be hidden and still have
visible children (contrary to USD, where invisibility is used to prune
an entire scene graph subtree). Because of this, the visibility is
stored on the transform node, as that represents the Object in Blender
and thus keeps the Alembic file as close to Blender's own structure as
possible.
Reviewed By: Sergey
Differential Revision: https://developer.blender.org/D8595
Rename test `alembic_tests` to `alembic_export_tests`, so that its name
is consistent with the Python file containing the tests,
`alembic_export_tests.py`.
No functional changes.
The paint cursor now uses a single call to
SCULPT_cursor_geometry_info_update and the Sculpt API to update both the
radius and the SculptSession data, so random access needs to be
initialized for dyntopo before using API functions.
Reviewed By: sergey
Maniphest Tasks: T79597
Differential Revision: https://developer.blender.org/D8489
When copying between a set RNA runtime property and an unset one, code
would not behave properly.
We have to also consider NULL 'override apply' callback pointer as a
valid 'use default override apply function' case.
Instead of checking for the length of a list, just handle the error that
occurs when the length is incorrect.
No functional changes to any actual test.
Currently, the search operator in the node add menu NODE_MT_add is drawn
even if no node categories exists. This patch only draws the operator if
at least one node category passes the poll.
This patch is needed because some add-ons use custom search operator and
do not register node categories. In this case, it is undesirable to have
a search operator drawn that do nothing and is not used. One such add-on
is Animation Nodes.
Reviewed By: Jacques Lucke
Differential Revision: https://developer.blender.org/D8576
The BLI_bitmap had the potential to eat a lot of memory as it was a
dense map between all the vertices in the mesh.
Now we instead use BLI_edgeset so that we only store data when needed
(creating a spare map instead of a dense).
In EEVEE the AO renderpass influenced other render passes. Until now the
pass wasn't selectable when AO was disabled in the scene to remove these
render artifacts.
This patch allows rendering EEVEE AO pass without enabling it in the
scene. It does this by binding a fallback texture that is used by the
surface shaders.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D7956
This commit renames 'execute' to 'run' because:
- This follows Python's "PyRun" which these functions wrap.
- Execution functions can use either exec/eval modes,
making naming awkward (for future API refactoring).
This was committed as a temporary workaround in 82150f5641
as release builds were failing (only debug builds worked).
This adds `stdio.h` to the header which is now split into a file that
contains more specialized functionality.
Also move function body inside BPY_python_backtrace,
removing PyC_StackPrint as we have PyC_StackSpit() for
similar functionality that can be called from a debugger.
Use a "generalized winding number" calculation to get an inside/outside
test that works reasonably well when meshes aren't closed.
This change allows one to use a plane as the cutter in a difference
operator and get the expected results.
Checks for header alignment didn't account for tool-header & header
having different alignment.
There is no reason to use a lookup function on the area
(ED_area_header_alignment) as we already have region.
Check the regions alignment directly, remove access functions.
The existing header flip detection didn't account for mixed
tool-header and header flipping & visibility between space-types.
Now alignment syncing handles any combination of header,
tool-header & footer flipped state, in a way that can be extended
to other region types in the future.
Since the beginning of time, Boolean has not supported this.
While it might be too slow for some uses, it seems that the user
should be able to decide whether to use it or not.
By default boost::python in debug configuration links the release
python libraries. Which leads to loading issues with the produced
modules in a debug blender (which does use the debug python libs)
Bjam has an option to switch this to the debug libraries but when
you switch that on it changes the library names for *all* boost
libraries, even ones that don't have anything to do with python
and even the release libraries.
therefore an alternative way has been chosen and we're dealing
with this by adding a define rather than asking bjam to do it.
Many of these popovers could use a design pass in 2.91, but for 2.90 we
don't want to change any UI strings at this point, so the best way to
solve the cutoff text is to widen the popovers. Sadly this won't affect
popovers when other languages besides English have longer strings, but
solving that is a much larger task.
Another benefit is that tweaking sculpt / paint brush options feels much
less cramped with slightly wider popovers.
I only know of one string that is still slightly cutoff by default with
this patch, the "Max Element Distance" property of the pose brush in the
sculpt mode brush settings popover. But I didn't think it was worth
widening that popover more to deal with that one case.
Differential Revision: https://developer.blender.org/D8575
We have to explicitly enable fixed world space lighting. This was in
fact already done, but overridden by the code to sync the 3D View
shading settings to the VR view.
Mistake in cb578ca104. Before that, the extension vector was static,
to make sure the extension name strings wouldn't get destructed when
leaving the function. I didn't think that was an issue and couldn't
recreate one, because until the previous commit we wouldn't actually
add any extensions to the vector on Windows (the system I tested
with).
Use C++17's `std::string_view` now, which avoids the string copies
`std::string` creates for itself and thus its destruction when leaving
the local scope.
The OpenXR debug extension was disabled on Windows as a workaround. This
was an old leftover from when there was only the Windows Mixed Reality
runtime on Windows. The debug extension didn't work for it and we didn't
have a way to disable it just for Windows Mixed Reality.
Now it seems to work though, so we remove the workaround. If specific
runtimes still have trouble with the extension, we can disable it
specifically for these runtimes now.
Windows only workaround. I'll have to investigate Linux separately.
Steam's OpenGL compatibility is still new and doesn't work for us yet
(neither does it for standard OpenXR examples from what I've heard and
seen myself). We can work around that by falling back to our DirectX
compatibility layer.
Note that this DirectX compatibility still doesn't work for some
systems, see T76082.
Implementation note: Since the graphics binding extensions have to be
enabled before we can find out which runtime is in use (e.g. SteamVR vs.
Oculus, etc), we can now enable multiple graphics binding extensions but
settle for a single one to use later.
Once the SteamVR OpenGL backend works, we can remove this workaround
again.
Fixes T78267.
On VR session start with positional tracking disabled, the pose would
have an offset applied but it was supposed to start exactly at the
landmark position.
Issue is that we applied the offset to cancel out the position offset
reported by the OpenXR runtime incorrectly. We only want to do that if
positional tracking is enabled, because if not we don't even apply the
runtime's position offset. So we'd cancel something out that wasn't
there.
The new reverse iterators behave as the reverse iterators for contains from
the standard library. Have a look at the tests to see how to use them.
Using them will hopefully become easier with ranges in C++20.
A Vector can now be constructed from two iterators, which is very common
in the standard library.
New Vector.insert methods allow adding elements in the middle of a vector.
These methods should not be used often in practice, because they has a linear running time.
New Vector.prepend methods allow adding elements to the beginning of a vector.
These methods are O(n) as well.
* Avoid deep copy of vectors (technically more than a cleanup).
* Use `std::make_unique` for allocating unique pointers, rather than
manual `new`.
* Use `std::optional` for optional by-value return values, rather than
C-style `bool` to indicate success + return-argument.
* Use references rather than pointers for non-optional arguments.
* Avoid manual `new`/`delete`. Use `std::unique_ptr` for local scope
bound lifetime.
* Use C++ `nullptr` rather than C's `NULL`.
* Remove unnecessary friend declaration.
These changes are generally considered good practise and move us more to
a "modern C++" style. We can still go much further of course.
See https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines.
Since DATA_PT_sculpt_vertex_colors has its own poll() we need to call
the poll() of MeshButtonsPanel as well
Differential Revision: https://developer.blender.org/D8563
This feature was removed during the refactor, but it's needed for this type of strokes to display the line using the stroke color without checking if the stroke is enabled or not in the material.
This color is used only for these special strokes.
This patch changes openvdb from a static to a dynamic library.
this is in preparation for enabling pyopenvdb at some point
in the future.
Differential Revision: https://developer.blender.org/D8282
Reviewed by: brecht
Many of the icons had lots of interior geometry left over from
subdivision. In these cases we should remove the interior geometry
and leave the object with the modifier for the future.
This icon mimics the details of the cloth brush icon while using the
frame style extablished for the other "filter" tools.
Differential Revision: https://developer.blender.org/D8467
This icon mimics the details of the cloth brush icon while using the
frame style extablished for the other "filter" tools.
Differential Revision: https://developer.blender.org/D8467
In this mode the preview image is always using the most of the preview
area space: it is scaled to fit, preserving aspect ratio. This makes it
possible to always have maximum of the preview region even after resize
of other areas.
This mode is enabled by default, is available in the View -> Zoom to Fit
menu. It is enabled when View All (Home key) is used, and is disabled
when manual navigation ([panning, zooming) is performed.
There is no versioning code, which means existing files will open as-is,
but new projects will have this option enabled.
Ref T78987
Maniphest Tasks: T78987
Differential Revision: https://developer.blender.org/D8549
Allows to hook per-space code which is to be run on view navigation.
This is required to have zoom-to-fit implemented in the sequencer.
There might be more cases where the clalback is to be called from,
but it could be easier to address those on the case-by-case basis
when its needed.
This changes the drawing paradigm a bit. The VAO configuration is done
JIT-style and depends on context active shader.
This is to allow more flexibility for implementations to do optimization
at lower level.
The vao cache is now its own class to isolate the concept. It is this
class that is reference by the GLContext for ownership of the containing
VAO ids.
We instead use a handle reference counter on the GPUVertBufs used by
the instancing batches. This make sure that if an update happens on the
GPUVertBuf used to contruct the batch, they will never have the same
memory address than the previously allocated ones (since they are still
pending deletion thanks to the refcounter).
This avoid the linear search to update the GPUBatch in the case a
batch is deleted (which was even a bad option since they could be only
cleared)
A handle refcount is here to avoid freeing of the GPUVertBuf datablock
if it is still referenced somewhere else.
This does not prevent deleting the actual data. This is to avoid too
much zombie data usage.
This is in order to avoid most hacks inside `draw_instance_data.c`.
It was impossible for drivers to use shape key properties, modifiers
generate a new mesh. After mesh evaluation the shape keys are no longer
necessary, and because of this the `key` pointer was not copied. As
drivers work on evaluated data, however, they do need this `key`
pointer.
This commit makes the `key` pointer available in evaluated meshes, but
this is somewhat dangerous. There was an explicit reason why the key on
result was kept at null pointer: to have the evaluated mesh in a
consistent state. Assigning this pointer makes it potentially
inconsistent, as the evaluated mesh and the original shape key may have
different topologies.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D7785
It was always possible to set it to zero by typing in the value.
This new soft limit is more consistent with the fluid cache
and the Scene.frame_start property.
This was a regression in deaff945d0 which skips copying a mesh.
Dupli-verts/faces were not updated to account for this.
This supports iterating over edit-mesh vertices & faces,
since falling back to a full copy (as we do in some places)
will be slow while transforming geometry.
This commit looks as if it would change behavior with orcos,
since any edit-mesh deformation causes them to be assigned.
However in practice there is no functional change, details in comments.
Replace the evaluated mesh with VertexDupliData.mvert since only
vertices are used. This makes dupli-vert similar to how dupli-face
was already working.
When using constant falloff symmetry was working fine because the same
deformation is applied twice on the same vertices. When using no
constant falloffs, the deformation is different between symmetry passes,
so vertices need to be separated by symmetry areas to get the right
deformation from its symmetry pass without being overwriten by the next
one.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8541
This adds the boundary_falloff_type and boundary_offset to control how the
falloff of the Boundary Brush is applied.
Boundary Origin Offset is the same concept as the Pose Origin offset in
the Pose Brush. It is a multiplier that adds extra length to the brush
radius to locate the deformation pivot further from the boundary without
affecting the falloff.
The Falloff type includes Constant (previous default), brush radius, loop
and loop and invert. Loop and Loop and Invert can be used to create
deformation patterns in a mesh.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8526
If the File Browser was used in regular editor mode (e.g. not through an
operation like File > Open), the operator that usually opens files and
directories wouldn't execute. We need to keep two operators for
double-click in the keymap so selecting and opening works in all cases.
Caused by c606044157.
This adds support for panel categories to the instanced panel system
used for modifiers and others. The change is pulled from D7997 where
it is needed for FCurve modifiers, but it is unused now.
The change is simple and basically amounts to checking the panel
category where it was overlooked before.
This brush deletes displacement information of the Multires Modifier,
resetting the mesh to the subdivision limit surface.
This can be use to easily delete parts of the sculpt or to fix
reprojection artifacts after applying a shrinkwrap.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8543
This this adds the option of building boost::python
in the libs builder, in preparation for future
dependencies that require it (ie pyopenvdb)
disabled by default, can be enabled with the
`WITH_BOOST_PYTHON` cmake option.
Differential Revision: https://developer.blender.org/D8212
Reviewed by: brecht
Previously the way to use this operations was using the shortcut Ctrl +
W and Ctrl + Alt + W, which was not very discoverable and it was
limiting the amount of options that can be added to the operator.Now the
same functionality of the operator is available as a tool, which will
make easier to add other editing operations and options without adding
more entries to the keymap.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8545
The object "delta_" rna variables were not added to the depsgraph search
and thus it would not trigger updates of the object during animation
playback.
The object "delta_" rna variables were not added to the depsgraph search
and thus it would not trigger updates of the object during animation
playback.
DRW_render_set_time is calling RE_engine_frame_set will in turn calls
BKE_scene_camera_switch_update.
To workaround this, we get the original camera object at render init and
get the evaluated version from it after each time change.
This change how motion data are indexed inside the ghash.
We follow cycles closely now and use evaluated ID pointers.
By removing the hack, it fixes T78561 (No Motion Blur on linked objects)
This fix issues with instanced geometry and modifiers. Since the
depsgraph will duplicate the objects when they have different modifiers,
the evaluated object are garanteed to be unique.
If one of the operands of a binary operator a float, integer
operand gets promoted to float as well.
Differential Revision: https://developer.blender.org/D8552
For a locked shapekey, a SculptSession's orig_cos / deform_cos /
deform_imats are not initialized (they only are when
deform_modifiers_active is true -- this in turn is only true for
shapekeys if they are //not// locked [and for deforming modifiers of
course])
We can just update that keyblock with sculpt_update_keyblock() in case
of a locked shapekey
Maniphest Tasks: T79622
Differential Revision: https://developer.blender.org/D8499
Caused by rBfffba2b6530.
In above commit, the buttons rnaindex [-1 for entire arrays like colors]
was not used anymore for the entire function body of
`ED_autokeyframe_property` (previously in `ui_but_anim_autokey`).
Replacing the index with 0 (in the array case) is indeed necessary for
`BKE_fcurve_find_by_rna_context_ui`, prior to rBfffba2b6530 this was
taken care of by using `ui_but_get_fcurve` instead [which did this
internally].
But using an index of 0 (instead of -1) for the entire function body of
`ED_autokeyframe_property` fails for the array part later, namely
`insert_keyframe` needs -1 here.
Now just replace the index for //finding the FCurve//, but use the
original for //inserting the keyframe//.
Could be backported to 2.83 LTS.
Reviewers: campbellbarton, sybren
Subscribers:
The current code is only supposed to work if the input meshes
are "piecewise constant winding number" (PWN). Added a check
to see if this is true about the inputs.
The previous algorithm was not using all of the requested grids to build a mesh
around the volume due to limitations regarding the use of a dense buffer to
gather information about the volume's topology. This resulted in artefacts during
rendering.
The mesh generation is now done by merging all of the input grids and using the
resulting grid's topology to create the mesh. The generation of the mesh
is still done in index space as before, and the vertices are converted to object
space by using the merged topology grid indexToWorld transform.
To be able to merge the grids together we have to make sure that their transformation
matrices and their index spaces match, thus, if they do not match we simply resample
the grids. This behaviour should tackle one other limitation of the current algorithm,
which is that only one transformation matrix was used to generate the final mesh.
If we do not have an OpenVDB grid for the requested volume data, we generate
a temporary OpenVDB grid for it.
Differential Revision: https://developer.blender.org/D8401
Now the one vertex defines the position of the UV chart, while rotation and
shape is still determined automatically.
Initial patch by Willis (wlssirius).
Differential Revision: https://developer.blender.org/D8484
This is particular important because 2.90 will coexist with 2.83 LTS, so
we should warn the users of potential loss of data when going from 2.90
to 2.83 and back.
Differential Revision: https://developer.blender.org/D8488
Those where assuming we always get a valid modifier data from context,
which is not always true...
Also fix similar issue with shortcuts as reported in T79635.
It is unfortunate that we cannot get active modifier from context when
operator is called from a shortcut, but we'd need an event for this to
work... So for now forbid any modifier operation of liboverride objects
in that case.
'VIEW2D_OT' operators were not respected in WM_keymap_guess_opname().
This was seemingly done on purpose (see comment "Op types purposely
skipped for now"), but dont really see the reason for doing so.
Since the "View2D" keymap is not bound to a specific spacetype, we can
still find it using WM_keymap_find_all() [and passing 0 as spacetype].
Reviewers: Severin
Subscribers:
Vert-only mesh is valid input for the skin modifier (displays isolated
cubes), prevent error message about missing root vertex in that case.
Maniphest Tasks: T79700
Differential Revision: https://developer.blender.org/D8533
saving with 'Remap Relative' option
Caused by rBf7386b97571e.
Logic in BKE_bpath_traverse_main calls the callback multiple times [as
often as there are images in the strip].
Prior to above commit, the callback was
'bpath_relative_convert_visit_cb' [this one did not have this problem -
since it returned early if the path was already made relative once]
After rBf7386b97571e though, the 'bpath_relative_rebase_visit_cb' is
used [this one should not be entered multiple times, it would modifiy the
directy again and again].
Luckily, we have a flag (BKE_BPATH_TRAVERSE_SKIP_MULTIFILE) that can be
used to prevent this (this will take care of only calling the callback
once in BKE_bpath_traverse_main for the VSE case)
Could be backported to 2.83 I think.
Maniphest Tasks: T79676
Differential Revision: https://developer.blender.org/D8536
This commit generally moves variable declarations to the smallest scope
the variables are used in. This makes the code more readable by
making it clearer when variables are used and by removing the block
of variable declarations at the top of each function.
This change makes the generated points a light dimmer than selectable points.
Before:
{F8765593}
After:
{F8765585}
Maniphest Tasks: T79683
Differential Revision: https://developer.blender.org/D8515
This options allows to perform Face Sets operations while preserving the
mesh visibility. Edit hidden face sets is enabled by default in order to
expand the visible area of the mesh with the grow/shrink operator, but
this can be changed in the keymap per edit operation as more operations
are supported.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8029
Old and new collections are the same data in Master collection case
here, so we cannot consider the `gobject` listbase of `collection_old`
as always immutable.
This commits:
- Updates some libraries to latest officially supported versions:
** Numpy: 1.17.5
** OCIO: 1.1.1
** OIIO: 2.1.15
** OSL: 1.10.10
** OIDN: 1.2.1
- Re-enables some distro packages (like OSL, OIIO, OCIO...).
- Add missing 'CMake cleanup commands' for generated CMake update
command, for Embree, OIDN and OpenXR.
- Generalizes using min/max versions of accepted libraries, if no
package can be found in specified range then it is built from sources.
The later point should help keeping things a bit in better conditions,
although current maximal accepted versions are somewhat arbitrary guess
currently.
The preview of points was only done when the edge is wire.
Now the preview of points is done when the edge is not connected to any
quad.
Also to avoid edge slide in this case, all new vertices created in this
specific case are not selected.
Differential Revision: https://developer.blender.org/D7457
Is not only the values of translation/scale/rotation which are to be inverted,
but also the order of operations.
Differential Revision: https://developer.blender.org/D8518
This reverts commit 9adedb2605. It changes
how duplis work, and by that altered how Alembic and USD files are
written. This was signalled by a failing Alembic unit test.
Now the operators are split to define different default values. This is also required for the future Bezier primitive tools.
This allows to show in the Topbar the number of subdivisions. Before this value was totally hidden and it was number of Edges. The wheelmouse can be used to override the value while running, but does not change the default value.
{F8766270}
All operators share same code.
Also, fixed some bad practices done with Toolbar in python.
Reviewed By: mendio, pepeland
Differential Revision: https://developer.blender.org/D8506
Mainly caused by moving tests to source folder, which brings
new compiler flags.
Also, no need to extend include directories (to the non-existing paths,
btw) since this is done by the CmakeList.txt which is in the blenlib folder.
Solves possible pointer-based comparison fiasco.
Another nice outcome of this is that topology cache will now be
preserved throughout the undo system. For example, undo of object
transform will not require topology cache to be re-created.
Differential Revision: https://developer.blender.org/D8493
The file was including BKE. It was a required fix for another
compilation error a while back. It is a bad level include, and
seems is not needed anymore.
The problem here is that the baking code uses tiles to exchange pixel data with
the renderer since a recent-ish refactor, but the code that sent data to the
renderer did not initialize the bake result pixels.
Therefore, when the baking process for the second object started, Cycles
received empty tiles and sent them back as-is if the second object did not
cover them.
By initializing the tiles with the result of the previous bakes, we avoid this
problem.
We can't exactly follow what we do for macOS here. On Windows special
characters can be inserted with Ctrl+Alt. So make sure we expect UTF-8
characters when Alt is held.
Mistake in 87062d4d67.
Since C++17 there is also std::string_view, which is similar to StringRef.
This commit does a couple of things:
* New implicit conversions between StringRef and std::string_view.
* Support std::string_view in blender::DefaultHash.
* Support most of the methods that std::string_view has.
* Add StringRef::not_found which can be used instead of -1 in some places.
* Improve/fix the description at the top of BLI_string_ref.hh.
And make them part of the blender_test runner. The one exception is blenlib
performance tests, which we don't want to run by default. They remain in their
own executable.
Differential Revision: https://developer.blender.org/D8498
This adds a property that checks the normals of each vertex against the
view direction to decide if they should be masked (similar to the
"Front Faces Only" option works for brushes.
Reviewed By: sergey
Maniphest Tasks: T77637
Differential Revision: https://developer.blender.org/D8448
This brush includes a set of deformation modes designed to deform and
control the shape of the mesh boundaries, which are really hard to do
with regular sculpt brushes (and even in edit mode). This is useful
for creating cloth assets and hard surface base meshes.
The brush detects the mesh boundary closest to the active vertex and
propagates the deformation using the brush falloff into the mesh.
It includes bend, expand, inflate, grab and twist deform modes.
The main use cases of this brush are the Bend and Expand deformation
modes, which depend on a grid topology to create the best results.
In order to do further adjustments and tweaks to the result of these
deformation modes, the brush also includes the Inflate, Grab and
Twist deformation modes, which do not depend that much on the topology.
Grab and Inflate are the same operation that is implemented in the
Grab and Inflate tools, they are also available in the boundary brush
as producing deformations with regular brushes in these areas is very
hard to control.
Even if this brush can produce deformations in triangle meshes and
meshes with a non-regular quad grid, the more regular and clean the
topology is, the better. Most of the assets this brush is intended to
deform are always created from a cylindrical or plane quad grid, so it
should be fine. Also, its algorithms can be improved in future versions
to handle more corner cases and topology patterns.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8356
Proper handling of View Layers for the VR session was never implemented.
Now the View Layer of the VR session follows the window the session was
started in.
Note that if this window is closed, we fallback to another window. This
is done to avoid the overhead it would take to maintain a separate
depsgraph for the VR view. Instead we always share some already visible
View Layer (and hence the depsgraph).
The problem is caused by a lack of prediction in the `isect_line_segment_tri_v3`
that incorrectly confirms some intersections of coplanar segments to the triangle.
The solution is to use another algorithm to detect intersections.
This also resulted in a slight improvement in the performance:
- 1min 17sec to 1min 6sec in my test file
Differential Revision: https://developer.blender.org/D8500
Root of the issue was not fixed in 2.90, only hidden by the fact that we
now re-read much less data during undo's that we used to, when some new
datablock gets added or removed.
This is not an ideal solution (as usual when dealing with data pointers
shared across data-blocks), but it's decent enough. thanks a lot to
@brecht for it!
To be backported to 2.83 too.
We want the session to start exactly at the landmark position, with
no additional offset. Some runtimes (e.g. Windows Mixed Reality) may
give an initial non-[0,0,0] position at session start though.
Also add a comment explaining the purpose of the eye offset variable.
There would always be an unintended offset applied. Per design there
should not be any offset when changing VR Landmarks, the view should
just jump exactly to the Landmark.
Due to the recent changes, we don't have to add, but substract the eye
offset we apply to get the wanted behavior.
Mistake in 607d745a79.
We want the session to start exactly at the landmark position, with
no additional offset. Some runtimes (e.g. Windows Mixed Reality) may
give an initial non-[0,0,0] position at session start though.
Also add a comment explaining the purpose of the eye offset variable.
There would always be an unintended offset applied. Per design there
should not be any offset when changing VR Landmarks, the view should
just jump exactly to the Landmark.
Due to the recent changes, we don't have to add, but substract the eye
offset we apply to get the wanted behavior.
Mistake in 607d745a79.
This does not fix all the cases in the bug report, because there are multiple
different issues. Only the first two are fixed. The third is probably a known
issue for now.
Before this patch, the rigid body simulation was always done after modifiers
are evaluated, because to perform the simulation, the final geometry of the
object was required. However, the geometry is not required in all cases,
depending on the selected collisions shape.
This patch changes it so that when the simulation does not need the
evaluated geometry, the simulation will be done before the modifiers
are evaluated. This gives the modifiers access to the simulated positions.
When the rigid body simulation does depend on the evaluated geometry,
it will still be performed after modifiers are evaluated.
The simulation will be performed after modifiers are evaluated, iff
the collision shape is "Convex Hull" or "Mesh" and the source is set
to "Deform" or "Final".
Reviewers: sergey
Differential Revision: https://developer.blender.org/D8487
In last set of refactoring patches, code implementing this feature
has been accidentally removed.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8449
This just set a global object responsible for allocating new objects
in a thread safe way without needing any GPUContext bound to this
thread.
This also introduce the GLContext which will contain all the GL related
functions for the current context.
# Conflicts:
# source/blender/gpu/intern/gpu_context.cc
This just set a global object responsible for allocating new objects
in a thread safe way without needing any GPUContext bound to this
thread.
This also introduce the GLContext which will contain all the GL related
functions for the current context.
For the main rationale behind this design, see 49f088e2d0. Further,
this removes users of uiBut.a1, which is a very ugly design
choice (hard to reason about).
Part of T74432.
Fix package name missmatch in a few module files. IE "ALEMBIC" was
defined in the file but the find_package commands used "Alembic"
Some modules state that they set and use the _LIBRARY variable but the
do in fact not do this. Removed these comments from those files.
Enable Clang-Tidy's `readability-function-size` rule and add a few
`NOLINT` markers to explicitly silence warnings for three functions.
These functions are huge and would IMO benefit from splitting up, but
are hard to without intimate knowledge of the code.
At least by enabling the rule, we can start tweaking the values and
refactoring other functions that bubble up as being too long/complex.
No functional changes.
Add a `NOLINT` marker to explicitly silence a warning from Clang-Tidy's
`readability-function-size` rule for the `node_type_base()` function.
This function is indeed huge, but that is because a lot of macros are
expanded. Before expansion things are still not small, but still
understandable & expandable.
No functional changes.
In the 3D View, the "Animation" keymap is not used, but the mode
specific ones. So the shortcut editing code should use these too, just
like the default keymap does.
This adds a `NOLINT` marker to explicitly silence a warning from
Clang-Tidy's `readability-function-size` rule for the `incircleadapt()`
function in `delaunay_2d.c`.
No functional changes.
This adds `NOLINT` markers to explicitly silence warnings from Clang-Tidy's
`readability-function-size` rule for versioning functions. Technically
these could be refactored and split up into smaller bits, but generally
they are hardly ever looked at once they're a few releases old.
No functional changes.
This addresses warnings from Clang-Tidy's `readability-function-size`
rule in the `source/blender/python` module.
It's just `BPyInit_bgl()` that's been split up into one or two smaller
functions per OpenGL version.
No functional changes.
For the main rationale behind this design, see 03b122e2a18df. Further,
this removes users of `uiBut.a1`, which is a very ugly design
choice (hard to reason about).
Part of T74432.
For the main rationale behind this design, see 03b122e2a18df. Further,
this removes users of `uiBut.a1`/`uiBut.a2`, which is a very ugly design
choice (hard to reason about).
Part of Part of T74432.
The current on-size-fits-all `uiBut` creates quite a mess, where it's
hard to reason about which members are free for use, under which
conditions they are used and how.
`uiBut` also has members that aren't used at times, violating the "don't
pay for what you don't use" principle.
To address this, we want to move to typed buttons, where `uiBut` is just
a base struct and each type extends it as needed. That structures data
better and type specific data is only available if it's actually used by
a button type.
Two trade-offs:
* Many casts to the derived type have to be done.
* Sometimes we change the button type after it's created. So I had to
add logic to reallocate the button for use with the new, possibly
derived struct. Ideally that wouldn't be needed, but for now that's
what we have.
Part of T74432.
Differential Revision: https://developer.blender.org/D7610
Reviewed by: Brecht Van Lommel, Campbell Barton
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule. This should be the final commit of the series of commits that
addresses this particular rule.
No functional changes.
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/draw` module. Not all warnings are addressed
in this commit.
No functional changes.
Clicking on the column header is supposed to enable sorting by this
column, or switch the sort order if already enabled.
The double-click event would be blocked by the `file.execute()`
operator, which is not supposed to act if the user clicked outside the
file list.
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/blenlib` module. Not all warnings are
addressed in this commit.
No functional changes.
This replaces header include guards with `#pragma once`.
A couple of include guards are not removed yet (e.g. `__RNA_TYPES_H__`),
because they are used in other places.
This patch has been generated by P1561 followed by `make format`.
Differential Revision: https://developer.blender.org/D8466
Follow path seems to not be catched by `BKE_object_moves_in_time`.
For this reason, we cache all transforms for all object and check
ourselves if an animation occurs. This is almost what cycles does.
We also fix the rigid body case if the rigid body use deformation.
The Pose FK mode assings the rotation origin to the boundary of the last
visited face set in the floodfill operation. In some cases, the topology
of the model may make the flood fill operation to visit a face set as the
first one (assinging it to target) and visit it again as the last one
(assinging it to origin). This will make the pose brush to default the
origin and target to the brush location and not to the face sets as it
considers that there is only one possible boundary.
This adds a GSet to ensure that a particular face set is not visited
twice in the flood fill, fixing these cases.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D7984
This makes possible to choose between a local and a global simulation
when the cloth brush is used. Local simulation is the current default.
When global simulation is enabled, the cloth brush simulates the entire
mesh without taking any simulation limits into account.
This was possible before by setting the simulation limits to 10 (the
current maximum value allowed) so the entire mesh was inside the limits,
but this was a hack as the limits scale with the radius and there should
not be any limitation on how big the simulated area can be to be able to
simulate an entire object. This also allows to make a more clear
distinction between cloth brush presets that are intended to be used in
local areas to add details or globally to generate the base shape of the
mesh.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8481
This patching duplicates the first frame of the layer if the first frame number is not equals to the scene first frame number.
Related to T79567
Differential Revision: https://developer.blender.org/D8486
Some minor cleanup in the patch.
The paint_draw_cursor function was handling the cursor drawing for 2D
and 3D views of all paint modes, calculating the brush radius, updating
the SculptSession data and updating and drawing all sculpt cursor
overlays for different tools. It was almost impossible to understand when
and what was being drawn and in which state the GPU matrix was.
Now everyting is organized into different functions, with clear
separation between modes, sculpt tool overlays and different drawing
setups. Update and drawing functions are also separated (this allows to
skip one PBVH query on each cursor drawing).
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8206
The current code is accessing this from outside the gpu "namespace". As
such it should be accessing GPU_ functions, not gpu_ functions.
This is also a place to centralize the XXX message that will be
addressed upon refactor. So we can reuse this call in other places that
need the same temporary workaround.
Groundwork for upcoming fix (D8472)
In an upcoming bugfix we'll use OpenVDB data structures directly to build mesh
for sparse OpenVDB volumes, loading them OpenVDB grids earlier and removing any
references to Blender data structures makes that easier.
This also makes changes to Blender volumes to support this, so Cycles can take
ownership of a grid without Blender having to keep its own reference to it.
This should also be useful in a future Python API.
Ref D8401
Small tweaks to make labels and texts more correct, consistent and
polished.
Reviewed by: Aaron Carlisle, Julian Eisel
Differential Revision: https://developer.blender.org/D8346
Having includes in debug builds makes it possible to accidentally
break release builds.
Avoid this by moving calls to other modules out of BLI_assert.h
into BLI_assert.c
When adding multiple force fields of different types they are all called
"Field", making it difficult to tell them apart.
Lights were already named based on their type. This follows the light
code.
New names:
- Force
- Vortex
- Magnet
- Wind
- Guide
- TextureField
- Harmonic
- Charge
- Lennard-Jones
- Boid
- Turbulence
- Drag
- Fluid
- Field
Reviewed by: Julian Eisel
Differential Revision: https://developer.blender.org/D8420
Similar to T58668, labels were not aligned when multi-editing widgets
that are not center-aligned.
Reviewed by: Hans Goudey, Julian Eisel
Differential Revision: https://developer.blender.org/D8441
Align items in the edit mesh context menus (reducing padding), for
consistency with other menus.
The root layout of menus doesn't add the padding, for sub-layouts
`align` has to be enabled.
{F8749633}
Reviewed By: Julian Eisel
Differential Revision: https://developer.blender.org/D8480
This seems to be caused by a change to the logic of movieclip_get_gputexture_ptr in rB97b597c.
Differential Revision: https://developer.blender.org/D8469
This implements collisions in the solver of the cloth brush/filter. It
uses the scene colliders as a regular physics simulation.
There are still some parameters (friction, distance to the surface...)
that can be exposed as properties in later patches.
Thanks to Sebastian Parborg for helping me with the implementation.
Reviewed By: sergey, zeddb
Differential Revision: https://developer.blender.org/D8019
The panels are rebuilt when a modifier is removed so the button handlers need
to properly finish. By adding a context argument to the panel_delete function
this will happen properly.
This adds a curvature smoothing and intensify details properties to control
the result of the Sharpen Mesh Filter.
Curvature smoothing removes high frequency details from the precalculated
sharpen data, so the filter result has much smoother surfaces and cleaner
sharpen lines;
Intensify details displaces the vertices of creases and valleys in the direction
opposite to its neighbors average, so it intensifies high frequency details
in those areas, producing more noisy and sharp shapes:
Both this properties can be used in combination to achieve a good balance of
high and low frequency details depending on the shape and the desired result.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8447
Previusly it was using the / character, which implies that there is one
deformation mode and and invert deformation mode like in the other two
deformation, but squash and stretch is only one deformation mode and
does not have an invert mode.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8463
The scale deform mode includes rotation by default, so when when scaling
down a part of the models it becomes harder to control as the effect of
the rotation less predictable (similar to using trackball rotation in a
very small radius). This locks the rotation of the segment, so parts of
the model can be scaled down in a more predictable way.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8465
Steps to reproduce were:
* Open File Browser
* Create a new directory
* Cancel renaming with Esc
File selection flags were modified during drawing when the rename button
got removed, but the file name label drawing wasn't checking the
modified state.
These tests rely on the behavoir of the old boolean, down the the
exact values of coordinates and ordering of the output vertices.
Because I want the default behavior of boolean to be new boolean
in this branch, this is inconvenient. I will make these tests work
again if/when we merge with master. Probably by adding the flag
that invokes the old behavior to the tests.
New bevel is mostly tested by unit tests now, so disabling the
regression test for it is not a big deal.
The file.execute() operator is the one that actually opened directories
and files, not file.select() with the "open" option, as it was assumed
when changing the keymap to double-click for opening. It only acts on
the current selection though, so we have to ensure the selection is set
on the first click.
Now, some touch-pads have a delay until they register a click event, so
the double-click would be registered instead, before the selection is
set. Always select on mouse-down now and remove the unnecessary select
operator call on double-click.
The crash is caused by the fact that a NULL Object pointer is passed to
calculate the transform orientation, which has been set to normal.
A check has been include to detect the same.
Differential Revision: https://developer.blender.org/D7951
Use `td->iloc` as the coordinates of the transformed element.
It is more accurate and other transformation modes, such as scale, also
operate on `td->iloc`.
The icons are label buttons. Usually these are not editable and can not
become active. These are draggable ones though (so dragging files can be
dragged by dragging the icon) which creates an exception to this rule.
So hovering the icon would activate its label and when executing the
rename operator via shortcut it wouldn't get exited properly. This broke
the invariant of only allowing a single active button at a time.
Added an assert to check that invariant now.
Letting the code to activate the text button ensure any currently active
button is exited seems sensible.
When disconnecting links for defaulted node group inputs, recurse
into the nested node group nodes, instead of checking the socket
flag. Otherwise the behavior is confusing and differs from Cycles.
Differential Revision: https://developer.blender.org/D8455
Disabled buttons would incorrectly toggle state when a drag toggle
passed over them. This adds a check to prevent a drag toggle on disabled
buttons.
Differential Revision: https://developer.blender.org/D8476
The `rna_Scene_ray_cast()` function tried to find the current depsgraph. To
this end, it required the scene, the view layer, and bmain. Scene has a cache
of per-view-layer depsgraphs, to speed up switching between view layers. This
cache does not contain render depsgraphs, and evaluated view layers also don't
have a depsgraph here.
When a suitable depsgraph cannot be found, a new depsgraph is created. However,
this depsgraph is not evaluated, and has an unexpanded scene pointer with a
`NULL` `view_layer`. Using this then crashes Blender. Also, there was no way
for the code to get the render depsgraph.
The solution is to pass the depsgraph to the `ray_cast()` function, instead of
the view layer. This avoids the depsgraph lookup, and also works correctly when
rendering.
Some add-ons also need updating, which I'll do in the `addons`
repository soon.
Reviewed By: Sergey
Differential Revision: https://developer.blender.org/D8475
This uses the vertices per grid instead of quads to set the limit of
grids per PBVH Node. This should create more leaf nodes in lower
subdivisions levels where the duplicates count is high, producing more
uniform performance across different levels.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8454
There were two issues. First, I made a mistake when I switched from unsigned
to signed integers. Second, two classes with the same name were defined in
separate files. Those classes are in an anonymus namespace now, so that they
don't leak into other files.
ad4928a171 disabled alignment for too many cases. Still try to avoid
aligning many items, to avoid thousands of redundant alignment
calculations. But now we're much more picky adding an sub-row with
alignment.
On windows, spacebar would be passed as UTF-8 text input, despite the
control key being pressed. On macOS, there already was an explicit
exception for this (command key in this case), on Linux XInput already
handled this case for us.
Note that Alt should still allow text input, for special character
sequences.
Issue also happened in the Text Editor if a text data-block was set.
Optimization was disabled in this function to work around a bug in MSVC, use
a different solution that does not come with such a big performance regression.
In Blender 2.90 EEVEE materials were refactored that introduced crashes on Intel
GPUs on Windows. The crash happened in the `local_context_workaround` that temporary
stored compiled materials in a binary form to reload it in the main GL context.
It has been tested that the workaround isn't needed anymore for HD6xx GPUs, but it
is still needed for HD4000.
After several unsuccesfull fixes we came to the conclusion that we could not support
the local context workaround and needed to come with a different workaround. The idea
of this patch is that in these cases there is only a single context that is used for
rendering. Threads that uses these contextes are guarded by a mutex and will block.
Impact on User Level:
* Due to main mutex lock the UI freezes when rendering or baking or feel less snappy
Reviewed By: Clément Foucault, Brecht van Lommel
Differential Revision: https://developer.blender.org/D8410
As far as I can see, this problem was introduced with the gpu_free_unused_buffers() changes in rB97b597c.
The code checks the returned pointer to stop looping, but the last iteration will return the last GPUTexture and set the queue to NULL, meaning that the next pop() will crash.
Differential Revision: https://developer.blender.org/D8468
Some implementation have different maximum texture size.
This patch avoid crash when texture allocation fails when:
- trying to bake a lightcache too big for the OpenGL imeplementaion.
- loading a cache from file that is too big for the OpenGL imeplementation.
Face Sets where only set and updated on the PBVH after starting a sculpt
tool. In order to preserve the visibility they store when changing
levels, they need to be updated and sync also on PBVH creation
Reviewed By: sergey
Maniphest Tasks: T78665
Differential Revision: https://developer.blender.org/D8225
Duplicates of a grid corner adjacent to an edge which are on the
adjacent grid of the same face were not added when requested.
Needed for D8356 to work, it may also fix some other bug in Multires.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8385
The cloth brush has a defined simulated area with a falloff. In the falloff
area (the area between the dashed white circle and the exterior white
circle), simulation properties change in order to fade out the
simulation deformation effects towards the boundary.
With some brushes and stroke types (like anchored strokes with pinching
or grabbing with full strength), it is possible to apply more force than
what the boundary falloff can compensate, so the simulation breaks when
this happens.
This option pins the falloff area with softbody constraints, This
produces a much better deformation falloff and it is no longer possible
to move the vertices near the simulation boundary, so the simulation
won't break no matter the strength of the forces applied inside the
simulated areas.
This is an option as it is particularly useful for some brushes to add
localized details, but for brushes that are supposed to deform the
entire mesh (like the grab brush in D8424), this can add unwanted
softbody constraints that affect the simulation result.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8435
Box mask is not a selection, so it should not be part of the select
operator. This allows to add more sculpt mode specific functionality and
properties and to share more code with the lasso mask operator in a
later refactor.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8456
When switching workspaces we need to have an unused screen layout that
we can activate. The other window now showed the only available screen
layout in fullscreen though.
Usually when there's no unused screen layout we duplicate an existing
one, but that code didn't respect the fullscreen case properly.
This also tries to clean up the logic a bit, but things are still rather
complicated to follow.
Changes in this code are always risky. Of course things worked fine in
my tests, but I wouldn't be surprised if something breaks.
Filtering Collections when also filtering object children would only
display the parent object. Add a check for the NO_CHILDREN filter before
creating the object-parent hierarchy.
Several bugs with the acceleration filters cauased crashes and
incorrect results. Redid the error analysis and found some mistakes.
There was also a bug in the code for checking non-trivial intersections.
Now you can boolean a standard cube and cylinder and scale the cylinder
without crashing.
Also rewrote the tri-tri intersection code to make it more understandable
and also prepare the way for more floating filters.
The winding order of the faces changes when flipping the faces.
This lead to the loop indices changing as well.
Now we take this into account when restoring and flipping the custom
normals. Before the normals would be swapped.
The winding order of the faces changes when flipping the faces.
This lead to the loop indices changing as well.
Now we take this into account when restoring and flipping the custom
normals. Before the normals would be swapped.
The problem in this case was that the flag for active fire was not set. With hidden flow sources the flag was not updated in update_flowsflags().
The solution for this is to take the active field from the config cache file.
Previously a for loop with two iterations was used to calculate the
3D segment locations for the input number and the higher power of 2.
Splitting off the inside of the for loop to a separate function makes
the code more readable.
This commit also includes a simple timer for bevel, enabled with a
define. Interestingly, the cleanup in this commit happended to give
a 3% speedup on a Ryzen 3700x for a bevel calculation with 64
segments.
Same exact system as instancing on vertices for a mesh. More powerful ways
of instancing will be added at some later point, but this makes the basics
works and is consistent with other geometry types.
The tests were broken because of an extra call to
RNA_def_struct_name_property which set the name of the velocity
attribute to be the string used to identify CacheFiles in
bpy.data.cachefiles.
When changing the material while the properties editor temporarily isn't
visible (e.g. because another editor is in full-screen or a different
workspace is active), the preview wouldn't be updated on changes.
Always trigger a material preview update on screen layout or editor type
changes.
When changing the material while the properties editor temporarily isn't
visible (e.g. because another editor is in full-screen or a different
workspace is active), the preview wouldn't be updated on changes.
Always trigger a material preview update on screen layout or editor type
changes.
The data member `new` was conflicting with the `new` keyword
when `BKE_screen.h` was included in C++ files.
Reviewers: sergey
Differential Revision: https://developer.blender.org/D8459
Caused by rB63ee3db96107.
While above commit corrected the clip offset, it also removed logic to
ensure a marker on a particular frame. This is needed though, otherwise
changes on a particular frame are applied to the marker being returned
by 'BKE_tracking_marker_get' which can be a completely different marker
if none exist for that frame yet.
This patch partly reverts rB63ee3db96107 and reintroduces the framenr
for the MarkerUpdateCb and uses that to ensure a marker on that frame.
Candidate for backporting to 2.83 LTS?
Reviewers: sergey, jacqueslucke
Subscribers:
Before: If the current frame is out of the cache start/end range, the viewport will show the fluid as it was on the last frame that was still in the cache frame range.
Now: If the current frame is out of the cache start/end range, the viewport will show no fluid at all (even if there are cache files present for this frame).
This fix is related / in response to T79423.
The decomposed transform would have consists of nan values if the input
transform had zero scale.
Now the decomposition will check for zero scale, and if it is detected
then the result will be ensured to be finite. Additionally, rotation
value will be copied from previous/next time step to help avoiding
obscure interpolation.
The latter step can become more comprehensive than the current simple
implementation.
Differential Revision: https://developer.blender.org/D8450
This will make it easier & cleaner to make custom-built depsgraph (for
example for exporting invisible objects to USD or Alembic, see T75936).
No functional changes.
Reviewed by: sergey
Differential Revision: https://developer.blender.org/D8423
This flag specifies that even when the socket is not connected,
the node should not display the input field for the constant input
value. This is useful for inputs like Normal, which have special
handling for the missing input case and don't use a constant value.
Currently there is no way to change this flag from Python, and
through UI it can only be done by re-creating the socket.
This patch exposes the flag through RNA and UI, makes sure it
is properly updated when changed, and adds special handling to
ensure that it is correctly set when creating a node group from
a node set that includes reroute nodes.
Differential Revision: https://developer.blender.org/D8395
Instead of assuming the node width, compute the actual right bound.
Otherwise BSDF nodes tend to be too wide, and intersect Output.
Differential Revision: https://developer.blender.org/D8395
Avoid the conversion for the hook modifier as riggers
may need to enable this modifier in edit-mode.
The speedup of the modifier alone is significant since the hook
operation is simple compared to conversion that took over 99.9%
of the time in my tests, however the overall speedup was around to 1.6x.
The bevel code initialized the CurveProfile with the "higher power of 2"
segments after the normal number of segments, leaving the widget in an
incorrect state after the calculation. A simple fix is to re-order the
initializations, doing the input number second.
'Default' actually means 'Keep Existing' and it makes more sense to
display the more descriptive label.
Differential Revision: https://developer.blender.org/D7614
Fixes T78346.
The shortcut display and change code is context sensitive. To make it
work correctly the context needs to be set properly.
When executing operators from the dropdowns, the active region is the
header, but the shortcut handlers are set for the main region. So make
sure that is used instead.
This also sets the main region active for context menu operators, where
this issue shouldn't be present. Doing it anyway shouldn't hurt though
and fixes this issue in case somebody displays the context menu in the
header as dropdown too.
Instead of clearing forces at the end of the simulation step, they will now be cleared before writing to them, i.e. at the beginning of a step.
Also cleaned up minor areas that I looked at while making this change.
Following work done in 2.83, the resolution control is now a real
level-of-detail parameter. It is now useful to be able to set the
resolution for display independently from render. This is true for
both mesh generation and mesh deformation modes.
For compatibility with old scenes, resolution is retained and is the
render resolution. Old modifiers loaded have the value of resolution
also applied to viewport resolution. This allows newer modifiers to
be used in older versions without trouble
Differential Revision: https://developer.blender.org/D8336
The text colors set by the general widget state function
(`widget_state()`) would always be overriden by the menu-back text
colors to avoid contrast issues. This would only respect the selected
state, not other states.
Address this now by changing the input theme colors to use the menu-back
ones, rather than overriding after the fact (calling `widget_state()`).
Changing the surface distance through the flow type is inappropriate here. It had been added to ensure that liquids / smoke use a different emission value.
Now the value will only be changed when changing from a gas to a liquid emitter or, vice-versa, when changing from a liquid to a gas emitter.
There is a parameter typo in Python API document about bpy.props.StringProperty.
This patch fixes this.
Also this patch should apply to 2.90 branch as well.
Reviewed By: Grische, mont29
Differential Revision: https://developer.blender.org/D8430
Code required the tabs to be placed in an aligned region. Code should
work fine even for unaligned regions though, so I don't see a reason to
forbid this.
This patch adds the ability to render motion blur from Alembic caches.
The motion blur data is derived from a velocity attribute whose name has
to be defined by the user through the MeshSequenceCache modifier, with a
default value of ".velocities", which is the standard name in Alembic
for the velocity property, although other software may ignore it and
write velocity with their own naming convention (e.g. "v" in Houdini).
Furthermore, a property was added to define how the velocity vectors
are interpreted with regard to time : frame or second. "Frame"
means that the velocity is already scaled by the time step and we do not
need to modify it for it to look proper. "Second" means that the unit
the velocity was measured in is in seconds and so has to be scaled by
some time step computed here as being the time between two frames (1 /
FPS, which would be typical for a simulation). This appears to be
common, and is the default behavior.
Another property was added to control the scale of the velocity to
further modify the look of the motion blur.
Reviewed By: brecht, sybren
Differential Revision: https://developer.blender.org/D2388
Several somewhat self-compensating bugs in the routine that sorts
triangles around an edge let to a bug visible with a unit cube
subtracting a unit cylinder with 4 sides. Fixed.
The hardcoded age limit is now gone. The behavior can be implemented
with an Age Reached Event and Kill Particle node. Other utility nodes
to handle age limits of particles can be added later. Adding an
Age Limit attribute to particles on birth will be useful for some effects,
e.g. when you want to control the color or size of a particle over its
life time.
The Random Float node takes a seed currently. Different nodes will
produce different values even with the same seed. However, the same
node will generate the same random number for the same seed every
time. The "Hash" of a particle can be used as seed. Later, we'd want
to have more modes in the node to make it more user friendly.
Modes could be: Per Particle, Per Time, Per Particle Per Time,
Per Node Instance, ...
Also a Random Vector node will be useful, as it currently has to be
build using three Random Float nodes.
Find free slot first for sound strips then for movie strips.
This patch also fixes issue where all strips were added to channel 2 by default.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8339
As creator.c is used for the 'main' function,
avoid obscure declarations being placed so prominently.
- Move Blender as a Python module declarations into it's own section.
- Move USD declaration to an 'extern' just before it's called.
This fixes some "implement me" crashes and also case where one
moves a cutter completely inside the cut mesh.
Also fixed a bug in the implementation of mpq3::distance_squared.
Previously, there were only particle-birth and time-step events.
Now the solver can handle custom events. On the user level
this does not change anything yet. This feature of the solver
will be used by an upcoming Age Reached Event node and
possibly others. When this node exists, I can finally remove
the hardcoded maximum particle age.
The abbreviation 'init' is brief, unambiguous and already used
in thousands of places, also initialize is often accidentally
written with British spelling.
Yet another update to ensure that pointer variables are always up to date, i.e. those referencing the memory allocated by Mantaflow. Outdated pointers usually show up through flickering in viewport.
The weight must be added only to the real points, not to the autogenerated points by modifiers. This affects, not only to subdivide, but to any modifier that generate points.
In f2b04302cd the pointer update was refactored. It was sufficient to update pointers just in replay mode at the end of a step since the 'ensure()' functions from manta_fluid_API.cpp had their own pointer update call. These were removed in 51f4bee5a5, however, and so in order to still have some sort of update, the given update call needs to be available to all cache types.
Required for the new boolean code, disabled by default
until all platforms have landed the libs and the boolean
code actually lands in master.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8384
Caused by c7aa0f9d74.
Since above commit, BKE_image_user_frame_calc requires an image (not
just the iuser) to get the framenumber.
Cycles used to call this with NULL image (in `image_user_file_path` and
`image_user_frame_number`), now pass the image as well.
Maniphest Tasks: T79111
Differential Revision: https://developer.blender.org/D8439
A collection of multiple changes that had been living in my stash:
- Use nullptr instead of NULL in C++ files
- Removed unused/deprecated functions from headers
- Cleared animatable flag in cache UI
- Comment cleanups
Use static_cast() where possible and refresh pointers for every frame when in replay mode. The latter is particularly important as this seems to have caused the issue where smoke in the viewport was flickering when loading data from pointers after loading them from disk for the frame before (e.g. when resuming a bake job).
Add our own copy of the gtest discovery scripts from CMake a few reasons:
* Use the very latest version which supports PRE_TEST for Windows
* Fix usage of [] symbols in file paths that fail with the zsh shell
* Disable asan leak checker when discovering tests
This means Windows also no longer requires the very latest CMake 3.18.
The root of the issue comes to the fact that sub-data pointers were
used to match strips before/after copy-on-write. The undo system might
re-use sub-data pointers after re-allocating them, making it so that,
for example, pointer used by sound strip is later re-used by video
strip.
This fix takes an advantage of recently introduced per-sequence UUID
and uses it to match sequences before/after copy-on-write.
Will trigger code paths which makes sure UUIDs are generated and
are unique.
Enabled with --debug-depsgraph-uuid (which is also implied by
--debug-depsgraph).
This is the first step for having sequences covered with session UUID
with the goal to remove code which uses original sequence pointer to
match sequences.
Currently this UUID is maintained on file load, allocation and leaf
duplication function.There are more cases to cover and ensure UUID
is re-generated or re-used when needed. It will be done as follow-up
development.
Allows to use pre-defined structure for session UUIDs in all data
structures which needs it: pose channels, sequencer strips, modifiers.
The goal of all this is to have a reliable way of matching original
and copy-on-written versions of data, so that it's possible to
preserve runtime caches.
button
This was reported for the FCurve modifier restrict ranges, but might fail
elsewhere, too. Reason is that the post_but has its range (hardmin/
hardmax etc) set before the updates to the active button take place, so
changes here dont end up on the post_but (even though the RNA range
function is properly called for a new defined button - new one is not the
same as the post_but though).
Now update the ranges on the post_but when that gets active.
Fixes T78763
Maniphest Tasks: T78763
Differential Revision: https://developer.blender.org/D8265
These were added in rB146473f08335e8cb774ccaf1baad82a1d308fbe1 however
there were a few errors with the labels:
1. Underscore in label
2. Abbreviation when not needed
Needed careful logic about what to do with zero volume cells.
It worked before on some cases by accident, but now it should
work on any depth stack of coincident faces.
This bumps the minimum requirement for cmake from 3.10 to 3.18 on windows
if `WITH_GTESTS` is enabled.
Reviewed By: sergey brecht sybren campbellbarton
Differential Revision: https://developer.blender.org/D8405
Collection instance datablocks were not filtered out when only showing
the selected object. They were treated as a collection (which should
show when filtering objects). Adds a case to check if the parent is an
object.
This patch adds a new compound shape entry to the shape selection
dropdown. It also corrects wrong inertia calculation for convex hulls,
that resulted in strange behavior for small objects.
The compound shape take the collision shapes from its object children
and combines them. This makes it possible to create concave shapes from
primitive shapes. Using this instead of the mesh collision shape is
often many times faster.
Reviewed By: Sergey, Sebastian Parborg
Differential Revision: http://developer.blender.org/D5797
Description of `USER_HEADER_SEARCH_PATHS` build setting:
"
This is a list of paths to folders to be searched by the compiler
for included or imported user header files (those headers listed
in quotes) when compiling C, Objective-C, C++, or Objective-C++.
Paths are delimited by whitespace, so any paths with spaces in
them need to be properly quoted. See Always Search User Paths
(Deprecated) (ALWAYS_SEARCH_USER_PATHS) for more details
on how this setting is used. If the compiler doesn't support the
concept of user headers, then the search paths are prepended to
the any existing header search paths defined in Header Search
Paths (HEADER_SEARCH_PATHS).
"
http://help.apple.com/xcode/mac/current/#/itcaec37c2a6
Xcode doesn't use `HEADER_SEARCH_PATHS` for auto-complete. Only the
header files in the same directory as the current file are suggested.
CMake as of now correctly sets `SYSTEM_HEADER_SEARCH_PATHS` and lumps the
rest in `HEADER_SEARCH_PATHS`. The standard way is to use
`USER_HEADER_SEARCH_PATHS` & `SYSTEM_HEADER_SEARCH_PATHS` and let
`HEADER_SEARCH_PATHS` be used as a fallback for compilers which do not
distinguish between `<*.h>` and `"*.h"` syntax.
So set `USER_HEADER_SEARCH_PATHS` to the include paths specified
in the `CMakeLists.txt` files of all targets.
Caused by {rBa1a333a1e92e}
`BKE_sequencer_prefetch_get_original_sequence` cant get a sequence in
`BKE_sequencer_cache_put`.
rBa1a333a1e92e moved multiple NULL checks (including the one checking
seq) above BKE_sequencer_prefetch_get_original_sequence (this should
never return NULL really, but this is for another fix).
So solution suggested by @ISS is to just stop prefetching all together
before changing content of seqbase.
Maniphest Tasks: T79357
Differential Revision: https://developer.blender.org/D8421
- add the use of DRWShaderLibrary to EEVEE's glsl codebase to reduce code
complexity and duplication.
- split bsdf_common_lib.glsl into multiple sub library which are now shared
with other engines.
- the surface shader code is now more organised and have its own files.
- change default world to use a material nodetree and make lookdev shader
more clear.
Reviewed By: jbakker
Differential Revision: https://developer.blender.org/D8306
Previously, deform brushes were modifying the final positions in the
simulation directly, which was causing all sorts of artifacts in the
deformed area and problems with other features of the solver.
Now these brushes deform a separate array of positions and the solver
adds constraints to them, so the real vertices are moved when solving
the constraints. This prevents those artifacts and gives the brush a
much better behavior.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8424
The cloth brush builds the constraints when the stroke starts usign the
current state of the mesh. This means that deformations profuced by the
simulattion will accumulate after multiple strokes as it will always
start from the previous deformed state. While this is useful in many
cases, for other uses it is convenient to always simulate the same
initial shape, but applying different forces to it.
The persistent base options work like the persistent base in the layer
brush and allows the cloth brush to not accumulate deformation after
each stroke. When enabled, constraints are created for the shape stored
in the persistent base instead of from the current state of the mesh.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8428
Fix several issues in CLOG code:
* In `clg_str_reserve`, allocated memory may be bigger than requested
one, do not assign the latter back to `cstr->len_alloc`.
* `clg_str_vappendf` was mis-interpreting returned value from
`vsnprintf`, and completely mixing total allocated memory and extra
needed amount of memory to allocate...
Simplified code of `clg_str_vappendf` to only have allocating code
handled in one place, makes things easier to follow too.
Think this should also be beckported to 2.83.
This is part of T79273 where separating a stroke would result in
multiuser gpencil data for the original object.
Real underlying issue seems to be that gpencil multiuser objects (also
the ones created by Alt+D duplicating) have a problem evaluating
modifiers correctly [this will need further investigation].
Not sure if this is a limitation of D5470?
This patch only corrects the usercount on separating [which already fixes
the scenario reported because singleuser gpencil modifiers work
correctly].
Note: we could have also called `ED_object_add_duplicate` with the
`USER_DUP_GPENCIL` dupflag -- that would have taken care of the usercount
--, but then the whole following logic in `gpencil_stroke_separate_exec`
would need to change from **adding** layers/frames/strokes to
**removing** these.
Part of T79273
Maniphest Tasks: T79273
Differential Revision: https://developer.blender.org/D8419
This is in order to disolve GPU_draw.h into more meaningful code blocks.
All the Image related function are in `image_gpu.c`.
All the MovieClip related function are in `movieclip.c`.
The IMB module now has a connection with GPU. This is not strickly
necessary and the code could be move to `image_gpu.c` if needed.
The Image garbage collection is also ported to `image_gpu.c`.
This property adds constraints to the simulation using the initial
location of the vertices, making it behave like a soft body. The
strength of these constraints can be modified with the brush parameter.
This makes some deformation modes more subtle and predictable, making it
possible to use the cloth brush to add surface detail in a more
controllable way without loosing completely the original shape of the
mesh.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D7845
This uses mesh's runtime mutex for both `BKE_mesh_runtime_looptri_ensure`
(was using its own global RW mutex before), and `BKE_mesh_wrapper_ensure_mdata`
(was not protected at all before).
This is more like a band-aid than a proper fix, as mentioned in the report
proper fix would be for the modifier to request those data (the relevant
BVHTree, which would implicitely also call the tow others) through flags,
just like it does for regular CDData layers. But this is a much bigger
refactor to be done outside of bugfix scope.
Reviewed By: sergey
Maniphest Tasks: T78285
Differential Revision: https://developer.blender.org/D8415
Previously, gravity was only applied in the real brush radius, not in
the whole simulation radius. For most deformation modes, applying
gravity to the entire simulation instead of just to the brush radius and
scaled by the radius (like a regular sculpt brush) makes more sense.
After this fix and with the cloth collisions patch applied, it is possible
to do things like this with the cloth grab brush.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8406
As the comment says, anchored stroke can't rely on the first stroke
iteration for creating the simulation data. Probably lost in a cleanup.
I also made that anchored stroke doesn't restore the mesh state in the
cloth brush, so it can create the simulation effect.
Reviewed By: sergey
Maniphest Tasks: T79054
Differential Revision: https://developer.blender.org/D8348
The final render will use scene resolution in this case.
For example, when Color Input is plugger to preview and composite output
nodes, final render will flood-fill the final image which is a size of
scene resolution with this color. Before this fix the node preview was
empty. After this fix the node preview will be flood-filled with the
color.
Fixes T78586
Differential Revision: https://developer.blender.org/D8263
Were two issues:
- Divider was calculated in integer domain, causing rounding issues in
general case, and causing singularity in a corner case when input is
smaller than the preview size.
- The resolution was scaled down by 1 pixel for no obvious reason.
it's good to have an option to ' pin' a mode to the brush, to use that mode always, independent of the current viewport selected mode.
{F8723224}
Reviewed By: pepeland
Differential Revision: https://developer.blender.org/D8399
81a002
This was fine in those cases with current code, but that kind of
assumption is always risky, and an open door to hard-to-track bugs when
code changes in the future...
This is also a bit of code cleanup, reorganisation.
Tried to be DRYed but avoid too much code change to (hopefully) minimize
breakage.
- GPU: remove TEXTARGET_CUBE_MAP, this is no longer used in the codebase.
- GPUTexture: Move compressed texture upload to gpu_texture.cc
- GPUTexture: Add per texture Anisotropic filtering switch
Before, when extrude a point, the extruded point is considered as the first point of the stroke, but this was not logic.
Now, the extrude point is considered as last.
Related to T79313
Use 'emboss' instead of 'draw_type' as enum, layout & functions use
the term emboss.
This issue was noted by @Poulpator in D8414, as `dt` is also an
abbreviation for delta-time.
Build a temp matarray storing materials from obdata and source object
(depending on slots 'allocation' of source object), and assign those to
targets.
Also remove limitation of 'using same obdata is forbidden', just never
edit obdata materials in that case...
Certainly not perfect, but already much better than existing code.
The fisheye camera setup causes the edges of the image to not shoot primary rays. This was not
respected by OptiX because of an optimization that tried to reduce conditionals around trace calls.
Removing that does not seem to have an impact on performance anymore however and it fixes
the issue.
A face must have area in order to be possible calculate interpolation weights.
The same to the reference UVs.
But the new faces created with the extrude operator, have no area (before moving).
The solution was to get the loop data from some neighbor face.
Differential Revision: https://developer.blender.org/D8278
Keeping face attributes connected is now optional.
Keeping UV's connected is useful for organic modeling, but bad for
architectural.
Differential Revision: https://developer.blender.org/D8360
This bumps the minimally required CMake version from 3.5 to 3.10, as
discussed in D8405.
Since D7649 landed, there has been the `gtest_discover_tests()` call to
discover individual unit tests in `bin/tests/blender_test`. This
function was introduced in CMake 3.10.
Since there were no complaints about this incompatibility, I suspect
that a newer version is already in use by the majority of the
Blender-building people.
When an object is moved only by the rigid body physics system, the
function `BKE_object_moves_in_time()` will incorrectly return `false`.
This commit adds a comment to make this behaviour more explicit.
No functional changes.
The root cause was that `BKE_object_moves_in_time()` incorrectly returns
`false` when an object is moved by the physics system.
This also fixes the same issue in the USD exporter.
This was done for the regular dopesheet in rB9ccc73ade8a2, this just
makes that label consistent across all anim views.
Differential Revision: https://developer.blender.org/D8255
rna_EffectorWeight_path() needs to point to "domain_settings" (instead
of "settings"), was a missing change when switching the FluidModifier to
mantaflow.
Maniphest Tasks: T79264
Differential Revision: https://developer.blender.org/D8398
Setting the environment variable `PXR_PATH_DEBUG` non-empty will make the
USD library print the directories it uses to find its JSON files. This can
aid in debugging when this unit test fails. Now the failure message also
tells you about this.
No functional changes.
Move the common entries (View and Area) into a static method to be
called from other menus to avoid duplicating the New Collection and ID
Paste operators.
Previously, mesh boundaries were relaxed as any other vertex, which was
causing artifacts and unwanted deformation. In order to prevent this,
the mesh filter was using the automasking system to lock the boundary
vertices, which was hacked into the tool. For the brush, the only
solution was to enable boundary automasking to lock those vertices
in plance.
Now the relax vertex function slides the boundary vertices along the
mesh boundary edges, relaxing all the topology correctly while
preserving the shape of the mesh. The automasking hack in the relax
mesh filter was also removed as now vertices slide correctly along
the boundary.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8350
All these data arrays are created for a specific topology, so they should be
freed and updated when the PBVH rebuilds. Previously, this was only
happening when freeing the SculptSession, but it also needs to happen in
BKE_sculpt_update_object_before_eval to avoid reusing out of date data.
Reviewed By: sergey
Maniphest Tasks: T79074
Differential Revision: https://developer.blender.org/D8357
When there is no color layer available,
BKE_sculpt_update_object_for_edit creates a new one and tags the mesh
with ID_RECLAC_GEOMETRY, so this layer is inmediatly available when the
tool starts. This also deletes the PBVH and when it is created again in
BKE_sculpt_update_object_after_eval, the pmap is not initialized, making
the tool crash.
This moves the color layer creation to a separate function outside
BKE_sculpt_update_object_for_edit, which now runs after the color
layer is available, so it won't need to update again and the pmap will
still be available when the tool is used.
Reviewed By: sergey
Maniphest Tasks: T78242
Differential Revision: https://developer.blender.org/D8135
The buildbot uses a separate `CMAKE_INSTALL_PREFIX`. This means that
the unit test could not find its USD JSON files in the build directory.
Using `${CMAKE_INSTALL_PREFIX}` instead of `$<TARGET_FILE_DIR:blender>`
solved this.
This commit reverts the "noindex" part of the original commit.
using noindex made it imposible to link to a specific property.
The original warnings do not pose an issue so until a proper solution is
found I am reverting this commit.
This reverts commit 953c232db3
MSVC does need the wholearchive flag but it was not set,
so no tests were actually linked into the binary.
Reviewed By: sybren
Differential Revision: https://developer.blender.org/D8404
Some modes were working by mere chance in that ugly 'reversed' case, but
the to/from selection modes were not properly swapped...
Should also be safe for 2.83.
In the situation where the precompiled libraries are used on Linux +
GCC, a version of GCC older than 9.3 is guaranteed to cause problems.
This just implents a fatal error message when we know it doesn't make
sense to continue. We could do more checks and add some warnings, but
it's very likely that these will be ignored amongst the other noise.
Reviewed By: sergey, brecht
Differential Revision: https://developer.blender.org/D8396
The following nodes work now (although things can still be improved of course):
Particle Birth Event, Praticle Time Step Event, Set Particle Attribute and Execute Condition.
Multiple Set Particle Attribute nodes can be chained using the "Execute" sockets.
They will be executed from left to right.
Showing the Python error without any explanation is often
not enough information and doesn't hint that the error was in the
user input.
The error report from a invalid expression such as '..1' used to be:
('invalid syntax', ('<string>', 1, 1, '..1'))
Now reads:
Error evaluating number, see Info editor for details: invalid syntax
Address issue raised by T78913.
The result of syntax errors read poorly in reports,
resulting in cryptic and unhelpful information.
Change PyC_ExceptionBuffer_Simple only to extract the initial text,
making syntax errors when entering invalid numeric expressions into
buttons easier to follow.
This operator cleanup any frame that is equal to the previous one. This is very handy when convert a mesh animation to Gpencil and the mesh is static for several frames.
Differential Revision: https://developer.blender.org/D8149
This makes `RNANodeQuery::construct_node_identifier()` more strict in
its matching of certain property names.
The downside of this approach is that it's not possible any more to use
`"rotation"` and expect a match for `"rotation_euler"` and friends, so
the list of strings to test against is now 3x as long.
Reviewed By: sergey
Maniphest Tasks: T79121
Differential Revision: https://developer.blender.org/D8375
The complete lack of a transform panel was confusing enough to spawn
this question: https://blender.stackexchange.com/q/169074/599
Displaying a message instead of nothing is more consistent with the
behavior of the mesh transform panel anyway.
Reviewed By: Blendify
Differential Revision: https://developer.blender.org/D8390
New option that lets users the define the maximum number of fluid particles that will be allowed in the simulation. This can come in handy, for example, to ensure that the particle count will not exceed the hardware capabilities, or to avoid excessive amounts of particles in a scene.
New option that lets users the define the maximum number of fluid particles that will be allowed in the simulation. This can come in handy, for example, to ensure that the particle count will not exceed the hardware capabilities, or to avoid excessive amounts of particles in a scene.
This is handy to add support for enums used in both C and C++
files. This removes the need to typecast each time for every
operation.
Only support bitwise operators for now.
Operator logic is limited to iterating over selection and executing
same code as python API does.
Functional changes:
- No attempt to preserve effects is made. Dependant effects are deleted.
- No attempt to change meta strip boundaries.
Partially fixes T73828
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D6892
Add recursion check before assigning strip as a mask for modifier.
Same check is used for recursion check when reassigning effect input, so it
should not be possible to create recursion at all.
Sequencer was not initialized yet, and RNA update function tried to clean up cache.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8323
This operator automates the following steps:
1. Create a point cloud object.
2. Create a simulation data block.
3. Add a small particle simulation to the node tree.
4. Add a Simulation modifier to the point cloud object.
5. Reference the particle simulation from the modifier.
You have to go back to frame 1 to start the simulation.
The simulation is not yet cached and cannot be rendered.
The bounding box of the point cloud object is enabled for now,
because otherwise it is hard to select the object.
The OptiX kernels are compiled for target "compute_sm_52", which is only available on second
generation Maxwell GPUs, so disable support for older ones.
A particle action is some function that is triggered by some event.
Right now, users cannot control this. There is just a
randomize-velocity on-birth action. So the direction of spawned
particles is slightly randomized now.
This also adds a new integer attribute called "Hash" which is
useful for a number of things. Mainly for generating random numbers
for a specific particle. The ID of a particle is not necessarily a good source
of randomness.
Uses existing BMVerts, BMEdges, and BMFaces if possible.
Uses good examples for BMFaces for intersected faces.
Still todo: good examples for BMEdges when partially reusing an edge,
and UV interpolation for new faces.
commit aa8279648e
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 21:19:48 2020 +0200
Simulation: extract node tree parsing code to separate file
commit 25582aef61
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 20:51:52 2020 +0200
Simulation: separate code from node tree parsing and solver
commit 69d14c0ddb
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 17 15:18:54 2020 -0400
Fix T78959: Show current frame indicator when interface is locked
When the playhead drawing moved to an overlay, a check was added to keep
it from drawing with a locked interface. This is necessary for some overlays,
but not this one, so this removes the check, making it the responsibility of
the editor.
A context function is added to make that check easier in the future.
Differential Revision: https://developer.blender.org/D8313
commit 8b0df381d9
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Fri Jul 17 14:33:40 2020 -0300
Transform: use GHASH_ITER when restoring customdata
commit d8a6eec1a3
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 17 16:00:08 2020 +0200
Cleanup: Removed incorrect `// namespace DEG` comment
No functional changes.
commit 893eb30730
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Fri Jul 17 16:11:21 2020 +0200
Fluid: Numpy support for Mantaflow build system
Adjusted the fluid build system so that plugins that depend on numpy can be compiled as well.
Note that in this commit numpy support is still disabled. It can be enabled by re-running the Mantaflow update script with USE_NUMPY=1 and enabling WITH_MANTA_NUMPY in extern/mantaflow/CMakeLists.txt. This will happen in a future commit.
commit 0cdc75ccd2
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Fri Jul 17 15:58:13 2020 +0200
Fluid: Cleanup build system for extern mantaflow
No longer including unused dependencies. Should numpy IO be needed at some point, the Manta source update script can be configured so that the required dependencies are included again.
commit e3f8768d8a
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 14:23:57 2020 +0200
Refactor: move ParticleFunction to separate file
commit 2679236047
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 14:15:06 2020 +0200
Cleanup: avoid static initialization order issues when accessing CPPTypes
Instead of depending on static initialization order of globals use
static variables within functions. Those are initialized on first use.
This is every so slighly less efficient, but avoids a full class of problems.
commit 3ef59121a4
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 13:47:57 2020 +0200
Simulation: move initial simulation code from bf_blenkernel to bf_simulation
I removed bf_blenkernel from `nodes/CMakeLists.txt` again (added it yesterday),
because now this was causing me unresolved symbol errors... Without it, cmake
seems to link the libraries bf_simulation, bf_blenkernel and bf_nodes in the right
order. Not sure if that is just luck or if it is guaranteed.
It was possible to fix the issue by using cmakes `LINK_INTERFACE_MULTIPLICITY`,
but that is probably bad style.
commit 9582797d4b
Author: Jeroen Bakker <jbakker>
Date: Fri Jul 17 13:47:10 2020 +0200
Fix T77867: Link Duplicate Object crashes during batch creation
When using link duplicated objects it could happen that one object is
calculating the GPUBuffers and the second object is marking these
buffers invalid. This introduces threading issues.
This patch fixes this by combining the surface and surface per material
batches. Most likely the surface per material batches are used and when
requested you will most likely need the surface batch for the depth
tests and overlays.
During tests it slightly improves performance as batches aren't thrown
away without using it.
After this patch we can add a quick path for meshes with one material
and two materials.
Alternative approaches that have been checked:
- sync extraction per object: reduced performance to much (-15%)
({D8292})
- post checks: reduced the threading issues, but didn't solve it.
- separating preparation and execution of the extraction ({D8312})
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8329
commit bf2bb6db26
Author: Ankit Meel <ankitjmeel@gmail.com>
Date: Fri Jul 17 12:50:08 2020 +0530
Cleanup: silence unused variable warning
Reviewed By: fclem
Differential Revision: https://developer.blender.org/D8328
commit 0e3d34e48f
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 12:38:15 2020 +0200
BLI: add StringRefNull.c_str() method
This should be used whenever you rely on the fact, that the
returned pointer points to the beginning of a null-terminated array.
commit 0fcd23a388
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 12:28:09 2020 +0200
Simulation: use better api for adding and removing simulation states
commit c5f61fbf48
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 17 11:29:46 2020 +0200
Cleanup: avoid warning about redundant access specifier
No functional changes.
commit 5910dbdbf7
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 17 11:36:59 2020 +0200
Nodes: move some code from blenkernel directory to nodes
This also introduces the `blender::nodes` namespace. Eventually,
we want to move most/all of the node implementation files into
this namespace.
The reason for this file-move is that the code fits much better
into the `nodes` directory than in the `blenkernel` directory.
commit 0a40c671b0
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 17 17:11:32 2020 +1000
Cleanup: consistent ordering for scene argument to UV functions
commit 83e204702d
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 23:50:33 2020 +1000
Cleanup: remove f-string use in favor of percentage for formatting
commit 618f31312c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 17 17:35:46 2020 +1000
Fix vertex selection error from recent refactor
Temporary fix for regression in 8084b7e6e2.
commit 89a7a1c156
Author: Jeroen Bakker <jeroen@blender.org>
Date: Fri Jul 17 08:31:03 2020 +0200
Cleanup: extract draw cache sanity checks to own function
commit 608d9b5aa1
Author: Hans Goudey <h.goudey@me.com>
Date: Thu Jul 16 14:07:47 2020 -0400
UI: Add shortcuts for constraint panels
Only the delete shortcut applies here, although the move up and down
operators can optionally be assigned in the keymap.
See rB1fa40c9f8a81 for more details and rB5d2005cbb54b for the
grease pencil modifier panel implementation, which is the same.
Some refactoring of the constraint delete operator was necessary,
including adding an invoke function.
Differential Revision: https://developer.blender.org/D8238
commit b13bbb22e4
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 19:52:28 2020 +0200
Fix link error in bf_nodes
I got undefined reference errors on the `NodeMFNetworkBuilder::get_default_fn`
function under some circumstances. This symbol is definitely defined in bf_blenkernel.
The error seemed a bit undeterministic and was probably caused by some incorrect
link order. I don't get the error with this change.
commit 02a3720000
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 18:49:26 2020 +0200
Simulation: rename bf_physics to bf_simulation
Also see {rB9363c4de0635394548fa2eb8d205581313029775}.
commit 93f21ebb13
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Thu Jul 16 18:01:08 2020 +0200
Fluid: Update Mantaflow source files
Includes cleanup that resolves a -Wunused-but-set-variable warning.
commit e7c1a32a78
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Thu Jul 16 17:22:58 2020 +0200
Tests: disable ASAN when discovering tests
CMake, when it's configuring the project, runs the `blender_test` test
runner (if it exists from a previous build) to discover which tests it
contains. At this time none of the tests themselves are run, so it's not
that useful to run ASAN and have it break things when there are memory
leaks.
This commit disables ASAN by injecting `ASAN_OPTIONS="detect_leaks=0"` in
the environment variables.
It is not enough to use `set(ENV{ASAN_OPTIONS} "detect_leaks=0")` in
`tests/gtests/runner/CMakeLists.txt`, as it wouldn't be passed to the child
process.
commit a138bf57c9
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Thu Jul 16 16:10:53 2020 +0200
Tests: move tests from USD test directory into `io/common` and `io/usd`
This commit is a followup of {D7649}, and ports the USD tests to the new
testing approach. It moves test code from `tests/gtests/usd` into
`source/blender/io/common` and `source/blender/io/usd`, and adjusts the
use of namespaces to be consistent with the other tests.
I decided to put one test into `io/usd/tests`, instead of
`io/usd/intern`. The reason is that this test does not correspond with a
single file in that directory; instead, it tests Blender's integration
with the USD library itself.
There are two new CLI arguments for the Big Test Runner:
- `--test-assets-dir`, which points to the `lib/tests` directory in the
SVN repository. This allows unit tests to find test assets.
- `--test-release-dir`, which points to `bin/{BLENDER_VERSION}` in the
build directory. At the moment this is only used by the USD test.
The CLI arguments are automatically passed to the Big Test Runner when
using `ctest`. When manually running the tests, the arguments are only
required when there is a test run that needs them.
For more info about splitting some code into 'common', see
rB084c5d6c7e2cf8.
No functional changes to the tests themselves, only to the way they are
built & run.
Differential Revision: https://developer.blender.org/D8314
Reviewed by: brecht, mont29
commit 09a483a3aa
Author: Francesco Siddi <fsiddi>
Date: Thu Jul 16 17:10:15 2020 +0200
macOS: improve design of .dmg background
Differential Revision: https://developer.blender.org/D8300
commit 671c6d8afd
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 04:32:09 2020 +0200
Cleanup: Gizmo: Remove non matched glDisable
We use the polyline shader for drawing the rotation gizmo now.
This shader supports clipping without hardware clip planes.
commit 07d70a76df
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 04:31:29 2020 +0200
Cleanup: WM: Use GPUTexture API instead of raw ogl calls
commit 5099cbeec9
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 04:16:10 2020 +0200
Cleanup: GPU: Move depth/color masks functions to GPU_state
commit 436d38bb54
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 03:31:25 2020 +0200
Cleanup: GPU: Move XOR logic op to gpu_state.c
commit 3481f6eaf2
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 03:12:21 2020 +0200
Cleanup: GPU: Remove GL_DITHER usage
commit 71ac137662
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 03:01:07 2020 +0200
Cleanup: GPU: Move quad buffer stereo check to GPU module
commit 8084b7e6e2
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 02:50:55 2020 +0200
Cleanup: GPU: Replace all glReadPixels by GPU equivalent
commit ab19abe223
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 02:06:25 2020 +0200
Cleanup: Port glClear calls to GPU module functions
commit bc85081156
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Thu Jul 16 01:20:25 2020 +0200
Cleanup: DRW: remove uneeded double bind
Now that binds are permanent there is no need to setup the same
texture for each subgroups.
commit 56b8adb9e2
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 16:41:36 2020 +0200
Particles: avoid crash when connected unimplemented node
commit 1494ad20b9
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 16:33:20 2020 +0200
Particles: add implicit covnersions between Vector and Color
Not sure if these conversions are a good idea. However, we have them
in Cycles, so they be available in the simulation node tree for consistency
reasons.
commit 76bf050853
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 16:29:05 2020 +0200
Particles: simplify adding new implicit conversions between sockets
commit aa547ce88b
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Thu Jul 16 16:39:14 2020 +0200
Fluid: Update Mantaflow source files
Refactored various functions after noticing new warnings when compiling on Apple DTK devices - there should now be fewer warnings when building.
commit f64710a518
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 16:09:09 2020 +0200
Particles: change initial velocity of particles
This is only temporary, but makes testing the system a bit easier.
commit 4249d6f58e
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 16:08:18 2020 +0200
Particles: support Separate/Combine RGB nodes
commit ada173ebfd
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 15:54:18 2020 +0200
Particles: simplify Combine XYZ node
commit 72df7c23c4
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 15:49:56 2020 +0200
Particles: support Color Ramp node
commit c7aa0f9d74
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 16 14:54:45 2020 +0200
Fix T78537: too much memory usage rendering animation with persistent images
For still images, always return 0 for the current frame number. This ensures
Cycles can detects that the image did not change.
Based on patch by Vincent Blankfield.
Differential Revision: https://developer.blender.org/D8242
commit 279cc34343
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 23:44:38 2020 +1000
Keymap: disable 'Alt' click for tools prompt by default
Based on feedback from artists in the Blender Studio this is too
easy to access by accident.
This is still accessible as a preference.
commit 83955d6769
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 13:25:57 2020 +0200
Particles: support Map Range node
Only linear interpolation mode is supported for now.
commit 99fda4d31e
Author: Ray Molenkamp <github@lazydodo.com>
Date: Thu Jul 16 07:22:52 2020 -0600
deps builder: Fix typo in windows harvesting
commit 9b6088cb9d
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 14:37:21 2020 +0200
Simulation: Change BPH prefix to SIM
In a previous commit the `physics` folder has been renamed to `simulation`.
This commit updates the function/file prefix accordingly.
commit 9363c4de06
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 14:27:47 2020 +0200
Simulation: Rename `physics` directory to `simulation`
Function names will be updated in a separate commit.
This will be the place for the new particle system and other
code related to the Simulation data block. We don't want
to have all that code in blenkernel.
Approved by brecht.
commit 66b48ad8fb
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 16 12:47:28 2020 +0200
Fix git tag warning when running make update after recent changes
commit f3ea6a5b28
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 14:15:12 2020 +0200
Particles: implement more vector math operations
commit 3d8f8085fb
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 18:53:41 2020 +1000
UI: show connected icon for proportional editing in the image space
commit b882f89fe3
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 13:41:47 2020 +0200
Particles: support for most math node operations
commit 2ddb3dc617
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 13:38:23 2020 +0200
Nodes: support default function for partially implemented nodes
commit 56aa5b0d8c
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Thu Jul 16 12:58:49 2020 +0200
T73268: Link C/C++ unit tests into single executable
This commit introduces a new way to build unit tests. It is now possible
for each module to generate its own test library. The tests in these
libraries are then bundled into a single executable.
The test executable can be run with `ctest`. Even though the tests
reside in a single executable, they are still exposed as individual
tests to `ctest`, and thus can be selected via its `-R` argument.
Not yet ported tests still build & run as before.
The following rules apply:
- Test code should reside in the same directory as the code under test.
- Tests that target functionality in `somefile.{c,cc}` should reside in
`somefile_test.cc`.
- The namespace for tests is the `tests` sub-namespace of the code under
test. For example, tests for `blender::bke` should be in
`blender::bke:tests`.
- The test files should be listed in the module's `CMakeLists.txt` in a
`blender_add_test_lib()` call. See the `blenkernel` module for an
example.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D7649
commit 065a00ee3e
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jul 14 16:31:54 2020 +0200
Fix T78920: missing depsgraph relation when using sound strips in VSE
Having a sound strip in the VSE caused a missing relation error to be
logged on the console. This was caused by the AUDIO depsgraph component
not having an entry node. This commits adds that node, and sets up
relations correctly.
Differential Revision: https://developer.blender.org/D8290
Reviewed By: Sergey
commit d4ce777aed
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 11:33:35 2020 +0200
BLI: move inline include to the bottom to avoid redeclaration warning
commit d897228682
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 11:28:31 2020 +0200
BLI: move safe math functions to separate header
commit f6f93b5b12
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 11:05:13 2020 +0200
BLI: add safe_divide, safe_modf and safe_logf
Those are defined exactly as their corresponding functions in Cycles.
commit 7e0bf7a0f1
Author: Bastien Montagne <bastien@blender.org>
Date: Thu Jul 16 11:03:11 2020 +0200
LibOverride: Fix getting proper RNA path and ID from embedded ones.
Master collections and root node trees should now be working as expected
in that regard.
commit 35bfe1702c
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 16 10:46:18 2020 +0200
BLI: add safe_powf function
The same function is also used by cycles.
commit 4a9d903e2b
Author: Yevgeny Makarov <jenkm>
Date: Thu Jul 16 18:06:51 2020 +1000
Fix View3D "Mirror" menu, both "Global" and "Local" items are GLOBAL
commit 9715ad5aca
Author: Stefan Werner <stewreo@gmail.com>
Date: Thu Jul 16 09:25:55 2020 +0200
macOS: Support arm64 architecture.
Enabling all `make deps` dependencies with the exception of Embree and OIDN.
After that, Blender can be compiled on an Apple Silicon Mac just like on any
Intel based Mac. There are still compiler warnings that need to be
investigated and there are probably a couple of bug still to be discovered
and to be fixed.
Most patches to the dependencies are simple and are about disabling SSE and
setting the proper architecture to compiile for. Notable exception is Python,
where I back ported a yet to be accepted PR for upstream Python:
https://github.com/python/cpython/pull/21249
Cross compiling or buliding a Universal Binary is not supported yet.
The minimum macOS target version for x86_64 remains at 10.13, the target
for arm64 is 11.00.
Differential Revision: https://developer.blender.org/D8236
commit ad4928a171
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 17:00:16 2020 +1000
UI: avoid aligning labels for ui_item_with_label
Key-map display was doing thousands of redundant alignment operations.
Set the spacing instead as align was only set to use zero spacing.
This would have prevented the crash reported by T78636.
commit 75520894c7
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 16:32:55 2020 +1000
Fix T78636: Crash displaying many aligned buttons
Displaying user preferences search crashed on macOS when the search
contained a common character such as 'E'.
This caused alignment to 'alloca' too much memory.
Replace with a heap allocation fallback.
commit 2811de6e5c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 13:48:01 2020 +1000
Cleanup: fix building without USE_UIBUT_SPATIAL_ALIGN defined
commit 5b099a25d7
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 13:27:50 2020 +1000
Fix T78966: Center cursor doesn't refresh the UI
commit 123e29c274
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 13:17:31 2020 +1000
Cleanup: missing CMake headers from source lists
commit 54abab53bf
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 11:07:36 2020 +1000
Cleanup: undeclared function warning, unused argument
commit a3d90337b8
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 10:58:33 2020 +1000
Cleanup: spelling
commit d11a2dfe71
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 16 10:44:37 2020 +1000
Cleanup: minor change to grease pencil material access
Rename for clarity and avoid passing in the prefix length.
commit 75a09ba2ed
Author: Richard Antalik <richardantalik@gmail.com>
Date: Thu Jul 16 02:24:37 2020 +0200
Fix T78837: Prefetching can corrupt .blend files
This happened because of typo in seq_dupli() when duplicating effect data.
Instead of duplicating data to new sequence, it was duplicated into original.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8295
commit 974e36d7d0
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 21:05:50 2020 +0200
Fix T78647 UVEdit: Crash when entering edit mode with UV Editor open
Only affects MacOS.
commit 058514aa0a
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 20:10:45 2020 +0200
PointCloud: Initial rendering support for Workbench
Also includes outline overlays. Removes the temp overlay drawing
We make the geometry follow camera like billboards this uses less
geometry. Currently we use half octahedron for now. Goal would be
to use icospheres.
This patch also optimize the case when pointcloud has uniform radius.
However we should premultiply the radius prop by the default radius
beforehand to avoid a multiplication on CPU.
Using geometry instead of pseudo raytraced spheres is more scalable as
we can render as low as 1 or 2 triangle to a full half sphere and can
integrate easily in the render pipeline using a low amount of code.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8301
commit d4d810f817
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Mon Jul 6 21:15:36 2020 +0200
Cleanup: EEVEE: Remove concentric samples.
commit 37a8c6d809
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Mon Jul 6 21:06:16 2020 +0200
Cleanup: EEVEE: Remove unused IRRADIANCE_CUBEMAP
commit 47885abbe6
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 16:41:30 2020 +0200
Workbench: Replace viewvecs caculation by DRWView
commit cd8f3c9ee7
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 16:38:44 2020 +0200
DRW: Add glsl math libraries
Copied from eevee bsdf_common_lib.glsl
commit 2c1edcf3ef
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 15:01:59 2020 +0200
EEVEE: Fix undefined behavior in world output
commit 24c846b2b4
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 14:59:52 2020 +0200
GPU: Shader: Move IN_OUT define to shader GPU_shader_create_ex
This adds the opportunity to use it in multiple places.
commit 987d14a3b2
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 14:40:28 2020 +0200
DRW: Shader: Fix const correctness and print better debug output
commit 8e16873086
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 14:39:29 2020 +0200
DRW: Shader: Add DRW_shader_create(_fullscreen)_with_shaderlib
Some convenience function for using DRWShaderLibrary.
commit 5dcf60e053
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Wed Jul 15 14:35:57 2020 +0200
DRW: View: Add ViewVecs calculation
This will remove some code duplication between draw engines.
commit f1104c2828
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Wed Jul 15 18:52:01 2020 +0200
Fix T78369: Sculpt Vertex Colors not rendering in EEVEE
The vertex colors node was using the M_COL attribute type but Sculpt
Vertex Colors use CD_PROP_COLOR
Now the Vertex Color node also fallbacks to legacy vertex colors if
Scultp Vertex Colors are not enabled as experimental.
Reviewed By: brecht
Maniphest Tasks: T78369
Differential Revision: https://developer.blender.org/D8185
commit eb54624a9a
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 15 18:10:55 2020 +0200
LibOverride: make outliner's 'override hierarchy' use same logic as 3DView operator.
So now one can create a 'full', 'complete' override of a character from
the outliner as well.
commit 5057b28a2f
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 15 18:09:30 2020 +0200
LibOverride: move most of 'complete override creation' from ED_object to BKE_lib_override.
This code is fairly complex and can be used in more places, better not
duplicate that logic and just have it in BKE area.
commit ba100c883c
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 15 18:07:56 2020 +0200
BKE collection: add util to add a collection using another collection as 'template'.
Similar to what we already had using an object as 'template'.
commit a082e49671
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 15 15:51:13 2020 +0200
Cleanup: remove debug prints.
commit cda6da4957
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 15 18:14:03 2020 +0200
Fix error in recent commit
Obviously a copy paste error of mine...
commit ae4098e234
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Wed Jul 15 17:25:07 2020 +0200
GPencil: Fix unreported error baking mesh animation
When the mesh is linked, the materials can not be available or be the same assigned to mesh. Now, if the mesh is linked, a simple two materials conversion is used.
To get the full list of materials, the mesh must not be linked.
Also checked some indexes to be sure never get a wrong value and that materials are not created again and again.
commit 36e836d0e9
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Wed Jul 15 17:03:51 2020 +0200
Fluid: Adjusted Mantaflow version number
Version number was increased after recent OpenVDB IO changes.
commit 19d17b217a
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 15 16:48:30 2020 +0200
Particles: use CD_PROP_FLOAT3 instead of CD_LOCATION
`CD_LOCATION` was only used temporarily due to the lack
of a better alternative. This also removes the name from
`CD_LOCATION` again, because at most one layer of this
type should exist.
commit 57ec1f37e9
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 15 16:42:17 2020 +0200
CustomData: add float2 and float3 data types
This adds `CD_PROP_FLOAT2` and `CD_PROP_FLOAT3`.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D8251
commit e06a346458
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Wed Jul 15 16:24:03 2020 +0200
Fix T78747: Fix mesh boundary detection and automasking
This issue was produced by a hack in the sculpt mode code from 2.80
when the sculpt API for connectivity info was not available.
The smooth brush was the only brush that needed connectivity info,
so there were 3 different smooth functions with the connectivity
queries implemented for dyntopo, meshes and grids. The mesh version
of smoothing was checking the number of connected faces to a vertex
to mask the mesh boundaries, which was not covering all cases and
was hardcoded in the smooth function itself.
This patch removes all those legacy functions and unifies all
smooth functions into a single one using the new API and the
automasking system. In order to achieve this, there were needed
some extra changes:
- The smooth brush now does not automasks the boundaries by default,
so its default preset needs to be updated to enable automasking
- The mesh boundary info is extracted once and cached in a
bitmap, similar to the disconnected elements IDs. This makes
boundary detection work as expected in all cases, solving a lot
of known issues with the smooth brush. In multires, this info is
extracted and cached only at the base mesh level, so it is much
more memory efficient than the previous automasking system.
- In order to keep the brushes responsive as they were before,
the automasking system can now skip creating the cache when it
is not needed for the requested options. This means that for
high poly meshes and simple automasking options the brushes
won't lag on start.
Reviewed By: sergey
Maniphest Tasks: T78747
Differential Revision: https://developer.blender.org/D8260
commit 10cacbbb15
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Tue Jul 14 23:15:13 2020 +0200
Fix T77417: Topology Automasking not working with individual vertices
The flood fill operation was setting the mask using to_v, so in the first
iteration when the floodfill callback was using the active vertex as
from_v and any other neighbor as to_v, the mask for the active vertex
was never set.
Now the mask is set using from_v and it checks if it should continue
propagating to the next neighbor using to_v.
Reviewed By: sergey
Maniphest Tasks: T77417
Differential Revision: https://developer.blender.org/D8294
commit 613d314251
Author: Campbell Barton <ideasman42@gmail.com>
Date: Wed Jul 15 17:35:57 2020 +1000
UV: support region fill for path select
This matches edit-mesh region selection (Ctrl-Shift-Select).
commit b3c34011c0
Author: Hans Goudey <h.goudey@me.com>
Date: Wed Jul 15 09:11:01 2020 -0400
Cleanup: Replace 0 with False for boolean argument
commit efc6f6e1ae
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 15 14:23:51 2020 +0200
Clang-Tidy: ignore some newer checks
Those checks have been added to clang tidy within the last year.
They fail when I use a clang tidy version I built from source.
Reviewers: sergey
Differential Revision: https://developer.blender.org/D8302
commit 5a11c8ba24
Author: Campbell Barton <ideasman42@gmail.com>
Date: Wed Jul 15 21:48:28 2020 +1000
Fix T68845: Follow Active Quads, divide by zero error
commit 87f8949f0e
Author: Brecht Van Lommel <brecht@blender.org>
Date: Wed Jul 15 13:37:13 2020 +0200
Fix T78930: Cycles OpenCL error on graphics cards that don't support half float
commit 44bb73e765
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Wed Jul 15 08:10:41 2020 -0300
Revert "Cleanup: simplify Weld Modifier logic"
This reverts commit 98b1a716d6.
That commit broke a few modifiers.py tests
(Screw+Weld and a weld merge threshold).
And some pairs may be lost in the first loop.
commit ff2fa59689
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 15 12:45:40 2020 +0200
Fix T76690: Incorrect liquid particle count displayed
Reviewers: sergey, sebbas
Differential Revision: https://developer.blender.org/D7852
commit 4e8fc14120
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Wed Jul 15 12:47:45 2020 +0200
GPencil: Fix name typo error
commit 7e2ffbfb25
Author: Sebastian Parborg <darkdefende@gmail.com>
Date: Wed Jul 15 12:36:48 2020 +0200
Add missing NULL assignment to D8293
Missed reseting "next_td" in that patch.
Shouldn't have caused any issues in practice, but it is nice to be
extra clear and safe in the code.
commit 50c6448781
Author: Sebastian Parborg <darkdefende@gmail.com>
Date: Wed Jul 15 12:28:32 2020 +0200
Fix T78909: Curve-edit proportional connected-only broken
Now it calculates the actual distance when traveling along the curve.
I addition to this, it also now supports cyclic curves.
Reviewed By: Campbell
Differential Revision: http://developer.blender.org/D8293
commit e8b26a0501
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 15 11:06:37 2020 +0200
Fix signed/unsigned comparison
commit 680a81fc49
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 15 10:58:54 2020 +0200
LibOverride: rework 'make override' 3DView operator.
Removed the 'select main object to override' menu when overriding an
instanced collection, this was no more used anyway.
Added new behavior allowing to select which directly linked collection
to override when trying to override an inderctly linked object. This
allows to link collections without instancing them with an empty object,
select one of their objects, and call override operator.
commit eb87b1c8f6
Author: Campbell Barton <ideasman42@gmail.com>
Date: Wed Jul 15 15:37:03 2020 +1000
Cleanup: remove assignment from a NULL struct
Quiet ASAN 'member access within null pointer' warning.
While this doesn't crash, access to 'shading'
without checking if the 'v3d' would have.
commit 920b138f83
Author: Liam Scaife <Voltist>
Date: Wed Jul 15 15:19:21 2020 +1000
UI: Add manifold extrude to extrude menu
commit e062def3b4
Author: Campbell Barton <ideasman42@gmail.com>
Date: Wed Jul 15 13:11:22 2020 +1000
Cleanup: spelling
commit 061d76f55c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Wed Jul 15 13:09:06 2020 +1000
Revert "Cleanup: remove public unused function."
This reverts commit 03c8b048a1.
This commit re-introduced T76837.
While there is a comment explaining why this function is needed,
the naming of the poll function does make this confusing.
The API could be changed to avoid confusion here.
commit d493fc43bd
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 14 17:45:31 2020 -0300
Fix T78875: Numerical display of delta of translation is not updating in 3d view
commit 7f67e3200a
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Tue Jul 14 22:16:43 2020 +0200
Fluid: Fix liquid mesh scaling
Fixes issue with .bobj.gz and .obj mesh files not always being scaled correctly in the viewport.
commit 7e0289b618
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Tue Jul 14 22:15:00 2020 +0200
Fluid: Updated Mantaflow source files
New files include fixes for obj mesh import and minor cleanups.
commit 98b1a716d6
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 14 15:18:03 2020 -0300
Cleanup: simplify Weld Modifier logic
The original code to rearrange the weld vertices map was confusing.
It traverses the overlap result multiple times within a loop.
This part of the code has therefore been rethought, simplified and commented.
This also results in a slight improvement in the performance of the modifier.
commit dbcc74f801
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Tue Jul 14 18:11:28 2020 +0200
Fix T77263: Mantaflow: Cache gets deleted at changing upres factor under Particles section.
Moved fluid simulation reset to separate functions based on type.
commit 0b100e21fb
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 13 14:19:13 2020 +0200
Fix T78704: RenderPass normals disapear when view isn't updated
When the view isn't updated the renderpass thought that it was rendering
the next sample, skipping the conversion from encoded to blender
normals.
This patch resets the current sample when only rendering single sample
layers.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8280
commit 6cc88e330b
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 08:41:28 2020 +0200
Fix T78431: Update mesh_cd_layers_type_ to support 8 bytes.
Sculpt vertex colors changed the `DRW_MeshCDMask` from 4 bytes to 8 bytes, but
the functions assumed it still was 4 bytes. This patch updates the functions and
adds a compile time check.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8215
commit 2ba1cf4b40
Author: Sebastian Parborg <darkdefende@gmail.com>
Date: Tue Jul 14 17:26:13 2020 +0200
Fix T78880: UV Editor - Match prop edit connected behavior with mesh editing and fix Rip Region double proportional checkbox
This fixes the double prop edit checkbox in the redo menu.
This also makes it so that proportional edit in connected mode now
matches how it behaves in mesh edit mode.
Without this change, ripping in UV edit mode with proportional edit on
would be useless as the UV verts you ripped will still be stuck together
even if they were not connected anymore.
Reviewed By: Campbell
Differential Revision: http://developer.blender.org/D8289
commit 797027be6b
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Tue Jul 14 16:30:01 2020 +0200
Fluid: Fix missing flag update for cache
These flags need to be set correctly in order to distinguish between data that comes from cache files and raw data that comes directly from pointers to the data in Mantaflow.
commit 14eaa9ed63
Author: Bastien Montagne <bastien@blender.org>
Date: Tue Jul 14 16:03:12 2020 +0200
LibOverride: fix for removing `use_override_library` in rB3d587efef2872.
Thanks to @JacquesLucke for the heads up.
commit 8e9dd5492a
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Tue Jul 14 15:59:40 2020 +0200
Gpencil: Simplify modifier sample mode minimal vert count fix.
For this mode is possible use strokes of 2 points.
Differential revision: https://developer.blender.org/D8138
commit c8a62e4f50
Author: Bastien Montagne <bastien@blender.org>
Date: Tue Jul 14 15:27:41 2020 +0200
Cleanup: function name not following its module conventions.
commit 6068f49c33
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 14 15:20:44 2020 +0200
BLI: remove static assert noexcept move constructors
The move constructor of `mpq_class` from GMP currently
allocates when it is moved. So, it cannot be noexcept.
Since we want to use this type, this static assert cannot
stay there.
commit 2e8a78f4d1
Author: Kévin Dietrich <kevin.dietrich@mailoo.org>
Date: Mon Jul 13 18:26:48 2020 +0200
Fluid bake: fix memory leak when path validation fails
Reviewed By: sebbas
Differential Revision: https://developer.blender.org/D8284
commit 78148e20fa
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 14 22:47:18 2020 +1000
Cleanup: remove tab indention
commit fa7ace2215
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 14 22:45:33 2020 +1000
PyAPI: support element multiplication for vector, matrix, quaternions
This was disabled during 2.8x for smooth porting of 2.7x scripts,
Now '@' is used for matrix multiplication,
support '*' to multiple vector elements.
See T56276.
commit e3fd60b182
Author: Bastien Montagne <bastien@blender.org>
Date: Tue Jul 14 14:49:59 2020 +0200
LibOverride: Outliner: Add an operation to override the selected ID and its parents.
This will override all linked data-blocks in the tree branch leading to
the selected one.
commit 140b26909e
Author: Bastien Montagne <bastien@blender.org>
Date: Tue Jul 14 11:38:25 2020 +0200
LibOverride: Move code tagging reauired dependencies of an override into BKE.
This is fairly generic code that can be re-used in other places.
commit 1e5ce39156
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 14 09:30:54 2020 -0300
Fix T78900: Single vertex sliding crashes
As we can see in `initVertSlide_ex`, `sld` can be `NULL`.
`sld` is dereferenced, but can still be `NULL`.
commit 01ec76842f
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 14 13:47:32 2020 +0200
Fix T77766: support animated global gravity toggle
Reviewers: sebbas
Differential Revision: https://developer.blender.org/D8281
commit 4096330b81
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 14 13:01:46 2020 +0200
Cleanup: typo
commit 25fc84bf2e
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 14 10:42:35 2020 +0200
Fix wrong vector size functions used in knife tool
Should not use copy_v3_v3 on a 2 element vectors.
commit 26793d619c
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Tue Jul 14 10:26:19 2020 +0200
GPencil: Cleanup Build modifier and fix potential div by zero errors
commit 0fb08b7cc4
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 14 16:04:18 2020 +1000
Cleanup: sort header, cmake paths
commit 93e14e5935
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 14 15:53:56 2020 +1000
Fix T78883: New bezier curve points to uninitialized memory
commit 5338b36fcc
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 14 15:19:52 2020 +1000
Cleanup: spelling
commit b818f6b55f
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 13 20:10:49 2020 -0400
Fix T78902: Only check main modifier panel for expansion property
Internally the "show_expanded" property stores the expansion for every
subpanel, but for RNA we should only check the first bit of the flag that
corresponds to the main panel.
commit 0b24930541
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 13 17:16:01 2020 -0400
UI: Add missing row in curve profile template
commit 37fb586a0b
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 13 16:10:45 2020 -0300
Cleanup: remove unnecessary member
`Kfv-> sco` was being treated as a local variable, and can be
confusing since this value is not updated when navigating the viewport.
commit 70992ae270
Author: Ray Molenkamp <github@lazydodo.com>
Date: Mon Jul 13 12:29:53 2020 -0600
Fix: Fix build error with MSVC in BLI_span_test
span.size() returns an uint, causing a signed/unsigned comparison
using 3u sidesteps the issue
commit 6e74a8b69f
Author: Brecht Van Lommel <brecht@blender.org>
Date: Mon Jul 13 16:45:15 2020 +0200
Fix T78881: Cycles OpenImageDenoise not using albedo and normal correctly
Properly normalize buffers now. Also expose option to not use albedo and normal
just like OptiX.
commit 2b5e21fe00
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Sat Jul 11 00:19:45 2020 +0200
Sculpt: Add extra deform types to Smear
The smear brush was using the stroke direction to slide colors across
the mesh surface (this is called drag in other sculpt tools). Similarly,
other deformations can be included. The most common ones in image
editing are pinch and expand, which can be used to sharpen transitions
between colors.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8270
commit 1076952209
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Fri Jul 10 23:00:21 2020 +0200
Fix wrong variable name in Sculpt Vertex Colors experimental check
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8269
commit eb3f74a0fe
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Fri Jul 10 19:43:01 2020 +0200
Sculpt: Enable color palettes for sculpt vertex colors
Enables the color palette subpanel for brushes that have color
capabilities (only the paint brush for now)
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8268
commit 8dd2386a68
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 17:43:22 2020 +0200
IDTemplate: Minor tweak to 'make local/override' code.
Only update pointer of the template if we actually changed it...
commit fcc91faf3f
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 17:02:58 2020 +0200
Fix (unreported) bad handling of undo for some IDTemplates operations.
commit 91e67c7bda
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 16:55:39 2020 +0200
Cleanup: remove some incorrectly placed consts
Clang-tidy reported that those parameters could be const,
but that is not true on windows.
commit 3d587efef2
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 16:44:41 2020 +0200
LibOverride: Cleanup: Remove option to disable library overrides.
Code is mature enough now to not need this anymore, people who do not
want to use liboverrides can just not create them.
commit 5c8dd2a703
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 13 11:40:14 2020 -0300
Cleanup: silence warnings
commit 3dcc7c73e2
Author: Ray Molenkamp <github@lazydodo.com>
Date: Mon Jul 13 08:38:31 2020 -0600
MSVC: Fix build error with the 8.1 SDK
shobjidl_core.h only exists in the windows 10 SDK in the 8.1
SDK ShObjIdl.h will have the definitions we need, which still
exists in the 10 SDK and implicitly includes shobjidl_core.h.
so ShObjIdl.h will work on both SDK versions.
commit 29da019cb3
Author: Szymon Ulatowski <szulat>
Date: Mon Jul 13 17:02:19 2020 +0200
EEVEE: Fix sky zenith bug
Careless use of acos() in spherical coordinates transformation was
deteriorating the precision near zenith (and nadir) and producing
glitchy pixels (best seen in longer focal lengths).
Reviewed By: fclem
Differential Revision: https://developer.blender.org/D8266
commit 16989c4d1d
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 16:15:52 2020 +0200
Fix T78037: fresh install of blender 2.83.0 not able to save user startup file.
Simply remove that check ob userdef's themes, we are never read any
userdef from startup file anymore, so this check makes no more sense.
To be backported to 2.83.
commit 952279a366
Author: Sebastián Barschkis <sebbas@sebbas.org>
Date: Mon Jul 13 16:09:24 2020 +0200
Fix T76687: [Mantaflow] low domain transformation performance
Implemented G.moving suggestion from comments.
commit 5ecefc6a07
Author: Brecht Van Lommel <brecht@blender.org>
Date: Mon Jul 13 15:42:47 2020 +0200
Build: make update support for git tags
Previously it only picked the appropriate version with the
blender-vX.XX-release branches.
commit 2be7a11e43
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Mon Jul 13 15:26:00 2020 +0200
Python API: new RNA property `Screen.is_scrubbing`
This commit adds a new read-only boolean property `Screen.is_scrubbing`.
The related property `Screen.is_animation_playing` is set to `True` in
two situations:
- Animation is actually playing (for example via the Play button in the
timeline)
- The user is scrubbing through time (in the timeline, dopesheet, graph
editor, etc.)
To distinguish between these two cases, the property
`Screen.is_scrubbing` has been added.
Concept approved by @brecht.
commit b9f565881e
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Mon Jul 13 15:02:25 2020 +0200
VSE: Python API, allow creation of VSE Movie strips with missing file
It was already possible to create Sound and Image strips that reference
non-existing files. Now it's also possible to create Movie strips
referencing missing files via the Python API call
`Sequences.new_movie()`. In this case, the duration of the strip will be
set to 1 frame.
Note that this commit does not change anything in the user interface.
The Python API of the `MovieStrip` class is extended with a function
`reload_if_needed()`. This function only performs disk I/O if the movie
strip cannot produce frames, that is either when its filepath points to
a non-existing file, or when the video sequence editor has not been
shown yet (for example because it is in an inactive workspace).
This allows for the following:
```
import bpy
scene = bpy.context.scene
vse = scene.sequence_editor_create()
filepath = bpy.path.abspath('//demo.mkv')
strip = vse.sequences.new_movie("movie", filepath,
channel=2,
frame_start=47,
file_must_exist=False)
strip.frame_final_end = 327
```
This will create a new movie strip, even when `demo.mkv` does not exist.
Once `demo.mkv` has appeared at the expected location, either
`strip.reload_if_needed()` or `strip.filepath = strip.filepath` will
load it.
Differential Revision: https://developer.blender.org/D8257
Reviewed By: Sergey, ISS
commit 9db0c36af1
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 14:29:04 2020 +0200
LibOverride: add more polling checks to operators not supposed to work on overrides.
This is long work, we are still likely missing a lot of cases...
commit 03c8b048a1
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 14:15:57 2020 +0200
Cleanup: remove public unused function.
commit 9c9eb03d78
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Sun Jul 12 21:47:50 2020 -0300
Fix T78855: Knife tool crashes when the geometry has no face
I don't see the need for a BVH Tree to have root but not have leafs.
But apparently this case is possible.
commit f019164f1f
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Sun Jul 12 21:13:05 2020 -0300
Optimization: Use dedicated function to restore customdata
Called when canceling a transform operation.
commit 8074a18964
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Sun Jul 12 21:01:54 2020 -0300
Cleanup: move unchanged condition out of loop
commit 7b558a20a9
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Sun Jul 12 20:53:22 2020 -0300
Fix Extrude Manifold losing original UV
commit 976a0ff691
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 12:48:56 2020 +0200
RNA code cleanup: Fix wrong usages of `rna_idproperty_check()`.
This function is more expansive than the simpler `rna_ensure_property()`
one, and should only be used when IDProperty data is actually needed.
If one only needs to ensure it has a valid PropertyRNA pointer,
`rna_ensure_property()` is much more efficient.
Also add compiler warnings when results of those functions are unused,
this should never be the case.
commit f8afbb7657
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 12:47:49 2020 +0200
RNA property management: tweak to 'is set' information.
Only consider a full IDProperty as set if it actually exists in given
PointerRNA data.
commit 0158571b34
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 13 12:46:29 2020 +0200
I18n utils: fix broken case when 'settings' argument is default NULL one.
commit 7453ff73ad
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 12:48:46 2020 +0200
Cleanup: quiet warnings by adding const in some places
The warnings were introduced in rB725973485a909c2b732c5.
commit 725973485a
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 11:27:09 2020 +0200
Clang Tidy: enable readability-non-const-parameter warning
Clang Tidy reported a couple of false positives. I disabled
those `NOLINTNEXTLINE`.
Differential Revision: https://developer.blender.org/D8199
commit a19584a471
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 10:51:46 2020 +0200
BLI: fix constructor regression for Vector and Array
This was introduced in rB403384998a6bb5f428e15ced5.
commit 644a915b1b
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 10:49:59 2020 +0200
BLI: don't allow mutable span of initializer list
commit 0718c6fae0
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 10:40:05 2020 +0200
Cleanup: fix clang tidy warning
The code was actually correct, but clang tidy complaint about
using the Vector after it was moved from.
commit 91c763af3e
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 13 10:34:44 2020 +0200
Cleanup: typo
commit 6dabfacb38
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:53:54 2020 +0200
Sky: Code style and formatting fixes
Differential Revision: https://developer.blender.org/D8091
commit 6a3c91f7ad
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:53:02 2020 +0200
Cycles: Clamp Sky Texture altitude to avoid numerical issues
Differential Revision: https://developer.blender.org/D8091
commit 7aacf2e119
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:52:07 2020 +0200
Cycles: Account for Sky Texture mapping in the sun sampling code
Differential Revision: https://developer.blender.org/D8091
commit 192bd2605f
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:51:13 2020 +0200
Cycles: Change precomputed Sky Texture mapping to prioritize the horizon
Differential Revision: https://developer.blender.org/D8091
commit 41e6f9bd43
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:49:25 2020 +0200
Cycles: Add control for sun intensity in Sky Texture and change altitude to km
Differential Revision: https://developer.blender.org/D8091
commit e2736afdbe
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:44:24 2020 +0200
Cycles: Add versioning code for the new Sky Texture model
Differential Revision: https://developer.blender.org/D8091
commit 77cd8182f8
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:40:47 2020 +0200
Cycles: Remove Vector input on Sky texture when using the included sun
When using the sun, we need to sun sampling logic to avoid excessive
sampling map resolution, but that logic assumes that the Vector input
comes from the view direction.
That is the case in the vast majority of cases anyways, so the easiest
solution is to just remove the input for that case.
Differential Revision: https://developer.blender.org/D8091
commit 474dcbcf12
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Mon Jul 13 01:39:11 2020 +0200
Cycles: Remove limits on the Sky texture's sun rotation
For animation/driver purposes, being able to go outside of the 0-360
range makes things easier.
Differential Revision: https://developer.blender.org/D8091
commit f319eec881
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 11:05:43 2020 +0200
Cleanup: disable debug code
commit 30ed51d60a
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:50:19 2020 +0200
Cleanup: unused debug variable
commit 21b20ae5ec
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:38:57 2020 +0200
Particles: initial support for forces in simulation node trees
The force node can now be used to control the behavior of particles.
Forces can access particles attributes. Currently, there are three attributes:
`Position` (vector), `Velocity` (vector) and `ID` (integer).
Supported nodes are: Math, Vector Math, Separate Vector, Combine Vector and Value.
Next, I'll have to split `simulation.cc` into multiple files and move
some stuff out of blenkernel into another folder.
commit ebf9082e1c
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:38:30 2020 +0200
Nodes: support more implicit conversions in simulation node tree
commit 838b1742fb
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:38:03 2020 +0200
Functions: minor improvements
commit 404486e66c
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 10:01:37 2020 +0200
Functions: minor api improvements
commit ee5c2f6ead
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 11 20:41:21 2020 +0200
GPencil: Replace "ShaderFX" with "Shader Effects" in RNA prop text
commit c7eada103c
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 18:02:06 2020 +0200
Nodes: support implicit conversions and incorrectly linked sockets
commit 06401157a6
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 17:59:43 2020 +0200
Fix: incorrect attribute type in network
commit 46b79b3d4a
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:55:57 2020 +0200
Nodes: support vector math node in simulation node tree
commit b920875893
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:47:53 2020 +0200
Nodes: support math node in simulation node tree
commit 8fae58ce0b
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:39:17 2020 +0200
Nodes: support Value node in simulation node tree
commit 16d4373158
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:24:53 2020 +0200
Nodes: move Math, Vector Math and Value shader nodes to c++ files
This required a little bit of refactoring, because we were using c-only
syntax for the gpu shader names. All tests are still passing.
commit 415d3ee05b
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 22:03:27 2020 +1000
UV: add path select operator that uses the selection
Instead of using the mouse cursor position,
this selects between existing selected elements.
Access this since picking a selection path doesn't
work from the menu.
commit 6e698653df
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 20:34:17 2020 +1000
Cleanup: remove unused function
commit 651db1b26f
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 15:10:05 2020 +1000
Cleanup: spelling
commit 020e0f11ff
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 14:50:47 2020 +1000
Docs: remove reference to PYTHONHOME
This is no longer used by default, when '--python-use-system-env' is set
there are many Python environment variables, don't list them in
Blender's help message.
commit d2b910fafe
Author: Aaron Carlisle <carlisle.b3d@gmail.com>
Date: Fri Jul 10 16:07:31 2020 -0400
UI: UV: Add Select Shortest Path to menu
This matches the 3D Viewport
commit 3dc0178390
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 20:00:20 2020 +0200
Fix T78662: Cycles baking fails if denoising is enabled, after recent changes
This is not supported yet.
commit 6fbacd6048
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 19:56:53 2020 +0200
Fix build error building without OpenImageDenoise
commit 48f10319c6
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 18:40:35 2020 +0200
Fix T78801: Eevee missing setting to enable/disable freestyle per view layer
This was only visible when Cycles was enabled.
commit 4e8fc15586
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 10 12:21:32 2020 -0400
UI: Improve transform constraint layout
- Remove the "mapping" subpanel and moves the source axis
selection ot the destination subpanel.
- Rename "Source" and "Destination" to "Map From" and "Map To" to
make the action more clear
- Gray out source axes when their data isn't selected.
These changes were discussed in D8041.
commit 3e4f49fe71
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 18:02:51 2020 +0200
Revert "Fix T78296: Performance - Use Binary Search for MDeformWeight"
This reverts commit 39b525e0f0 and
3121015dce as tests are failing.
commit d5208c45fa
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Fri Jul 10 17:56:05 2020 +0200
GPencil: Fix unreported Use Falloff curve for active frame not working
For the active frame it was using always a value of 1.0 and it was not using the curve.
commit 6eeb32706a
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 12:20:07 2020 +0200
Cycles: support OpenImageDenoise in final renders
Performance is not great currently due to the API not seeming to support
efficient denoising of multiple tiles at the same time. So in many cases
only one or a few threads will actually be denoising at the same time.
In renders with many samples this is not a big problem, but for faster
renders it's a signficant overhead.
We should try to optimize this still, possibly by batching denoising of
a bigger neighborhood of multiple tiles at once.
commit 93791381fe
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 20:01:22 2020 +0200
Cleanup: reduce hardcoded numbers in denoising neighbor tiles code
commit e65c78cd43
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 18:54:42 2020 +0200
Cleanup: minor refactoring in Cycles update detection code
commit ad45b8d6a4
Author: Milan Jaros <jar091>
Date: Fri Jul 10 11:49:52 2020 +0200
Cycles: optimize camera inside volume tests
Only run when there are volumes in the scene, and compute in parallel.
Ref T56939
Differential Revision: https://developer.blender.org/D8261
commit d8e648c352
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 17:09:35 2020 +0200
Fix T78776: Cycles OpenCL error after recent changes for holdouts
commit 9dbe9a753a
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 16:50:26 2020 +0200
Fix T78766: Blender crashes after deleting vertices with Custom Normals.
Some core BMesh topology changing functions were not properly tagging
custom normal runtime caches as dirty...
commit 5372924983
Author: Richard Antalik <richardantalik@gmail.com>
Date: Fri Jul 10 16:14:10 2020 +0200
Fix T78579: Proxy produces wrong preview when using Offset or Crop
Make sure that proxy and original images are scaled to same size before
applying offset or crop.
During testing, I discovered, that raw cache will lose information whether
this image was proxy or not. Because of this, proxy images will not create
this cache type. It would be fairly easy to implement this functionality for
cache, but I have decided to not do it now, because I did not want to pass yet
another mostly hard-coded bool flag to cache system. Since image is proxy, it
should be fast to read anyway.
In case of using offset property, code was modified to make sure we scale
image only once. I also tried to make code more readable and streamlined and
cleaned up surrounding functions a bit.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8203
commit 77f823a240
Author: Richard Antalik <richardantalik@gmail.com>
Date: Fri Jul 10 15:57:28 2020 +0200
Fix T78573: Crash when removing strips with prefetching
Stop prefetching before changing content of seqbase.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8256
commit 47e71f4623
Author: Richard Antalik <richardantalik@gmail.com>
Date: Fri Jul 10 15:53:57 2020 +0200
Fix T69440: Memory leak adding strips via python
seq->strip was overwritten in python API function.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8204
commit cbfedf2139
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 15:53:36 2020 +0200
BLI: add C++ random number generator
This adds `blender::RandomNumberGenerator` in `BLI_rand.hh`.
Furthermore, `RNG` is now implemented in terms of this new generator.
No functional changes are expected, the generated random numbers
are not changed by this commit.
Reviewers: campbellbarton, brecht
Differential Revision: https://developer.blender.org/D8259
commit c2304d2f02
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 15:29:03 2020 +0200
Expose override flags to python RNA properties definition.
Time will tell whether we need to expose more RNA override flags here.
Implements/Fix T78534.
Differential Revision: https://developer.blender.org/D8250
commit 4d1c3c029e
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 08:37:35 2020 +0200
Cleanup: declaration and implementation function signature did not match
commit f93e0f1a9e
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 15:23:52 2020 +0200
Refactor override code to properly deal with runtime rna properties too.
The triplet static RNA / runtime RNA / custom properties is a real pain to
deal with...
Using the new `PropertyRNAOrID` struct helps clarifying and properly
dealing with all three cases.
Note that this makes override of py-defined RNA properties working
(support for that will be committed next).
Differential Revision: https://developer.blender.org/D8249
commit 337e2c9029
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 15:19:40 2020 +0200
RNA: refactor how we get 'ensured' RNA properties.
Introduce new PropertyRNAOrID structure, storing most useful data about
an 'opaque' PropertyRNA in relation with a given PointerRNA struct.
It deals with all the three cases (pure static RNA, runtime RNA where
data is actually stored in IDProperties, and pure IDProperties, aka
custom data.
commit 6c1157201a
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 22:59:12 2020 +1000
Cleanup: simplify platform define checks
Platforms besides WIN32 were in a single else clause, use elif instead.
commit 45287f909c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 22:58:30 2020 +1000
Fix for building on systems besides apple/windows/linux
commit 26d28ade26
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:40:23 2020 +0200
Cleanup: follow code style
commit c806db6313
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:22:35 2020 +0200
Functions: add utility to find dependencies of input sockets
commit 60133ff98d
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:20:39 2020 +0200
Functions: store derived node tree and network in map for future access
commit 295b3aefb0
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:19:45 2020 +0200
Functions: make constant folding work on unfinished networks
commit 7bae599232
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:18:51 2020 +0200
Nodes: add redundant name check in debug builds to prevent errors
commit 3121015dce
Author: Jeroen Bakker <jeroen@blender.org>
Date: Fri Jul 10 13:37:12 2020 +0200
Fix Crash due to recent changes
{39b525e0f07fa25dcda54226ade789959b642dec} could write in unallocated
space.
commit 00eb6a56aa
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Fri Jul 10 13:30:08 2020 +0200
GPencil: Fix tooltip error
The tooltip was copied by error from Lattice modifier.
commit 8fd65a2252
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:56:57 2020 +0200
Functions: use new is-equal and hash function of CPPType
commit 3edd2832b2
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:54:19 2020 +0200
Functions: make generic types hashable
commit f62204718b
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:53:50 2020 +0200
BLI: initial hash function for Color4b and float4x4
commit 8f6c0f2242
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:41:51 2020 +0200
Functions: make generic types equality comparable
commit 52636c3059
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:36:06 2020 +0200
Cleanup: various cleanups in for CPPType
commit 39b525e0f0
Author: Jeroen Bakker <jeroen@blender.org>
Date: Fri Jul 10 12:05:31 2020 +0200
Fix T78296: Performance - Use Binary Search for MDeformWeight
Use binary search for querying deform weights.
Spring 02_020_A.anim.blend on Ryzen 1700X goes from 12.4 to 12.7fps.
During profiling it was detected that adding new items to the head was faster than adding to the tail.
Reviewed By: Campbell Barton
Differential Revision: https://developer.blender.org/D8127
commit 77a646279d
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:04:32 2020 +0200
Cleanup: structure CPPType according to code style guide
commit 9c25731781
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 11:53:11 2020 +0200
LibOverride: Fix improper tagging of more of the backward pointers in RNA nodetrees.
commit 582a0b7e5a
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 19:02:18 2020 +1000
Fix T78756: White UV drawing is displayed as Dashed
commit 7a9028cad1
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 18:58:36 2020 +1000
Fix UV rip failing to disable proportional edit-mode
commit a148c4676b
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 16:04:09 2020 +1000
Cleanup: spelling
commit 03f5acd445
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 16:03:12 2020 +1000
Cleanup: clang-format
commit 8b660ea0ec
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 13:36:16 2020 +1000
Fix UV path redo in vert/edge mode
Redo was only working in some situations,
some options were also not being forwarded.
commit 96068324cd
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 13:35:44 2020 +1000
Fix BM_loop_at_index_find lookup
commit 89cb41faa0
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:55:59 2020 +1000
UV: allow ripping face-regions
This changes the behavior of rip when entire faces are selected.
Now face regions are isolated and moved instead of ripping the edge-loop
extracted from the selection boundary.
This is a convenient alternative to separate selection & move.
Resolves T78751.
commit 3fdd092649
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:38:28 2020 +1000
Cleanup: face-center mesh calculation
Loop over faces and calculate their centers instead of zeroing the
face center array and accumulating all faces vertex corners.
Move subsurf face center extraction into it's own loop since it works
differently.
commit b0378440ce
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:18:43 2020 +1000
Fix missing adjacent UV check for recent UV path select
Path selection could cross UV islands if the destination element was
on an island boundary.
commit 8f24ec2e26
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:04:29 2020 +1000
Cleanup: add BLI_linklist_find_last
This makes adding to the end of a linked list simpler,
In most cases we avoid this in favor of BLI_linklist_append.
For one off operations it's OK.
commit 3dd460aa7f
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:41:14 2020 +1000
Cleanup: spelling
commit a0d3b60015
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:46:26 2020 +1000
Cleanup: use FLT_MAX for the maximum path selection cost
A large number below FLT_MAX was used to avoid overflow,
however this doesn't cause any problems.
commit 0b77e2f4c4
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:31:41 2020 +1000
Cleanup: variable names, use define for maximum path cost
commit 92bc277950
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:40:38 2020 +1000
Cleanup: undeclared warnings
commit 3623db7784
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 19:03:50 2020 +0200
BLI: add more operator overloads for float2
commit 03a00bda2b
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Thu Jul 9 17:16:24 2020 +0200
Sculpt: Make Sculpt Vertex Colors features experimental
This disables all Sculpt Vertex Colors tools, operators, panels and rendering capabilities and puts them under the "Use Sculpt Vertex Colors" experimental option.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8239
commit 1e3247c078
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 18:19:39 2020 +0200
Fix: add missing extern "C"
commit a90b69d065
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 18:04:13 2020 +0200
Build: add more libc compatibility functions for upcoming libraries update
These are needed by the x264 library.
commit 6778949e01
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Thu Jul 9 17:56:00 2020 +0200
Fix repeated Face Sets IDs when joining meshes
As Face Sets IDs start from 0 and increase by 1 each time a new face set
is created in a mesh, when joining multiple meshes it could happen that
the same ID is used by several unrelated areas in multiple objects. This
checks the Face Sets IDs when joining meshes and ensures that they are
not repeated between different objects when joining them, so in the
resulting mesh all previous face sets will have different IDs.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8224
commit 7b1c406b54
Author: Bastien Montagne <bastien@blender.org>
Date: Thu Jul 9 15:33:34 2020 +0200
Implement T77959: Never duplicate linked data during deep-copy.
Note that this behavior is enforced on user level for now, but on code
side it is controlled with a flag, which should make it easy to refine
that behavior if needed.
Only exception is when we duplicate a linked ID directly (then we assume
user wants a local deep-copy of that linked data, and we always also
duplicate linked sub-data-blocks).
Note that this commit also slightly refactor the handling of actions of
animdata, by simplifying `BKE_animdata_copy_id_action()` and adding an
explicit new `BKE_animdata_duplicate_id_action()` to be used during ID
duplication (deep copy).
This also allows us to get rid of the special case for liboverrides.
commit 78b629a98f
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Wed Jul 8 18:10:31 2020 +0200
Sculpt: Skip fully hidden nodes in sculpt tools
As tools iterators skip not visible vertices, fully hidden nodes can
also be skipped and considered as masked.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8244
commit 1fb667da01
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Tue Jul 7 23:01:51 2020 +0200
Fix wrong upate flag when updating the PBVH visibility
This function was using the wrong flag to update the visibility state of
the nodes, so I assume that most of the partially visible optimizations
were not working.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8243
commit e5ebaa9fd6
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Wed Jul 8 17:22:11 2020 +0200
Fix T78664: Implement Mesh and Face Set boundary automasking in Multires
This implements the SCULPT_vertex_is_boundary and SCULPT_vertex_has_unique_face_set functions for PBVH_GRIDS, which makes features such as automasking now work in multires. It also fixes some other face sets related features in multires, like face set boundary smoothing.
This uses the BKE_subdiv_ccg_coarse_mesh_adjacency_info_get function to get the vertex indicies in the base mesh from multires. This way the API functions can get topology or face set information directly from it. In the future, these vertex indices can be used to get any other information from the base mesh from multires, like seams, sharp edges, disconnected elements IDs...
Reviewed By: sergey
Maniphest Tasks: T78664
Differential Revision: https://developer.blender.org/D8227
commit bd84b2cbcc
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Sat Jul 4 18:28:40 2020 +0200
Fix Sculpt Vertex Colors sample color changing brush alpha
It is not practical to change the alpha of the paint color with the
color picker as with the current brush design alpha is the main strength
control for the brush.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8208
commit 13b1374497
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Thu Jul 9 17:41:04 2020 +0200
Fix crash when using Mask by Color in Multires
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8207
commit 78d48343ae
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Thu Jul 9 15:59:57 2020 +0200
Make deps: Fix compilation error on CentOS
There were two issues.
First is related on ISPC's CMake configuration forcing C and C++
compilers to be clang and clang++. This goes against of desired
behavior when we use our own compiled clang compilers.
The second issue was related on linker failure: CLang libraries
are linked statically, and they need some of C++ 11 STL symbols
which are coming from libstdc++.
Differential Revision: https://developer.blender.org/D8258
commit 2be0ae7c99
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 16:51:48 2020 +0200
Fix Cycles unnecessary updates to camera in viewport render
Problem identified by Milan Jaros.
commit 9de09220fc
Author: Szymon Ulatowski <szulat>
Date: Thu Jul 9 17:19:52 2020 +0200
EEVEE: Implement the missing Sky texture
I'm not sure if the Sky was deliberately left out or was just waiting for a
better moment, but so many I was disappointed that Sky in EEVEE is
completely white.
There are already 2 implementations (osl and gpu) so this is the third one.
Looking at other cases it seems that we are not supposed to share sources
between cycles and the rest? So the new util_sky_model files are just
copies of what is already in cycles, except that the data file uses the RGB
variant of the Hosek/Wilkie model, because we output RGB anyway (but can be
easily changed to XYZ if desired - the results are nearly identical).
I am not sure if it is okay to pass 3*9 float values as 3 mat4 uniforms (I
wanted to use mat3 but it does not work).
Also, should I cache the sky model data between renders if the parameters
do not change?
Reviewed By: fclem, brecht
Differential Revision: https://developer.blender.org/D7108
commit 42c99ec15b
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 16:37:44 2020 +0200
BLI: rename rand.c to rand.cc
commit 580d50091c
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 15:40:27 2020 +0200
Particles: Create a simulation state for every Particle Simulation node
Every Particle Simulation node has a name (or a path when it is in a node group).
This name has to be used in the Simulation modifier on a point cloud to see
the particles.
Caching has been disabled for now, because it was holding back development
a bit. To reset the simulation, go back to frame 1.
Currently, there is no way to influence the simulation. There are just some
randomly moving points. Changing that is the next step.
commit 31ad43a3c7
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 15:29:25 2020 +0200
Blenloader: make BLO_read_data_address work in C++
commit 544c435fdd
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 12:20:07 2020 +0200
Fix T78745: Cycles error baking with multiple materials
commit 8ddf7556a5
Author: Bastien Montagne <bastien@blender.org>
Date: Thu Jul 9 11:44:11 2020 +0200
Fix T78718: Crash when deleting particle system modifier with the X Shortcut.
Duplication and deletion code of modifiers was totally wrong for
particle system, that special weird thing needs its own custom
management.
Note that for now I chose not to duplicate the particle settings ID when
duplicating the modifier...
commit ea5fe7abc1
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 17:29:17 2020 +1000
UV: path selection support
This adds support for path selection for vertex edge & face selection
modes, matching mesh editing behavior, useful with the UV rip tool.
Region select & edge tagging are currently not supported,
although they could be added eventually.
commit 0b8221683f
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 9 18:23:16 2020 +1000
BMesh: add utility functions
- BM_edge_uv_share_vert_check
- BM_face_uv_calc_center_median_weighted
- BM_loop_at_index_find
commit 0b3bf69d3c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 9 13:33:15 2020 +1000
Cleanup: move BMesh UV queries into their own file
commit 754c5d6a14
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 9 13:29:48 2020 +1000
Cleanup: clang-format
commit 31bc76ea4e
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 22:29:10 2020 +0200
Cleanup: remove unnecessary calls to as_span
This uses the new implicit conversions and constructors
that have been committed in the previous commit.
I tested these changes on Linux with gcc and on Windows.
commit 403384998a
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 22:27:25 2020 +0200
BLI: improve constructors and conversions to span
This allows us to avoid many calls to `as_span()` methods. I will
remove those in the next commit. Furthermore, constructors
of Vector and Array can convert from one type to another now.
I tested these changes on Linux with gcc and on Windows.
commit 4b85ed819d
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 20:41:00 2020 +0200
Cleanup: remove unused function
This is not necessary in C++17 anymore.
commit f7d5d4ee3b
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 20:39:12 2020 +0200
Cleanup: use c++17 helper variable templates
commit e4926c167b
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 8 18:08:08 2020 +0200
Fix T78718: Crash when deleting particle system modifier with the X Shortcut.
Again those backward pointers not properly flagged in RNA, hence
generating infinite loops.
commit f4a39cafa1
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 17:05:40 2020 +0200
Functions: add AttributesRef class
This is the same as MutableAttributesRef, but the data in it cannot be changed.
commit 439c238bb4
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 17:04:50 2020 +0200
Cleanup: use different internal socket name
commit 05365d1376
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 17:04:09 2020 +0200
Functions: support hashing MFDataType and CPPType
commit 2de5de57c5
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Wed Jul 8 15:03:06 2020 +0200
Build: fix stack linker warning with ffmpeg on macOS
The ff_cfhd_init_vlcs() function was using a lot of stack space, which
made linker on macOS unhappy. Using heap allocation allows to silence
the warning without causing other side-effects.
Kept the patch enabled for all platforms to avoid difference in behavior
and performance on different platforms, which could make certain types
of investigation very tricky.
Differential Revision: https://developer.blender.org/D8248
commit cb3c4218bf
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 8 15:43:57 2020 +0200
Minor cleanup in rna override code.
commit d1f4546a59
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:10:24 2020 +0200
Functions: implement common subnetwork elimination optimization
This was the last of the three network optimizations I developed in
the functions branch. Common subnetwork elimination and constant
folding together can get rid of most unnecessary nodes.
commit e3e42c00cb
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:06:32 2020 +0200
Functions: Support getting MFSocket based on its id
commit 2b9d62b73a
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:06:04 2020 +0200
Functions: Support accessing socket index of MFSocket
commit 34d175f372
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:04:28 2020 +0200
Functions: initial hash/equals implementation for constant multi-functions
commit 840941215d
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:02:47 2020 +0200
Functions: allow multi-functions to override a hash and equals function
commit 36a547af7b
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:01:33 2020 +0200
Cleanup: add correct license header to tests
commit ff133bbd33
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 14:57:31 2020 +0200
BLI: add disjoint set data structure
This can be used to find separate islands in meshes efficiently (as is
done in cycles already). Furthermore, this helps to implement some
algorithms on node trees more efficiently.
commit a8ff8b64dc
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 14:40:34 2020 +0200
BLI: add comparison operators and hash functions for float3, etc.
commit ff444da7c4
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 2 12:28:57 2020 +0200
macOS: upgrade minimum required version to 10.13 High Sierra
C++17 does not work on 10.12, and Apple extended support ended for 10.12 in
October 2019.
Maniphest Tasks: T76783, T76184
Differential Revision: https://developer.blender.org/D8179
commit 6435acd8f6
Author: Brecht Van Lommel <brecht@blender.org>
Date: Wed Jul 8 12:57:59 2020 +0200
Cycles: support shader transparency for holdout objects
Now transparent areas of the object will render objects behind.
Fixes T78728.
commit 643196cc37
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Wed Jul 8 11:04:49 2020 +0200
CMake: Fix spelling of Embree passed to find package
The spelling and capitalization of package name passed to find_package()
and find_package_handle_standard_args() needs to match.
Silences CMake warning about mismatch.
Differential Revision: https://developer.blender.org/D8247
commit 45004d82e0
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 11:18:43 2020 +0200
Functions: add dead node removal and constant folding optimization
Those optimizations work on the multi-function network level.
Not only will they make the network evaluation faster, but they also
simplify the network a lot. That makes it easier to understand the
exported dot graph.
commit 50d7c00d9c
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 10:16:56 2020 +0200
Cleanup: fix comment
commit 01c8aa12a1
Author: Alexander Gavrilov <angavrilov@gmail.com>
Date: Wed Jul 1 17:38:07 2020 +0300
Apply Modifier: support applying as shape key and keeping the modifier.
This can be useful to save the result of a cloth simulation as a
shape key without destroying the simulation, so it's possible to
e.g. re-run it to get other shapes, or simply use the new shape
key to start the simulation already in a draped state.
It also makes sense to allow applying as shape key even when the
mesh is shared, because the operation itself just adds a shape
key. To support this, split the apply operator into Apply and
Apply As Shapekey so that they can have different poll callbacks.
Differential Revision: https://developer.blender.org/D8173
commit 7fcb6bc59c
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Wed Jul 8 02:10:02 2020 +0200
Fix T78324: Different Sky Texture results between CPU and GPU
The problem here was numerical precision: The code calculates the angle between
sun and view direction, and the usual acos(dot(a, b)) approach for that has
poor numerical performance for almost parallel angles.
As a result, the generally tiny difference between floating point computation
between CPU and GPU was enough to make the sun vanish at different radii,
causing different results.
The new version fixes the difference by making the computation much more robust
on both platforms.
commit afcb41a0aa
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 20:32:40 2020 +0200
BLI: simplify copy constructor of Array
commit eb5fb1741d
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 20:29:35 2020 +0200
Cleanup: don't end description with a '.'
commit 8713109212
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 20:27:34 2020 +0200
Cleanup: fix typo
commit 902ee4d13c
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 19:46:10 2020 +0200
Functions: cleanup loop that traverses the MFNetwork
commit 22158162ef
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 19:34:35 2020 +0200
Functions: add generic functions that output constants
commit f4633cf46c
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 19:16:31 2020 +0200
BLI: simplify copy constructor of vector
commit 67042aa6a1
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:45:34 2020 +0200
Functions: extend multi-function network api
commit adfae89f96
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:40:42 2020 +0200
BLI: provide access to underlying node in dot exporter
commit a8627ea66d
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:39:24 2020 +0200
Functions: Add debug print and destruct callback to CPPType
commit 4990e4dd01
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:23:33 2020 +0200
Nodes: Generate multi-function network from node tree
This adds new callbacks to `bNodeSocketType` and `bNodeType`.
Those are used to generate a multi-function network from a node
tree. Later, this network is evaluated on e.g. particle data.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D8169
commit ff97545c50
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Tue Jul 7 18:37:35 2020 +0200
Fix T75943 EEVEE: Cubemaps shows black
Caused by faulty driver implementation. Force fallback method.
commit 1e2ff4f81b
Author: Hans Goudey <h.goudey@me.com>
Date: Tue Jul 7 11:10:42 2020 -0400
Cleanup: Add braces for clang tidy
commit 0edf2fc128
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 16:51:03 2020 +0200
BLI: Correct spin lock definition
The MSVC atomic function is defined for an unsigned type.
Not sure why this became an issue after switch to TBB by default,
maybe some CFLAGS changed to be more strict after that.
commit dad3de89dc
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 7 11:27:09 2020 -0300
Fix: remove accidental code
`v1` and `v2` are already set.
commit d352902758
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 11:16:31 2020 +0200
Make deps: Use own nasm for ffmpeg and x264
Fixes the warning: building for macOS, but linking in object file
Differential Revision: https://developer.blender.org/D8235
commit 1e3c0b4b03
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 10:47:09 2020 +0200
Make deps: Compile own version of nasm for Apple
The upstream version of nasm does not put version information to the
generated object files, which makes linker to show the following
warning:
building for macOS, but linking in object file
Using own patched version of nasm which puts required information to
the object file, making linker happy.
The plan is to either streamline the patch and provide it to the
upstream, or, it that takes too long, get an independent fix from the
upstream.
commit 202e7ccaae
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 14:33:59 2020 +0200
Fix T77455: Blender Freezes when using the 3d Scale Gizmo
Issue is reported on Linux ith Intel HD6xx iGPU. Inside
`gpu_select_sample_query.c` the call to `glGetQueryObjectuiv` froze. After
bisecting this lead to the polyline shader. When using a 3d color shader
in stead of the polyline shader during selection seems to fix the issue.
Other parts of blender might also be effective, but I wasn't able to
freeze blender in these areas. When it does, we might want to add
a similar work-around to button2d, cage2d, cage3d & move3d, navigate.
Backport this patch to 2.83.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8217
commit d1dcd2b464
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 16:17:36 2020 +0200
BLI: Fix mistake in SpinLock TBB migration
Copy-paste mistake.
commit 20558848d3
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 7 09:45:53 2020 -0300
Optimization: use `BLI_bvhtree_intersect_plane` to detect faces that will be affected by the knife tool
The knife code currently calls the `BLI_bvhtree_overlap` function that
tests the overlap between the mesh tree and an AABB that encompasses the
points projected in the clip_start, clip_end and or clip_planes of the
view.
This resulted in many false positives since the AABB is very large.
Often all the triangles "overlapped".
The solution was to create a new function that actually tests the
intersection of AABB with a plane.
Even not considering the clip_planes of the view, this solution is more
appropriate than using overlap.
Differential Revision: https://developer.blender.org/D8229
commit 630c6226e2
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Tue Jul 7 16:26:01 2020 +0200
Fix T78307 UI: Drawing artifacts in the Blender UI on macOS
This was due to a bad driver which was not respecting this bit of the
specification:
`If the current primitive does not originate from an instanced draw command, the value of gl_InstanceID is zero.`
commit 737bd549b6
Author: Patrick Mours <pmours@nvidia.com>
Date: Mon Jul 6 12:25:54 2020 +0200
Cycles: Add support for native OptiX curve primitive
This patch adds support for the curve primitive from OptiX to Cycles. It's currently hidden
behind a debug option, since there can be some slight rendering differences still (because no
backface culling is performed and something seems off with endcaps). The curve primitive
was added with the OptiX 7.1 SDK and requires a r450 driver or newer, so this also updates
the codebase to be able to build with the new SDK.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8223
commit 95f0f31279
Author: Brecht Van Lommel <brecht@blender.org>
Date: Tue Jul 7 14:45:31 2020 +0200
Fix T78692: improve UI regarding the effect of the denoiser on denoising passes
It wasn't obvious that the choice of Cycles denoiser also generates different
denoising data passes for compositing.
commit a394aac8b4
Author: Brecht Van Lommel <brecht@blender.org>
Date: Tue Jul 7 14:47:59 2020 +0200
Fix T78666: Cycles non-uniformly scaled hair renders wrong for static objects
Don't apply the matrix transform optimization in this case, curve points and
radius can't represent non-uniform scale the way is possible with triangle
meshes and vertices.
This would cause abrupt change if objects had e.g. motion blur in one frame
and not in the next.
commit 98bee41c8a
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jul 7 14:30:55 2020 +0200
IO: Reversed persistent ID order in exports to Alembic and USD
Each duplicated (a.k.a. instanced) object has a Persistent ID, which
identifies a dupli within the context of its duplicator. This ID
consists of several numbers when there are nested duplis (for example a
mesh instancing empties on its vertices, where each empty instances a
collection). When exporting to Alembic/USD, these are used to uniquely
name the duplicated objects in the export.
This commit reverses the order of the persistent ID numbers, so that the
first number identifies the first level of recursion. This produces
trees like this:
ABC
`--Triangle
|--Triangle
|--Empty-1
| `--Pole-1-0
| |--Pole
| `--Block-1-1
| `--Block
|--Empty
| `--Pole-0
| |--Pole
| `--Block-1
| `--Block
|--Empty-2
| `--Pole-2-0
| |--Pole
| `--Block-2-1
| `--Block
`--Empty-0
`--Pole-0-0
|--Pole
`--Block-0-1
`--Block
It is now clearer that `Pole-2-0` and `Block-2-1` are instanced by
`Empty-2`. Before this commit, they would have been named `Pole-0-2` and
`Block-1-2`.
commit 70b1c09d7a
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jul 7 12:45:30 2020 +0200
IO: Fix bug exporting dupli parent/child relations
Exporting a scene to USD or Alembic would fail when there are multiple
duplicates of parent & child objects, duplicated by the same object. For
example, this happens when such a hierarchy of objects is contained in a
collection, and that collection is instanced multiple times by mesh
vertices. The problem here is that the 'parent' pointer of each
duplicated object points to the real parent; Blender would not figure
out properly which duplicated parent should be used.
This is now resolved by keeping track of the persistent ID of each
duplicated instance, which makes it possible to reconstruct the
parent-child relations of duplicated objects. This does use up some
memory for each dupli, so it could be heavy to export a Spring scene
(with all the pebbles and leaves), but it's only a small addition on top
of the USD/Alembic writer objects that have to be created anyway. At
least with this patch, they're created correctly.
Code-wise, the following changes are made:
- The export graph (that maps export parent to its export children) used
to have as its key (Object, Duplicator). This is insufficient to
correctly distinguish between multiple duplis of the same object by
the same duplicator, so this is now extended to (Object, Duplicator,
Persistent ID). To make this possible, new classes `ObjectIdentifier`
and `PersistentID` are introduced.
- Finding the parent of a duplicated object is done via its persistent
ID. In Python notation, the code first tries to find the parent
instance where `child_persistent_id[1:] == parent_persistent_id[1:]`.
If that fails, the dupli with persistent ID `child_persistent_id[1:]`
is used as parent.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8233
commit f2175e06a7
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 12:43:18 2020 +0200
Mae deps: Ensure Brotli is disabled for FreeType
We don't need it and it was optionally enabled, causing Blender to fail
to link on certain configuration (when Brotli is installed via Homebrew
for example).
commit 02cd159539
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 12:31:10 2020 +0200
Cleanup: add comment explaining operator delete
commit cc311e4a52
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jun 30 15:13:54 2020 +0200
IO: print export name instead of object name in debug export graph output
This is just a change in `AbstractHierarchyIterator::debug_print_export_graph()`
to aid in debugging. It'll make it possible to distinguish between
different duplicates of the same object.
No functional changes to Blender itself.
commit 5761cb9ee2
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 11:52:45 2020 +0200
Guarded Allocator: add missing operator delete
This resolves warning C4291 on windows.
commit 80fe5e1b15
Author: Johan Walles <walles>
Date: Tue Jul 7 11:09:31 2020 +0200
UI: Add units to motion tracking solve errors
The unit being "pixels".
Before this change the solve errors were unitless in the UI.
With this change in place, the UI is now clear on that the unit of the
reprojection errors is pixels (px).
Differential Revision: https://developer.blender.org/D8000
commit 6d9a6f12b3
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 10:06:14 2020 +0200
Make deps: Fix compilation error of Python on macOS
The configuration was confused about gettext installed via Homebrew
and isysroot passed to Python's compilation but not to test programs.
After this change `import gettext` still works, but it is unclear how
to test it further,
Differential Revision: https://developer.blender.org/D8231
commit 955abbeff2
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 09:01:01 2020 +0200
Fix sign conversion error
commit e233ee1c1f
Author: Philipp Oeser <info@graphics-engineer.com>
Date: Thu Jun 25 14:37:22 2020 +0200
Fix T78186: Dyntopo panel error with tools that dont have a brush
Maniphest Tasks: T78186
Differential Revision: https://developer.blender.org/D8120
commit 19d4e265b6
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 10:35:28 2020 +0200
Cleanup: remove redundant comments
Searching in these files for "_as" will reveal a comment at the
top, that explains what these methods are for. There is no need
to duplicate that knowledge all over the place.
commit 6e609f0eb0
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 17:50:33 2020 +1000
Cleanup: use doxy comments
commit 62774baded
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 16:06:05 2020 +1000
UI: add merge/split menus
This makes the menus and keymap match the edit-mesh
(M for merge, Alt-M for split).
commit d212b3dc43
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Mon Jul 6 15:28:19 2020 +0200
Make deps: Fixes for macOS platform
Set of fixes which had to be made in order to have dependencies built
on own laptop:
- Require bison as a dependent software. It is required by ISPC.
On macOS it is required to be installed via Homebrew. This is because
Bison from Xcode toolchain is too old.
- Made sure Boost is compiled using clang.
Without this gcc was used, and some unsupported command line argument
was passed to it.
- Modify OGG in a way which does in fact pull fixed sized types.
They are defined in stdint.h.
Without this fix FFmpeg will not detect presence of OGG because the
test program fails to compile.
- Force disable zstd compression and make wepb optional for the TIFF
library. Without this TIFF might pick up development libraries from
Homebrew.
Differential Revision: https://developer.blender.org/D8221
commit b28683b8b5
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 16:03:26 2020 +1000
Cleanup: remove unused arguments
commit 0c58970da7
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 12:44:47 2020 +1000
Cleanup: spelling
commit ad0edc626d
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 12:43:45 2020 +1000
Cleanup: unused World struct members linfac, logfac
commit e20171e59f
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 16:39:28 2020 -0400
Fix build error with tests for removed functions
These GHash functions were removed in 12817083ec,
so the tests should be removed too.
commit d557f05502
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 16:07:54 2020 -0400
Cleanup: Use bool instead of int
commit 053e0c0af3
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 15:35:21 2020 -0400
UI: Add shortcuts for shader effect panels
Only the delete shortcut applies here, although the move up and down
operators can optionally be assigned in the keymap.
See rB1fa40c9f8a81 for more details and rB5d2005cbb54b for the
grease pencil modifier panel implementation, which is the same.
commit 12817083ec
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 6 14:44:30 2020 -0300
Cleanup: Use the BLI_edgehash API in the sewing simulation of cloths
Also remove the code in the ghash that is no longer used.
This change simplifies the existing code.
Differential Revision: https://developer.blender.org/D8219
commit a856de700b
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 13:17:07 2020 -0400
Fix T77730: ShaderFx Missing Update Notifier
This adds a notification type for shaderfx so the properties editor can
be properly notified to redraw.
Another possible solution would be to also redraw the shaderfx tab
with a ND_MODIFIER update, but this solution allows us to avoid
some unecessary redraws too. There were no existing cases of
ND_OBJECT | NC_MODIFIER updates, so those cases were
removed from buttons_area_listener.
Differential Revision: https://developer.blender.org/D8159
commit f6f4043924
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 17:59:04 2020 +0200
BLI: add methods to lookup a stored key in a set
commit 1562c9f031
Author: Patrick Mours <pmours@nvidia.com>
Date: Mon Jul 6 17:32:32 2020 +0200
Fix OptiX viewport denoising not working when rendering scene (without OptiX) that uses unsupported features
Denoising devices do not need to load the full feature set of kernels, so only activate the denoising
feature for them (so that it is possible to use features that are supported by the render devices, but
not the denoising devices).
commit aabfd2fb9b
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 6 16:55:00 2020 +0200
Cleanup: readfile: remove old deprecated OldNewMap for runtime caches.
commit ee3eba902a
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 6 16:21:41 2020 +0200
Runtime cache preservation during undo: add support for nodes and embedded IDs.
commit bfc644dcfb
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Mon Jul 6 16:52:28 2020 +0200
Reduce `DupliObject::persistent_id` from 16 to 8 items
For historical reasons, `DupliObject::persistent_id` was of size
`2*MAX_DUPLI_RECUR`. These reasons are now gone, and the persistent ID
always gets exactly one array element for every dupli-recursion.
Differential Revision: https://developer.blender.org/D8222
Reviewed by: brecht
commit 0b07f9b717
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 6 15:07:12 2020 +0200
Fix T78608: Memory leak in Material properties: "Data from SCE".
Caused by recent own refactor of cache presevation handling in readfile,
EEVEE's lightcache are weird birds that can also be saved in .blend
files, need a special handling for those 'persistent' caches...
commit 99feb10b8b
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 23:01:36 2020 +1000
Cleanup: warning, spelling
commit 20446f07f6
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 22:52:29 2020 +1000
Docs: reference bl_rna_get_subclass_py instead of bl_rna_get_subclass
bl_rna_get_subclass only works for Nodes at the moment.
commit ffaf294c3f
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Mon Jul 6 14:53:39 2020 +0200
Fix alignment/size issue on ARM/RPi architecture
Addresses 964305 from Debian bug tracker.
commit 924578ce19
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 6 09:49:00 2020 -0300
Optimization: Don't compute the snap to face on the knife tool twice
Both `knife_find_closest_vert` and `knife_find_closest_edge` call
`knife_find_closest_face`. Thus, running the raycast twice and setting
values like `kcd->curr.bmface` and `kcd->curr.is_space` repeatedly.
So:
- separate `knife_find_closest_face` from `knife_find_closest_vert` and `knife_find_closest_edge`.
- rename `knife_find_closest_vert` to `knife_find_closest_vert_of_face`
- rename `knife_find_closest_edge `to `knife_find_closest_edge_of_face`.
- do not set parameters previously set.
Differential Revision: https://developer.blender.org/D8198
commit 073c426900
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 6 09:03:33 2020 -0300
Fix faces disappearing when AutoMerge & Split
commit c632cf9ccd
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 21:23:35 2020 +1000
Fix UV select separate not refreshing the display
commit 2c0cab03ca
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 21:14:12 2020 +1000
UV: add rip region to toolbar
commit dbe171fb26
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 21:03:45 2020 +1000
Cleanup: spelling, comments
commit 18b6c49a90
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 12:37:11 2020 +0200
Cleanup: rename namespace TimeIt to timeit
According to our style guide, namespaces should have
lower case names.
commit 572c48cf98
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 09:08:53 2020 +0200
BLI: improve exception safety of memory utils
Even if we do not use exception in many places in Blender, our core C++ library
should become exception safe. Otherwise, we don't even have the option
to work with exceptions if we decide to do so.
commit 703a73fa84
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 10:56:26 2020 +0200
BLI: refactor how buffers for small object optimization are stored
Previously, there was an error when operator-> was returning an
invalid type. See error C2839.
commit 80393a0eba
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:41:36 2020 +1000
UV: add rip tool
New rip tool matching edit-mesh rip functionality.
Useful as disconnecting UV's, especially for loops is inconvenient
without this.
This uses 'V' to rip, changing stitch to 'Alt-V'.
commit 9353477383
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:41:17 2020 +1000
BMesh: add BM_face_calc_uv_cross
commit b51b893df8
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:40:55 2020 +1000
BMesh: add BM_loop_other_vert_loop_by_edge
commit 705015e0a4
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 10:21:14 2020 +0200
Fix T78481: Workbench Shadow effects XRay
When in XRay some effects (shadow, cavity & depth of field) aren't supported.
This patch makes sure that these effects aren't enabled.
commit 4f3045999d
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:35:41 2020 +1000
Cleanup: warnings, spelling
commit 0f617cd67e
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 07:45:10 2020 +0200
GPU: Remove local shaders workaround for Intel/Windows
It has been tested that local shaders workaround isn't needed for the
latest Windows/Intel 6xx GPU's.
Currently the local shaders workaround doesn't work anymore during the
investigation it was detected that the intel drivers didn't need it
anymore.
Local shaders should still be fixed as it is also used for some legacy
iGPU's. The current work around crashes when doing preview renders in
EEVEE as the default materials aren't available but for the work around
they should. (See T77346 for more information)
commit baf124c753
Author: Aaron Carlisle <carlisle.b3d@gmail.com>
Date: Sun Jul 5 16:45:56 2020 -0400
RNA Manual Reference: Update links
commit 247a28f242
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 5 15:08:26 2020 +0200
Revert "BLI: refactor how buffers for small object optimization are stored"
This reverts commit 5d79f9f276.
This was introducing build errors in windows. Need a bit more time to check it.
commit 5d79f9f276
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 5 16:30:26 2020 +0200
BLI: refactor how buffers for small object optimization are stored
commit 464aaf2701
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 4 17:31:02 2020 +0200
Fix T78603: GPencil Noise modifier Vertex Group influence filter missing
This was removed by error during the last refactor of modiifers.
commit 169bb4b9ce
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 4 17:28:05 2020 +0200
BLI: fix mistake in move constructor of Stack
commit 8e97694c8a
Author: Julian Eisel <julian@blender.org>
Date: Sat Jul 4 17:06:57 2020 +0200
Fix T78588: Material preview not visible in selection list
Logic to determine if the library icon should be used was too general.
commit 9168ea8aab
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 4 11:15:11 2020 +0200
Cleanup: Fix small typo error
commit 17603816f2
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 4 11:04:21 2020 +0200
GPencil: Cleanup some comments typo
commit b0da78084b
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Sat Jul 4 01:27:12 2020 +0200
UI: Attempt to fix OSX widget shader issue
Some OSX GL driver implementation needs a dummy vbo read. This fixed issues
with the Hair shaders in the past.
Related to T78307
commit cad98923d0
Author: Richard Antalik <richardantalik@gmail.com>
Date: Sat Jul 4 01:02:54 2020 +0200
Cleanup: spelling
commit ea65c6a153
Author: Richard Antalik <richardantalik@gmail.com>
Date: Sat Jul 4 00:59:09 2020 +0200
Fix T78433: Adding Fade Generates Python Exception
This was caused by typo in rB67a822e08684.
commit 4bf56b37ca
Author: Nathan Craddock <nzcraddock@gmail.com>
Date: Fri Jul 3 13:31:42 2020 -0600
Cleanup: Use C-style comments in outliner files
No functional changes. Convert all C++ style comments to C comments.
Also capitalize and add full stops.
The comments themselves were not cleaned up. Some could be removed or
reworded.
commit 59ef43147e
Author: Nathan Craddock <nzcraddock@gmail.com>
Date: Fri Jul 3 12:48:00 2020 -0600
Cleanup: Remove unused outliner activation code
No functional changes. Remove commented calls to extern_set_butspace
and unused text activation code.
commit 57a48bd0ca
Author: Nathan Craddock <nzcraddock@gmail.com>
Date: Fri Jul 3 12:36:09 2020 -0600
Cleanup: Use _fn suffix for outliner button callbacks
No functional changes. Use _fn instead of _cb.
commit d7dbf90a02
Author: Sebastian Parborg <darkdefende@gmail.com>
Date: Fri Jul 3 21:22:41 2020 +0200
Clang-tidy: Enable braces-around-statements warning
commit 185fe9cd8b
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 3 18:55:32 2020 +0200
Cleanup: compiler warning
commit 46fcc12e83
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 3 18:54:04 2020 +0200
Fix error in new Hair data type file reading
commit d2db481dc7
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 18:04:40 2020 +0200
Cleanup: Blendkernel, Clang-Tidy else-after-return fixes (incomplete)
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/blenkernel` module. Not all warnings are
addressed in this commit.
No functional changes.
commit a21cb22f8b
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 11:58:43 2020 -0400
Cleanup: Deduplicate code for finding context object
Instead of manually checking the pinned object, use the existing
ED_object_active_context function. This requires adding const
to the context in that function.
commit 33a74941c5
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:30:31 2020 +0200
Cleanup: Editors, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors` module.
No functional changes.
commit 367034f210
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:30:09 2020 +0200
Cleanup: Editors/Space/UV-Edit, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/uv_edit` module.
No functional changes.
commit 651d1aa7c8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:25:04 2020 +0200
Cleanup: Editors/Transform, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/transform` module.
No functional changes.
commit 35ce16939c
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:58 2020 +0200
Cleanup: Editors/Space/sequencer, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_sequencer` module.
No functional changes.
commit a201020cd3
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:41 2020 +0200
Cleanup: Editors/Space/Clip, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_clip` module.
No functional changes.
commit f254f66587
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:22 2020 +0200
Cleanup: Editors/Space/Outliner, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_outliner` module.
No functional changes.
commit 3aa53b361d
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:08 2020 +0200
Cleanup: Editors/Space/Node, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_node` module.
No functional changes.
commit bf532b1106
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:19:13 2020 +0200
Cleanup: Editors/Space/Text, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_text` module.
No functional changes.
commit 2f6fc5a7e8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:18:56 2020 +0200
Cleanup: Editors/Space/View3D, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_view3d` module.
No functional changes.
commit b61ecb785c
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 16:34:57 2020 +0200
Cleanup: Explicit return in each `else if` block in `buttons_context()`
This is a similar change as in rB4283da83cc9.
No functional changes.
commit f43fedd400
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 17:35:31 2020 +0200
Cleanup: remove side effect in assertion
commit 4a48939f04
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 11:18:24 2020 -0400
UI: Fix bevel modifier not showing vertex group
commit cad2d32be6
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 17:09:24 2020 +0200
Clang-Tidy: Enable bugprone-misplaced-widening-cast
commit 4a5389816b
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 17:07:01 2020 +0200
Clang-Tidy: enable readability-named-parameter
commit fac2e63bc0
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 16:57:55 2020 +0200
Fix utterly broken code regarding GPUtextures of MovieClip in readfile.c
Treat those as pure runtime code, reset to NULL by reading code, for
now.
Think those could be handled like Image gputextures (i.e. considered
runtime cache and preserved across undo steps), but probably not
critical for now.
commit 1bdabd7b4f
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 16:55:13 2020 +0200
Move MovieClip to new undo cache management system.
commit 1019c9f582
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 16:54:08 2020 +0200
Clang-Tidy: enable bugprone-too-small-loop-variable
commit 883f9dd6e5
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 16:48:04 2020 +0200
Clang-Tidy: enable bugprone-assert-side-effect
Looks like we have no assertions with side effects.
commit 9739fc4d1b
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 16:44:46 2020 +0200
Clang-Tidy: More fixed of redundant check before delete
For some reason got unnoticed in the original cleanup pass.
commit 14fd91e7e8
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 16:38:01 2020 +0200
Clang-Tidy: enable bugprone-argument-comment
It was called `inverted` in the header.
commit f4fdb8efc5
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:38:49 2020 -0400
Cleanup: Remove redundant logic
commit f66aafa391
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:37:58 2020 -0400
Fix memory leak when dragging shaderfx
commit f891d4e2ad
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 16:32:12 2020 +0200
Clang-Tidy: Fix readability-delete-null-pointer warnings
Also enable it in the configuration.
commit 53d41e1a6f
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:28:13 2020 -0400
UI: Use sliders and [0, 1] ranges in ocean modifier
The ocean modifier has two properties that use a [0, 10] hard min and
hard max. The values act as factors though, so it makes more sense to
use sliders and a 0 to 1 range.
This commit also bumps the file subversion to avoid repeatedly applying
the change to the properties' range.
Differential Revision: https://developer.blender.org/D8186
commit 2a39b34a09
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 16:09:51 2020 +0200
Cleanup: Editors/Sculpt/Paint, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/sculpt_paint` module.
No functional changes.
commit fd5b093f84
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 16:01:15 2020 +0200
Cleanup: Editors/Screen, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/screen` module.
No functional changes.
commit 4283da83cc
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 15:59:48 2020 +0200
Cleanup: Explicit return in each `else if` block in `ed_screen_context()`
The `ed_screen_context()` function is approximately 700 lines long, and
its main structure is a huge chain of `else if` statements. Some of the
bodies did not return, but rather fell through and relied on the `return
-1;` at the bottom of the function. This means that in order to truly
understand what is going on in one of those `else if` blocks, it could
be required to scroll past all the following `else if` blocks,
double-checking that they all had an `else`, and then see what happens
below.
By adding explicit `return -1;` everywhere this happened, this is all
avoided, increasing local understandability of the code. Furthermore, it
makes the upcoming cleanup with the Clang-Tidy rule
`readability-else-after-return` a lot easier to do.
No functional changes.
commit de7c9f41e6
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 15:42:22 2020 +0200
Cleanup: Editors/Object, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/object` module.
No functional changes.
commit 19483125f8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 15:19:52 2020 +0200
Cleanup: Editors/Mesh, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/mesh` module.
No functional changes.
commit 7d0a0b8a6d
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 14:52:32 2020 +0200
Cleanup: Editors/Armature, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/armature` module.
No functional changes.
commit f82e52ebc8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 14:51:19 2020 +0200
Cleanup: Editors/Animation, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/animation` module.
No functional changes.
commit 17ba566018
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Fri Jul 3 02:15:54 2020 +0200
Fix Pose Brush crashing after disabling connected only in FK mode
This function was returning the ik_chain before disabling the
fake_neighbors, so when the brush was used again with fake neighbors
disabled after rebuilding the PBVH and free them, they were still
enabled in the SculptSession, causing a the crash.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8195
commit 3a59c184b9
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 16:09:58 2020 +0200
Move Scene's cache management during undo to new system.
commit a33756d783
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:09:19 2020 -0400
Cleanup: Unused variables in non-debug build
commit 6a58e15548
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:03:16 2020 -0400
Cleanup: Remove obsolete code in interface_panel.c
Some code delt with panel merging in earlier versions of Blender,
which is no longer needed. Other code delt with controls that aren't
used anymore, and in some cases have region-level equivalents.
There's a surprising amount of this unused code in this file, so removing it
will be helpful for the future.
Differential Revision: https://developer.blender.org/D7938
commit 88d358902f
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 15:54:55 2020 +0200
Clang-Tidy: Enable readability-redundant-string-cstr
commit 405e6c6cc9
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Fri Jul 3 15:53:44 2020 +0200
Fix T78555: GPencil bake animation operator loose frame setting
The values were reset for each run
commit 19ff145e66
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 09:41:55 2020 -0400
Clang-Tidy: Enable readability-redundant-control-flow
commit ffef562bf7
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 15:31:23 2020 +0200
Disable clang-tidy for code-generated RNA files
This needs some extra care, which is probably easier once the initial
pass over integration is done.
commit c9975088a9
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 15:27:12 2020 +0200
Move volume to new cache management system for undo.
commit 1e255ce031
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 15:27:02 2020 +0200
Fix T72214: Fluids: noise does not work with negative frame numbers
The issue is duplicated code. There are two functions that zero-fill
the frame number. They worked the same for positive frames numbers, but
behaved differently for negative ones.
On frame `-100`, `BLI_path_frame` outputs `-0100` and
`fluid_cache_get_framenr_formatted_$ID$` outputted `-100`.
I changed the behavior of the latter, because we depend on the behavior
of the former for much longer already.
Reviewers: sebbas
Differential Revision: https://developer.blender.org/D8107
Starting to use floating filters to avoid expensive gmp operations
when possible. These changes speed up the sphere-sphere test with
n=64 to 5s (now 17 times slower than BMesh on this test, down from
100 times slower. But answer is correct.
Also make format.
Intersection of my spheresphere test with n=16 (two uvspheres
with 16 rings and 32 segments overlapping), time went from
12.8 seconds to 2.3 seconds on my Mac. The n=32 test went from
195.1s to 8.9s.
commit 622aa7bc5015cc3b85deb0eb13b7b315169569b4
Author: Howard Trickey <howard.trickey@gmail.com>
Date: Sun Jul 12 21:09:59 2020 -0400
Provided noexcept move contructors for many types.
Needed because now a static assert trips when making Arrays
or Vectors of these types.
commit 7a7dd53bca36506fb51788cad0444dcb491b3c13
Merge: 74c56382b8f319eec881
Author: Howard Trickey <howard.trickey@gmail.com>
Date: Sun Jul 12 19:22:24 2020 -0400
Merge branch 'master' into boolmerge
commit f319eec881
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 11:05:43 2020 +0200
Cleanup: disable debug code
commit 30ed51d60a
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:50:19 2020 +0200
Cleanup: unused debug variable
commit 21b20ae5ec
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:38:57 2020 +0200
Particles: initial support for forces in simulation node trees
The force node can now be used to control the behavior of particles.
Forces can access particles attributes. Currently, there are three attributes:
`Position` (vector), `Velocity` (vector) and `ID` (integer).
Supported nodes are: Math, Vector Math, Separate Vector, Combine Vector and Value.
Next, I'll have to split `simulation.cc` into multiple files and move
some stuff out of blenkernel into another folder.
commit ebf9082e1c
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:38:30 2020 +0200
Nodes: support more implicit conversions in simulation node tree
commit 838b1742fb
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 12:38:03 2020 +0200
Functions: minor improvements
commit 404486e66c
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 12 10:01:37 2020 +0200
Functions: minor api improvements
commit ee5c2f6ead
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 11 20:41:21 2020 +0200
GPencil: Replace "ShaderFX" with "Shader Effects" in RNA prop text
commit c7eada103c
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 18:02:06 2020 +0200
Nodes: support implicit conversions and incorrectly linked sockets
commit 06401157a6
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 17:59:43 2020 +0200
Fix: incorrect attribute type in network
commit 46b79b3d4a
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:55:57 2020 +0200
Nodes: support vector math node in simulation node tree
commit b920875893
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:47:53 2020 +0200
Nodes: support math node in simulation node tree
commit 8fae58ce0b
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:39:17 2020 +0200
Nodes: support Value node in simulation node tree
commit 16d4373158
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 11 16:24:53 2020 +0200
Nodes: move Math, Vector Math and Value shader nodes to c++ files
This required a little bit of refactoring, because we were using c-only
syntax for the gpu shader names. All tests are still passing.
commit 415d3ee05b
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 22:03:27 2020 +1000
UV: add path select operator that uses the selection
Instead of using the mouse cursor position,
this selects between existing selected elements.
Access this since picking a selection path doesn't
work from the menu.
commit 6e698653df
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 20:34:17 2020 +1000
Cleanup: remove unused function
commit 651db1b26f
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 15:10:05 2020 +1000
Cleanup: spelling
commit 020e0f11ff
Author: Campbell Barton <ideasman42@gmail.com>
Date: Sat Jul 11 14:50:47 2020 +1000
Docs: remove reference to PYTHONHOME
This is no longer used by default, when '--python-use-system-env' is set
there are many Python environment variables, don't list them in
Blender's help message.
commit d2b910fafe
Author: Aaron Carlisle <carlisle.b3d@gmail.com>
Date: Fri Jul 10 16:07:31 2020 -0400
UI: UV: Add Select Shortest Path to menu
This matches the 3D Viewport
commit 3dc0178390
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 20:00:20 2020 +0200
Fix T78662: Cycles baking fails if denoising is enabled, after recent changes
This is not supported yet.
commit 6fbacd6048
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 19:56:53 2020 +0200
Fix build error building without OpenImageDenoise
commit 48f10319c6
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 18:40:35 2020 +0200
Fix T78801: Eevee missing setting to enable/disable freestyle per view layer
This was only visible when Cycles was enabled.
commit 4e8fc15586
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 10 12:21:32 2020 -0400
UI: Improve transform constraint layout
- Remove the "mapping" subpanel and moves the source axis
selection ot the destination subpanel.
- Rename "Source" and "Destination" to "Map From" and "Map To" to
make the action more clear
- Gray out source axes when their data isn't selected.
These changes were discussed in D8041.
commit 3e4f49fe71
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 18:02:51 2020 +0200
Revert "Fix T78296: Performance - Use Binary Search for MDeformWeight"
This reverts commit 39b525e0f0 and
3121015dce as tests are failing.
commit d5208c45fa
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Fri Jul 10 17:56:05 2020 +0200
GPencil: Fix unreported Use Falloff curve for active frame not working
For the active frame it was using always a value of 1.0 and it was not using the curve.
commit 6eeb32706a
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 12:20:07 2020 +0200
Cycles: support OpenImageDenoise in final renders
Performance is not great currently due to the API not seeming to support
efficient denoising of multiple tiles at the same time. So in many cases
only one or a few threads will actually be denoising at the same time.
In renders with many samples this is not a big problem, but for faster
renders it's a signficant overhead.
We should try to optimize this still, possibly by batching denoising of
a bigger neighborhood of multiple tiles at once.
commit 93791381fe
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 20:01:22 2020 +0200
Cleanup: reduce hardcoded numbers in denoising neighbor tiles code
commit e65c78cd43
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 18:54:42 2020 +0200
Cleanup: minor refactoring in Cycles update detection code
commit ad45b8d6a4
Author: Milan Jaros <jar091>
Date: Fri Jul 10 11:49:52 2020 +0200
Cycles: optimize camera inside volume tests
Only run when there are volumes in the scene, and compute in parallel.
Ref T56939
Differential Revision: https://developer.blender.org/D8261
commit d8e648c352
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 10 17:09:35 2020 +0200
Fix T78776: Cycles OpenCL error after recent changes for holdouts
commit 9dbe9a753a
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 16:50:26 2020 +0200
Fix T78766: Blender crashes after deleting vertices with Custom Normals.
Some core BMesh topology changing functions were not properly tagging
custom normal runtime caches as dirty...
commit 5372924983
Author: Richard Antalik <richardantalik@gmail.com>
Date: Fri Jul 10 16:14:10 2020 +0200
Fix T78579: Proxy produces wrong preview when using Offset or Crop
Make sure that proxy and original images are scaled to same size before
applying offset or crop.
During testing, I discovered, that raw cache will lose information whether
this image was proxy or not. Because of this, proxy images will not create
this cache type. It would be fairly easy to implement this functionality for
cache, but I have decided to not do it now, because I did not want to pass yet
another mostly hard-coded bool flag to cache system. Since image is proxy, it
should be fast to read anyway.
In case of using offset property, code was modified to make sure we scale
image only once. I also tried to make code more readable and streamlined and
cleaned up surrounding functions a bit.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8203
commit 77f823a240
Author: Richard Antalik <richardantalik@gmail.com>
Date: Fri Jul 10 15:57:28 2020 +0200
Fix T78573: Crash when removing strips with prefetching
Stop prefetching before changing content of seqbase.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8256
commit 47e71f4623
Author: Richard Antalik <richardantalik@gmail.com>
Date: Fri Jul 10 15:53:57 2020 +0200
Fix T69440: Memory leak adding strips via python
seq->strip was overwritten in python API function.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8204
commit cbfedf2139
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 15:53:36 2020 +0200
BLI: add C++ random number generator
This adds `blender::RandomNumberGenerator` in `BLI_rand.hh`.
Furthermore, `RNG` is now implemented in terms of this new generator.
No functional changes are expected, the generated random numbers
are not changed by this commit.
Reviewers: campbellbarton, brecht
Differential Revision: https://developer.blender.org/D8259
commit c2304d2f02
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 15:29:03 2020 +0200
Expose override flags to python RNA properties definition.
Time will tell whether we need to expose more RNA override flags here.
Implements/Fix T78534.
Differential Revision: https://developer.blender.org/D8250
commit 4d1c3c029e
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 08:37:35 2020 +0200
Cleanup: declaration and implementation function signature did not match
commit f93e0f1a9e
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 15:23:52 2020 +0200
Refactor override code to properly deal with runtime rna properties too.
The triplet static RNA / runtime RNA / custom properties is a real pain to
deal with...
Using the new `PropertyRNAOrID` struct helps clarifying and properly
dealing with all three cases.
Note that this makes override of py-defined RNA properties working
(support for that will be committed next).
Differential Revision: https://developer.blender.org/D8249
commit 337e2c9029
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 15:19:40 2020 +0200
RNA: refactor how we get 'ensured' RNA properties.
Introduce new PropertyRNAOrID structure, storing most useful data about
an 'opaque' PropertyRNA in relation with a given PointerRNA struct.
It deals with all the three cases (pure static RNA, runtime RNA where
data is actually stored in IDProperties, and pure IDProperties, aka
custom data.
commit 6c1157201a
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 22:59:12 2020 +1000
Cleanup: simplify platform define checks
Platforms besides WIN32 were in a single else clause, use elif instead.
commit 45287f909c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 22:58:30 2020 +1000
Fix for building on systems besides apple/windows/linux
commit 26d28ade26
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:40:23 2020 +0200
Cleanup: follow code style
commit c806db6313
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:22:35 2020 +0200
Functions: add utility to find dependencies of input sockets
commit 60133ff98d
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:20:39 2020 +0200
Functions: store derived node tree and network in map for future access
commit 295b3aefb0
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:19:45 2020 +0200
Functions: make constant folding work on unfinished networks
commit 7bae599232
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 14:18:51 2020 +0200
Nodes: add redundant name check in debug builds to prevent errors
commit 3121015dce
Author: Jeroen Bakker <jeroen@blender.org>
Date: Fri Jul 10 13:37:12 2020 +0200
Fix Crash due to recent changes
{39b525e0f07fa25dcda54226ade789959b642dec} could write in unallocated
space.
commit 00eb6a56aa
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Fri Jul 10 13:30:08 2020 +0200
GPencil: Fix tooltip error
The tooltip was copied by error from Lattice modifier.
commit 8fd65a2252
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:56:57 2020 +0200
Functions: use new is-equal and hash function of CPPType
commit 3edd2832b2
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:54:19 2020 +0200
Functions: make generic types hashable
commit f62204718b
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:53:50 2020 +0200
BLI: initial hash function for Color4b and float4x4
commit 8f6c0f2242
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:41:51 2020 +0200
Functions: make generic types equality comparable
commit 52636c3059
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:36:06 2020 +0200
Cleanup: various cleanups in for CPPType
commit 39b525e0f0
Author: Jeroen Bakker <jeroen@blender.org>
Date: Fri Jul 10 12:05:31 2020 +0200
Fix T78296: Performance - Use Binary Search for MDeformWeight
Use binary search for querying deform weights.
Spring 02_020_A.anim.blend on Ryzen 1700X goes from 12.4 to 12.7fps.
During profiling it was detected that adding new items to the head was faster than adding to the tail.
Reviewed By: Campbell Barton
Differential Revision: https://developer.blender.org/D8127
commit 77a646279d
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 10 12:04:32 2020 +0200
Cleanup: structure CPPType according to code style guide
commit 9c25731781
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 10 11:53:11 2020 +0200
LibOverride: Fix improper tagging of more of the backward pointers in RNA nodetrees.
commit 582a0b7e5a
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 19:02:18 2020 +1000
Fix T78756: White UV drawing is displayed as Dashed
commit 7a9028cad1
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 18:58:36 2020 +1000
Fix UV rip failing to disable proportional edit-mode
commit a148c4676b
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 16:04:09 2020 +1000
Cleanup: spelling
commit 03f5acd445
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 16:03:12 2020 +1000
Cleanup: clang-format
commit 8b660ea0ec
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 13:36:16 2020 +1000
Fix UV path redo in vert/edge mode
Redo was only working in some situations,
some options were also not being forwarded.
commit 96068324cd
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 13:35:44 2020 +1000
Fix BM_loop_at_index_find lookup
commit 89cb41faa0
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:55:59 2020 +1000
UV: allow ripping face-regions
This changes the behavior of rip when entire faces are selected.
Now face regions are isolated and moved instead of ripping the edge-loop
extracted from the selection boundary.
This is a convenient alternative to separate selection & move.
Resolves T78751.
commit 3fdd092649
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:38:28 2020 +1000
Cleanup: face-center mesh calculation
Loop over faces and calculate their centers instead of zeroing the
face center array and accumulating all faces vertex corners.
Move subsurf face center extraction into it's own loop since it works
differently.
commit b0378440ce
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:18:43 2020 +1000
Fix missing adjacent UV check for recent UV path select
Path selection could cross UV islands if the destination element was
on an island boundary.
commit 8f24ec2e26
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 12:04:29 2020 +1000
Cleanup: add BLI_linklist_find_last
This makes adding to the end of a linked list simpler,
In most cases we avoid this in favor of BLI_linklist_append.
For one off operations it's OK.
commit 3dd460aa7f
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:41:14 2020 +1000
Cleanup: spelling
commit a0d3b60015
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:46:26 2020 +1000
Cleanup: use FLT_MAX for the maximum path selection cost
A large number below FLT_MAX was used to avoid overflow,
however this doesn't cause any problems.
commit 0b77e2f4c4
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:31:41 2020 +1000
Cleanup: variable names, use define for maximum path cost
commit 92bc277950
Author: Campbell Barton <ideasman42@gmail.com>
Date: Fri Jul 10 11:40:38 2020 +1000
Cleanup: undeclared warnings
commit 3623db7784
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 19:03:50 2020 +0200
BLI: add more operator overloads for float2
commit 03a00bda2b
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Thu Jul 9 17:16:24 2020 +0200
Sculpt: Make Sculpt Vertex Colors features experimental
This disables all Sculpt Vertex Colors tools, operators, panels and rendering capabilities and puts them under the "Use Sculpt Vertex Colors" experimental option.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8239
commit 1e3247c078
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 18:19:39 2020 +0200
Fix: add missing extern "C"
commit a90b69d065
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 18:04:13 2020 +0200
Build: add more libc compatibility functions for upcoming libraries update
These are needed by the x264 library.
commit 6778949e01
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Thu Jul 9 17:56:00 2020 +0200
Fix repeated Face Sets IDs when joining meshes
As Face Sets IDs start from 0 and increase by 1 each time a new face set
is created in a mesh, when joining multiple meshes it could happen that
the same ID is used by several unrelated areas in multiple objects. This
checks the Face Sets IDs when joining meshes and ensures that they are
not repeated between different objects when joining them, so in the
resulting mesh all previous face sets will have different IDs.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8224
commit 7b1c406b54
Author: Bastien Montagne <bastien@blender.org>
Date: Thu Jul 9 15:33:34 2020 +0200
Implement T77959: Never duplicate linked data during deep-copy.
Note that this behavior is enforced on user level for now, but on code
side it is controlled with a flag, which should make it easy to refine
that behavior if needed.
Only exception is when we duplicate a linked ID directly (then we assume
user wants a local deep-copy of that linked data, and we always also
duplicate linked sub-data-blocks).
Note that this commit also slightly refactor the handling of actions of
animdata, by simplifying `BKE_animdata_copy_id_action()` and adding an
explicit new `BKE_animdata_duplicate_id_action()` to be used during ID
duplication (deep copy).
This also allows us to get rid of the special case for liboverrides.
commit 78b629a98f
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Wed Jul 8 18:10:31 2020 +0200
Sculpt: Skip fully hidden nodes in sculpt tools
As tools iterators skip not visible vertices, fully hidden nodes can
also be skipped and considered as masked.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8244
commit 1fb667da01
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Tue Jul 7 23:01:51 2020 +0200
Fix wrong upate flag when updating the PBVH visibility
This function was using the wrong flag to update the visibility state of
the nodes, so I assume that most of the partially visible optimizations
were not working.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8243
commit e5ebaa9fd6
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Wed Jul 8 17:22:11 2020 +0200
Fix T78664: Implement Mesh and Face Set boundary automasking in Multires
This implements the SCULPT_vertex_is_boundary and SCULPT_vertex_has_unique_face_set functions for PBVH_GRIDS, which makes features such as automasking now work in multires. It also fixes some other face sets related features in multires, like face set boundary smoothing.
This uses the BKE_subdiv_ccg_coarse_mesh_adjacency_info_get function to get the vertex indicies in the base mesh from multires. This way the API functions can get topology or face set information directly from it. In the future, these vertex indices can be used to get any other information from the base mesh from multires, like seams, sharp edges, disconnected elements IDs...
Reviewed By: sergey
Maniphest Tasks: T78664
Differential Revision: https://developer.blender.org/D8227
commit bd84b2cbcc
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Sat Jul 4 18:28:40 2020 +0200
Fix Sculpt Vertex Colors sample color changing brush alpha
It is not practical to change the alpha of the paint color with the
color picker as with the current brush design alpha is the main strength
control for the brush.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8208
commit 13b1374497
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Thu Jul 9 17:41:04 2020 +0200
Fix crash when using Mask by Color in Multires
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8207
commit 78d48343ae
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Thu Jul 9 15:59:57 2020 +0200
Make deps: Fix compilation error on CentOS
There were two issues.
First is related on ISPC's CMake configuration forcing C and C++
compilers to be clang and clang++. This goes against of desired
behavior when we use our own compiled clang compilers.
The second issue was related on linker failure: CLang libraries
are linked statically, and they need some of C++ 11 STL symbols
which are coming from libstdc++.
Differential Revision: https://developer.blender.org/D8258
commit 2be0ae7c99
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 16:51:48 2020 +0200
Fix Cycles unnecessary updates to camera in viewport render
Problem identified by Milan Jaros.
commit 9de09220fc
Author: Szymon Ulatowski <szulat>
Date: Thu Jul 9 17:19:52 2020 +0200
EEVEE: Implement the missing Sky texture
I'm not sure if the Sky was deliberately left out or was just waiting for a
better moment, but so many I was disappointed that Sky in EEVEE is
completely white.
There are already 2 implementations (osl and gpu) so this is the third one.
Looking at other cases it seems that we are not supposed to share sources
between cycles and the rest? So the new util_sky_model files are just
copies of what is already in cycles, except that the data file uses the RGB
variant of the Hosek/Wilkie model, because we output RGB anyway (but can be
easily changed to XYZ if desired - the results are nearly identical).
I am not sure if it is okay to pass 3*9 float values as 3 mat4 uniforms (I
wanted to use mat3 but it does not work).
Also, should I cache the sky model data between renders if the parameters
do not change?
Reviewed By: fclem, brecht
Differential Revision: https://developer.blender.org/D7108
commit 42c99ec15b
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 16:37:44 2020 +0200
BLI: rename rand.c to rand.cc
commit 580d50091c
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 15:40:27 2020 +0200
Particles: Create a simulation state for every Particle Simulation node
Every Particle Simulation node has a name (or a path when it is in a node group).
This name has to be used in the Simulation modifier on a point cloud to see
the particles.
Caching has been disabled for now, because it was holding back development
a bit. To reset the simulation, go back to frame 1.
Currently, there is no way to influence the simulation. There are just some
randomly moving points. Changing that is the next step.
commit 31ad43a3c7
Author: Jacques Lucke <jacques@blender.org>
Date: Thu Jul 9 15:29:25 2020 +0200
Blenloader: make BLO_read_data_address work in C++
commit 544c435fdd
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 9 12:20:07 2020 +0200
Fix T78745: Cycles error baking with multiple materials
commit 8ddf7556a5
Author: Bastien Montagne <bastien@blender.org>
Date: Thu Jul 9 11:44:11 2020 +0200
Fix T78718: Crash when deleting particle system modifier with the X Shortcut.
Duplication and deletion code of modifiers was totally wrong for
particle system, that special weird thing needs its own custom
management.
Note that for now I chose not to duplicate the particle settings ID when
duplicating the modifier...
commit ea5fe7abc1
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 17:29:17 2020 +1000
UV: path selection support
This adds support for path selection for vertex edge & face selection
modes, matching mesh editing behavior, useful with the UV rip tool.
Region select & edge tagging are currently not supported,
although they could be added eventually.
commit 0b8221683f
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 9 18:23:16 2020 +1000
BMesh: add utility functions
- BM_edge_uv_share_vert_check
- BM_face_uv_calc_center_median_weighted
- BM_loop_at_index_find
commit 0b3bf69d3c
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 9 13:33:15 2020 +1000
Cleanup: move BMesh UV queries into their own file
commit 754c5d6a14
Author: Campbell Barton <ideasman42@gmail.com>
Date: Thu Jul 9 13:29:48 2020 +1000
Cleanup: clang-format
commit 31bc76ea4e
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 22:29:10 2020 +0200
Cleanup: remove unnecessary calls to as_span
This uses the new implicit conversions and constructors
that have been committed in the previous commit.
I tested these changes on Linux with gcc and on Windows.
commit 403384998a
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 22:27:25 2020 +0200
BLI: improve constructors and conversions to span
This allows us to avoid many calls to `as_span()` methods. I will
remove those in the next commit. Furthermore, constructors
of Vector and Array can convert from one type to another now.
I tested these changes on Linux with gcc and on Windows.
commit 4b85ed819d
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 20:41:00 2020 +0200
Cleanup: remove unused function
This is not necessary in C++17 anymore.
commit f7d5d4ee3b
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 20:39:12 2020 +0200
Cleanup: use c++17 helper variable templates
commit e4926c167b
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 8 18:08:08 2020 +0200
Fix T78718: Crash when deleting particle system modifier with the X Shortcut.
Again those backward pointers not properly flagged in RNA, hence
generating infinite loops.
commit f4a39cafa1
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 17:05:40 2020 +0200
Functions: add AttributesRef class
This is the same as MutableAttributesRef, but the data in it cannot be changed.
commit 439c238bb4
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 17:04:50 2020 +0200
Cleanup: use different internal socket name
commit 05365d1376
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 17:04:09 2020 +0200
Functions: support hashing MFDataType and CPPType
commit 2de5de57c5
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Wed Jul 8 15:03:06 2020 +0200
Build: fix stack linker warning with ffmpeg on macOS
The ff_cfhd_init_vlcs() function was using a lot of stack space, which
made linker on macOS unhappy. Using heap allocation allows to silence
the warning without causing other side-effects.
Kept the patch enabled for all platforms to avoid difference in behavior
and performance on different platforms, which could make certain types
of investigation very tricky.
Differential Revision: https://developer.blender.org/D8248
commit cb3c4218bf
Author: Bastien Montagne <bastien@blender.org>
Date: Wed Jul 8 15:43:57 2020 +0200
Minor cleanup in rna override code.
commit d1f4546a59
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:10:24 2020 +0200
Functions: implement common subnetwork elimination optimization
This was the last of the three network optimizations I developed in
the functions branch. Common subnetwork elimination and constant
folding together can get rid of most unnecessary nodes.
commit e3e42c00cb
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:06:32 2020 +0200
Functions: Support getting MFSocket based on its id
commit 2b9d62b73a
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:06:04 2020 +0200
Functions: Support accessing socket index of MFSocket
commit 34d175f372
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:04:28 2020 +0200
Functions: initial hash/equals implementation for constant multi-functions
commit 840941215d
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:02:47 2020 +0200
Functions: allow multi-functions to override a hash and equals function
commit 36a547af7b
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 15:01:33 2020 +0200
Cleanup: add correct license header to tests
commit ff133bbd33
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 14:57:31 2020 +0200
BLI: add disjoint set data structure
This can be used to find separate islands in meshes efficiently (as is
done in cycles already). Furthermore, this helps to implement some
algorithms on node trees more efficiently.
commit a8ff8b64dc
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 14:40:34 2020 +0200
BLI: add comparison operators and hash functions for float3, etc.
commit ff444da7c4
Author: Brecht Van Lommel <brecht@blender.org>
Date: Thu Jul 2 12:28:57 2020 +0200
macOS: upgrade minimum required version to 10.13 High Sierra
C++17 does not work on 10.12, and Apple extended support ended for 10.12 in
October 2019.
Maniphest Tasks: T76783, T76184
Differential Revision: https://developer.blender.org/D8179
commit 6435acd8f6
Author: Brecht Van Lommel <brecht@blender.org>
Date: Wed Jul 8 12:57:59 2020 +0200
Cycles: support shader transparency for holdout objects
Now transparent areas of the object will render objects behind.
Fixes T78728.
commit 643196cc37
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Wed Jul 8 11:04:49 2020 +0200
CMake: Fix spelling of Embree passed to find package
The spelling and capitalization of package name passed to find_package()
and find_package_handle_standard_args() needs to match.
Silences CMake warning about mismatch.
Differential Revision: https://developer.blender.org/D8247
commit 45004d82e0
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 11:18:43 2020 +0200
Functions: add dead node removal and constant folding optimization
Those optimizations work on the multi-function network level.
Not only will they make the network evaluation faster, but they also
simplify the network a lot. That makes it easier to understand the
exported dot graph.
commit 50d7c00d9c
Author: Jacques Lucke <jacques@blender.org>
Date: Wed Jul 8 10:16:56 2020 +0200
Cleanup: fix comment
commit 01c8aa12a1
Author: Alexander Gavrilov <angavrilov@gmail.com>
Date: Wed Jul 1 17:38:07 2020 +0300
Apply Modifier: support applying as shape key and keeping the modifier.
This can be useful to save the result of a cloth simulation as a
shape key without destroying the simulation, so it's possible to
e.g. re-run it to get other shapes, or simply use the new shape
key to start the simulation already in a draped state.
It also makes sense to allow applying as shape key even when the
mesh is shared, because the operation itself just adds a shape
key. To support this, split the apply operator into Apply and
Apply As Shapekey so that they can have different poll callbacks.
Differential Revision: https://developer.blender.org/D8173
commit 7fcb6bc59c
Author: Lukas Stockner <lukas.stockner@freenet.de>
Date: Wed Jul 8 02:10:02 2020 +0200
Fix T78324: Different Sky Texture results between CPU and GPU
The problem here was numerical precision: The code calculates the angle between
sun and view direction, and the usual acos(dot(a, b)) approach for that has
poor numerical performance for almost parallel angles.
As a result, the generally tiny difference between floating point computation
between CPU and GPU was enough to make the sun vanish at different radii,
causing different results.
The new version fixes the difference by making the computation much more robust
on both platforms.
commit afcb41a0aa
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 20:32:40 2020 +0200
BLI: simplify copy constructor of Array
commit eb5fb1741d
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 20:29:35 2020 +0200
Cleanup: don't end description with a '.'
commit 8713109212
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 20:27:34 2020 +0200
Cleanup: fix typo
commit 902ee4d13c
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 19:46:10 2020 +0200
Functions: cleanup loop that traverses the MFNetwork
commit 22158162ef
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 19:34:35 2020 +0200
Functions: add generic functions that output constants
commit f4633cf46c
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 19:16:31 2020 +0200
BLI: simplify copy constructor of vector
commit 67042aa6a1
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:45:34 2020 +0200
Functions: extend multi-function network api
commit adfae89f96
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:40:42 2020 +0200
BLI: provide access to underlying node in dot exporter
commit a8627ea66d
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:39:24 2020 +0200
Functions: Add debug print and destruct callback to CPPType
commit 4990e4dd01
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 18:23:33 2020 +0200
Nodes: Generate multi-function network from node tree
This adds new callbacks to `bNodeSocketType` and `bNodeType`.
Those are used to generate a multi-function network from a node
tree. Later, this network is evaluated on e.g. particle data.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D8169
commit ff97545c50
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Tue Jul 7 18:37:35 2020 +0200
Fix T75943 EEVEE: Cubemaps shows black
Caused by faulty driver implementation. Force fallback method.
commit 1e2ff4f81b
Author: Hans Goudey <h.goudey@me.com>
Date: Tue Jul 7 11:10:42 2020 -0400
Cleanup: Add braces for clang tidy
commit 0edf2fc128
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 16:51:03 2020 +0200
BLI: Correct spin lock definition
The MSVC atomic function is defined for an unsigned type.
Not sure why this became an issue after switch to TBB by default,
maybe some CFLAGS changed to be more strict after that.
commit dad3de89dc
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 7 11:27:09 2020 -0300
Fix: remove accidental code
`v1` and `v2` are already set.
commit d352902758
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 11:16:31 2020 +0200
Make deps: Use own nasm for ffmpeg and x264
Fixes the warning: building for macOS, but linking in object file
Differential Revision: https://developer.blender.org/D8235
commit 1e3c0b4b03
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 10:47:09 2020 +0200
Make deps: Compile own version of nasm for Apple
The upstream version of nasm does not put version information to the
generated object files, which makes linker to show the following
warning:
building for macOS, but linking in object file
Using own patched version of nasm which puts required information to
the object file, making linker happy.
The plan is to either streamline the patch and provide it to the
upstream, or, it that takes too long, get an independent fix from the
upstream.
commit 202e7ccaae
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 14:33:59 2020 +0200
Fix T77455: Blender Freezes when using the 3d Scale Gizmo
Issue is reported on Linux ith Intel HD6xx iGPU. Inside
`gpu_select_sample_query.c` the call to `glGetQueryObjectuiv` froze. After
bisecting this lead to the polyline shader. When using a 3d color shader
in stead of the polyline shader during selection seems to fix the issue.
Other parts of blender might also be effective, but I wasn't able to
freeze blender in these areas. When it does, we might want to add
a similar work-around to button2d, cage2d, cage3d & move3d, navigate.
Backport this patch to 2.83.
Reviewed By: Clément Foucault
Differential Revision: https://developer.blender.org/D8217
commit d1dcd2b464
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 16:17:36 2020 +0200
BLI: Fix mistake in SpinLock TBB migration
Copy-paste mistake.
commit 20558848d3
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Tue Jul 7 09:45:53 2020 -0300
Optimization: use `BLI_bvhtree_intersect_plane` to detect faces that will be affected by the knife tool
The knife code currently calls the `BLI_bvhtree_overlap` function that
tests the overlap between the mesh tree and an AABB that encompasses the
points projected in the clip_start, clip_end and or clip_planes of the
view.
This resulted in many false positives since the AABB is very large.
Often all the triangles "overlapped".
The solution was to create a new function that actually tests the
intersection of AABB with a plane.
Even not considering the clip_planes of the view, this solution is more
appropriate than using overlap.
Differential Revision: https://developer.blender.org/D8229
commit 630c6226e2
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Tue Jul 7 16:26:01 2020 +0200
Fix T78307 UI: Drawing artifacts in the Blender UI on macOS
This was due to a bad driver which was not respecting this bit of the
specification:
`If the current primitive does not originate from an instanced draw command, the value of gl_InstanceID is zero.`
commit 737bd549b6
Author: Patrick Mours <pmours@nvidia.com>
Date: Mon Jul 6 12:25:54 2020 +0200
Cycles: Add support for native OptiX curve primitive
This patch adds support for the curve primitive from OptiX to Cycles. It's currently hidden
behind a debug option, since there can be some slight rendering differences still (because no
backface culling is performed and something seems off with endcaps). The curve primitive
was added with the OptiX 7.1 SDK and requires a r450 driver or newer, so this also updates
the codebase to be able to build with the new SDK.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D8223
commit 95f0f31279
Author: Brecht Van Lommel <brecht@blender.org>
Date: Tue Jul 7 14:45:31 2020 +0200
Fix T78692: improve UI regarding the effect of the denoiser on denoising passes
It wasn't obvious that the choice of Cycles denoiser also generates different
denoising data passes for compositing.
commit a394aac8b4
Author: Brecht Van Lommel <brecht@blender.org>
Date: Tue Jul 7 14:47:59 2020 +0200
Fix T78666: Cycles non-uniformly scaled hair renders wrong for static objects
Don't apply the matrix transform optimization in this case, curve points and
radius can't represent non-uniform scale the way is possible with triangle
meshes and vertices.
This would cause abrupt change if objects had e.g. motion blur in one frame
and not in the next.
commit 98bee41c8a
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jul 7 14:30:55 2020 +0200
IO: Reversed persistent ID order in exports to Alembic and USD
Each duplicated (a.k.a. instanced) object has a Persistent ID, which
identifies a dupli within the context of its duplicator. This ID
consists of several numbers when there are nested duplis (for example a
mesh instancing empties on its vertices, where each empty instances a
collection). When exporting to Alembic/USD, these are used to uniquely
name the duplicated objects in the export.
This commit reverses the order of the persistent ID numbers, so that the
first number identifies the first level of recursion. This produces
trees like this:
ABC
`--Triangle
|--Triangle
|--Empty-1
| `--Pole-1-0
| |--Pole
| `--Block-1-1
| `--Block
|--Empty
| `--Pole-0
| |--Pole
| `--Block-1
| `--Block
|--Empty-2
| `--Pole-2-0
| |--Pole
| `--Block-2-1
| `--Block
`--Empty-0
`--Pole-0-0
|--Pole
`--Block-0-1
`--Block
It is now clearer that `Pole-2-0` and `Block-2-1` are instanced by
`Empty-2`. Before this commit, they would have been named `Pole-0-2` and
`Block-1-2`.
commit 70b1c09d7a
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jul 7 12:45:30 2020 +0200
IO: Fix bug exporting dupli parent/child relations
Exporting a scene to USD or Alembic would fail when there are multiple
duplicates of parent & child objects, duplicated by the same object. For
example, this happens when such a hierarchy of objects is contained in a
collection, and that collection is instanced multiple times by mesh
vertices. The problem here is that the 'parent' pointer of each
duplicated object points to the real parent; Blender would not figure
out properly which duplicated parent should be used.
This is now resolved by keeping track of the persistent ID of each
duplicated instance, which makes it possible to reconstruct the
parent-child relations of duplicated objects. This does use up some
memory for each dupli, so it could be heavy to export a Spring scene
(with all the pebbles and leaves), but it's only a small addition on top
of the USD/Alembic writer objects that have to be created anyway. At
least with this patch, they're created correctly.
Code-wise, the following changes are made:
- The export graph (that maps export parent to its export children) used
to have as its key (Object, Duplicator). This is insufficient to
correctly distinguish between multiple duplis of the same object by
the same duplicator, so this is now extended to (Object, Duplicator,
Persistent ID). To make this possible, new classes `ObjectIdentifier`
and `PersistentID` are introduced.
- Finding the parent of a duplicated object is done via its persistent
ID. In Python notation, the code first tries to find the parent
instance where `child_persistent_id[1:] == parent_persistent_id[1:]`.
If that fails, the dupli with persistent ID `child_persistent_id[1:]`
is used as parent.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8233
commit f2175e06a7
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 12:43:18 2020 +0200
Mae deps: Ensure Brotli is disabled for FreeType
We don't need it and it was optionally enabled, causing Blender to fail
to link on certain configuration (when Brotli is installed via Homebrew
for example).
commit 02cd159539
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 12:31:10 2020 +0200
Cleanup: add comment explaining operator delete
commit cc311e4a52
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Tue Jun 30 15:13:54 2020 +0200
IO: print export name instead of object name in debug export graph output
This is just a change in `AbstractHierarchyIterator::debug_print_export_graph()`
to aid in debugging. It'll make it possible to distinguish between
different duplicates of the same object.
No functional changes to Blender itself.
commit 5761cb9ee2
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 11:52:45 2020 +0200
Guarded Allocator: add missing operator delete
This resolves warning C4291 on windows.
commit 80fe5e1b15
Author: Johan Walles <walles>
Date: Tue Jul 7 11:09:31 2020 +0200
UI: Add units to motion tracking solve errors
The unit being "pixels".
Before this change the solve errors were unitless in the UI.
With this change in place, the UI is now clear on that the unit of the
reprojection errors is pixels (px).
Differential Revision: https://developer.blender.org/D8000
commit 6d9a6f12b3
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Tue Jul 7 10:06:14 2020 +0200
Make deps: Fix compilation error of Python on macOS
The configuration was confused about gettext installed via Homebrew
and isysroot passed to Python's compilation but not to test programs.
After this change `import gettext` still works, but it is unclear how
to test it further,
Differential Revision: https://developer.blender.org/D8231
commit 955abbeff2
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 09:01:01 2020 +0200
Fix sign conversion error
commit e233ee1c1f
Author: Philipp Oeser <info@graphics-engineer.com>
Date: Thu Jun 25 14:37:22 2020 +0200
Fix T78186: Dyntopo panel error with tools that dont have a brush
Maniphest Tasks: T78186
Differential Revision: https://developer.blender.org/D8120
commit 19d4e265b6
Author: Jacques Lucke <jacques@blender.org>
Date: Tue Jul 7 10:35:28 2020 +0200
Cleanup: remove redundant comments
Searching in these files for "_as" will reveal a comment at the
top, that explains what these methods are for. There is no need
to duplicate that knowledge all over the place.
commit 6e609f0eb0
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 17:50:33 2020 +1000
Cleanup: use doxy comments
commit 62774baded
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 16:06:05 2020 +1000
UI: add merge/split menus
This makes the menus and keymap match the edit-mesh
(M for merge, Alt-M for split).
commit d212b3dc43
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Mon Jul 6 15:28:19 2020 +0200
Make deps: Fixes for macOS platform
Set of fixes which had to be made in order to have dependencies built
on own laptop:
- Require bison as a dependent software. It is required by ISPC.
On macOS it is required to be installed via Homebrew. This is because
Bison from Xcode toolchain is too old.
- Made sure Boost is compiled using clang.
Without this gcc was used, and some unsupported command line argument
was passed to it.
- Modify OGG in a way which does in fact pull fixed sized types.
They are defined in stdint.h.
Without this fix FFmpeg will not detect presence of OGG because the
test program fails to compile.
- Force disable zstd compression and make wepb optional for the TIFF
library. Without this TIFF might pick up development libraries from
Homebrew.
Differential Revision: https://developer.blender.org/D8221
commit b28683b8b5
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 16:03:26 2020 +1000
Cleanup: remove unused arguments
commit 0c58970da7
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 12:44:47 2020 +1000
Cleanup: spelling
commit ad0edc626d
Author: Campbell Barton <ideasman42@gmail.com>
Date: Tue Jul 7 12:43:45 2020 +1000
Cleanup: unused World struct members linfac, logfac
commit e20171e59f
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 16:39:28 2020 -0400
Fix build error with tests for removed functions
These GHash functions were removed in 12817083ec,
so the tests should be removed too.
commit d557f05502
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 16:07:54 2020 -0400
Cleanup: Use bool instead of int
commit 053e0c0af3
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 15:35:21 2020 -0400
UI: Add shortcuts for shader effect panels
Only the delete shortcut applies here, although the move up and down
operators can optionally be assigned in the keymap.
See rB1fa40c9f8a81 for more details and rB5d2005cbb54b for the
grease pencil modifier panel implementation, which is the same.
commit 12817083ec
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 6 14:44:30 2020 -0300
Cleanup: Use the BLI_edgehash API in the sewing simulation of cloths
Also remove the code in the ghash that is no longer used.
This change simplifies the existing code.
Differential Revision: https://developer.blender.org/D8219
commit a856de700b
Author: Hans Goudey <h.goudey@me.com>
Date: Mon Jul 6 13:17:07 2020 -0400
Fix T77730: ShaderFx Missing Update Notifier
This adds a notification type for shaderfx so the properties editor can
be properly notified to redraw.
Another possible solution would be to also redraw the shaderfx tab
with a ND_MODIFIER update, but this solution allows us to avoid
some unecessary redraws too. There were no existing cases of
ND_OBJECT | NC_MODIFIER updates, so those cases were
removed from buttons_area_listener.
Differential Revision: https://developer.blender.org/D8159
commit f6f4043924
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 17:59:04 2020 +0200
BLI: add methods to lookup a stored key in a set
commit 1562c9f031
Author: Patrick Mours <pmours@nvidia.com>
Date: Mon Jul 6 17:32:32 2020 +0200
Fix OptiX viewport denoising not working when rendering scene (without OptiX) that uses unsupported features
Denoising devices do not need to load the full feature set of kernels, so only activate the denoising
feature for them (so that it is possible to use features that are supported by the render devices, but
not the denoising devices).
commit aabfd2fb9b
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 6 16:55:00 2020 +0200
Cleanup: readfile: remove old deprecated OldNewMap for runtime caches.
commit ee3eba902a
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 6 16:21:41 2020 +0200
Runtime cache preservation during undo: add support for nodes and embedded IDs.
commit bfc644dcfb
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Mon Jul 6 16:52:28 2020 +0200
Reduce `DupliObject::persistent_id` from 16 to 8 items
For historical reasons, `DupliObject::persistent_id` was of size
`2*MAX_DUPLI_RECUR`. These reasons are now gone, and the persistent ID
always gets exactly one array element for every dupli-recursion.
Differential Revision: https://developer.blender.org/D8222
Reviewed by: brecht
commit 0b07f9b717
Author: Bastien Montagne <bastien@blender.org>
Date: Mon Jul 6 15:07:12 2020 +0200
Fix T78608: Memory leak in Material properties: "Data from SCE".
Caused by recent own refactor of cache presevation handling in readfile,
EEVEE's lightcache are weird birds that can also be saved in .blend
files, need a special handling for those 'persistent' caches...
commit 99feb10b8b
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 23:01:36 2020 +1000
Cleanup: warning, spelling
commit 20446f07f6
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 22:52:29 2020 +1000
Docs: reference bl_rna_get_subclass_py instead of bl_rna_get_subclass
bl_rna_get_subclass only works for Nodes at the moment.
commit ffaf294c3f
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Mon Jul 6 14:53:39 2020 +0200
Fix alignment/size issue on ARM/RPi architecture
Addresses 964305 from Debian bug tracker.
commit 924578ce19
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 6 09:49:00 2020 -0300
Optimization: Don't compute the snap to face on the knife tool twice
Both `knife_find_closest_vert` and `knife_find_closest_edge` call
`knife_find_closest_face`. Thus, running the raycast twice and setting
values like `kcd->curr.bmface` and `kcd->curr.is_space` repeatedly.
So:
- separate `knife_find_closest_face` from `knife_find_closest_vert` and `knife_find_closest_edge`.
- rename `knife_find_closest_vert` to `knife_find_closest_vert_of_face`
- rename `knife_find_closest_edge `to `knife_find_closest_edge_of_face`.
- do not set parameters previously set.
Differential Revision: https://developer.blender.org/D8198
commit 073c426900
Author: Germano Cavalcante <germano.costa@ig.com.br>
Date: Mon Jul 6 09:03:33 2020 -0300
Fix faces disappearing when AutoMerge & Split
commit c632cf9ccd
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 21:23:35 2020 +1000
Fix UV select separate not refreshing the display
commit 2c0cab03ca
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 21:14:12 2020 +1000
UV: add rip region to toolbar
commit dbe171fb26
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 21:03:45 2020 +1000
Cleanup: spelling, comments
commit 18b6c49a90
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 12:37:11 2020 +0200
Cleanup: rename namespace TimeIt to timeit
According to our style guide, namespaces should have
lower case names.
commit 572c48cf98
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 09:08:53 2020 +0200
BLI: improve exception safety of memory utils
Even if we do not use exception in many places in Blender, our core C++ library
should become exception safe. Otherwise, we don't even have the option
to work with exceptions if we decide to do so.
commit 703a73fa84
Author: Jacques Lucke <jacques@blender.org>
Date: Mon Jul 6 10:56:26 2020 +0200
BLI: refactor how buffers for small object optimization are stored
Previously, there was an error when operator-> was returning an
invalid type. See error C2839.
commit 80393a0eba
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:41:36 2020 +1000
UV: add rip tool
New rip tool matching edit-mesh rip functionality.
Useful as disconnecting UV's, especially for loops is inconvenient
without this.
This uses 'V' to rip, changing stitch to 'Alt-V'.
commit 9353477383
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:41:17 2020 +1000
BMesh: add BM_face_calc_uv_cross
commit b51b893df8
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:40:55 2020 +1000
BMesh: add BM_loop_other_vert_loop_by_edge
commit 705015e0a4
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 10:21:14 2020 +0200
Fix T78481: Workbench Shadow effects XRay
When in XRay some effects (shadow, cavity & depth of field) aren't supported.
This patch makes sure that these effects aren't enabled.
commit 4f3045999d
Author: Campbell Barton <ideasman42@gmail.com>
Date: Mon Jul 6 17:35:41 2020 +1000
Cleanup: warnings, spelling
commit 0f617cd67e
Author: Jeroen Bakker <j.bakker@atmind.nl>
Date: Mon Jul 6 07:45:10 2020 +0200
GPU: Remove local shaders workaround for Intel/Windows
It has been tested that local shaders workaround isn't needed for the
latest Windows/Intel 6xx GPU's.
Currently the local shaders workaround doesn't work anymore during the
investigation it was detected that the intel drivers didn't need it
anymore.
Local shaders should still be fixed as it is also used for some legacy
iGPU's. The current work around crashes when doing preview renders in
EEVEE as the default materials aren't available but for the work around
they should. (See T77346 for more information)
commit baf124c753
Author: Aaron Carlisle <carlisle.b3d@gmail.com>
Date: Sun Jul 5 16:45:56 2020 -0400
RNA Manual Reference: Update links
commit 247a28f242
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 5 15:08:26 2020 +0200
Revert "BLI: refactor how buffers for small object optimization are stored"
This reverts commit 5d79f9f276.
This was introducing build errors in windows. Need a bit more time to check it.
commit 5d79f9f276
Author: Jacques Lucke <jacques@blender.org>
Date: Sun Jul 5 16:30:26 2020 +0200
BLI: refactor how buffers for small object optimization are stored
commit 464aaf2701
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 4 17:31:02 2020 +0200
Fix T78603: GPencil Noise modifier Vertex Group influence filter missing
This was removed by error during the last refactor of modiifers.
commit 169bb4b9ce
Author: Jacques Lucke <jacques@blender.org>
Date: Sat Jul 4 17:28:05 2020 +0200
BLI: fix mistake in move constructor of Stack
commit 8e97694c8a
Author: Julian Eisel <julian@blender.org>
Date: Sat Jul 4 17:06:57 2020 +0200
Fix T78588: Material preview not visible in selection list
Logic to determine if the library icon should be used was too general.
commit 9168ea8aab
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 4 11:15:11 2020 +0200
Cleanup: Fix small typo error
commit 17603816f2
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Sat Jul 4 11:04:21 2020 +0200
GPencil: Cleanup some comments typo
commit b0da78084b
Author: Clément Foucault <foucault.clem@gmail.com>
Date: Sat Jul 4 01:27:12 2020 +0200
UI: Attempt to fix OSX widget shader issue
Some OSX GL driver implementation needs a dummy vbo read. This fixed issues
with the Hair shaders in the past.
Related to T78307
commit cad98923d0
Author: Richard Antalik <richardantalik@gmail.com>
Date: Sat Jul 4 01:02:54 2020 +0200
Cleanup: spelling
commit ea65c6a153
Author: Richard Antalik <richardantalik@gmail.com>
Date: Sat Jul 4 00:59:09 2020 +0200
Fix T78433: Adding Fade Generates Python Exception
This was caused by typo in rB67a822e08684.
commit 4bf56b37ca
Author: Nathan Craddock <nzcraddock@gmail.com>
Date: Fri Jul 3 13:31:42 2020 -0600
Cleanup: Use C-style comments in outliner files
No functional changes. Convert all C++ style comments to C comments.
Also capitalize and add full stops.
The comments themselves were not cleaned up. Some could be removed or
reworded.
commit 59ef43147e
Author: Nathan Craddock <nzcraddock@gmail.com>
Date: Fri Jul 3 12:48:00 2020 -0600
Cleanup: Remove unused outliner activation code
No functional changes. Remove commented calls to extern_set_butspace
and unused text activation code.
commit 57a48bd0ca
Author: Nathan Craddock <nzcraddock@gmail.com>
Date: Fri Jul 3 12:36:09 2020 -0600
Cleanup: Use _fn suffix for outliner button callbacks
No functional changes. Use _fn instead of _cb.
commit d7dbf90a02
Author: Sebastian Parborg <darkdefende@gmail.com>
Date: Fri Jul 3 21:22:41 2020 +0200
Clang-tidy: Enable braces-around-statements warning
commit 185fe9cd8b
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 3 18:55:32 2020 +0200
Cleanup: compiler warning
commit 46fcc12e83
Author: Brecht Van Lommel <brecht@blender.org>
Date: Fri Jul 3 18:54:04 2020 +0200
Fix error in new Hair data type file reading
commit d2db481dc7
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 18:04:40 2020 +0200
Cleanup: Blendkernel, Clang-Tidy else-after-return fixes (incomplete)
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/blenkernel` module. Not all warnings are
addressed in this commit.
No functional changes.
commit a21cb22f8b
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 11:58:43 2020 -0400
Cleanup: Deduplicate code for finding context object
Instead of manually checking the pinned object, use the existing
ED_object_active_context function. This requires adding const
to the context in that function.
commit 33a74941c5
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:30:31 2020 +0200
Cleanup: Editors, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors` module.
No functional changes.
commit 367034f210
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:30:09 2020 +0200
Cleanup: Editors/Space/UV-Edit, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/uv_edit` module.
No functional changes.
commit 651d1aa7c8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:25:04 2020 +0200
Cleanup: Editors/Transform, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/transform` module.
No functional changes.
commit 35ce16939c
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:58 2020 +0200
Cleanup: Editors/Space/sequencer, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_sequencer` module.
No functional changes.
commit a201020cd3
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:41 2020 +0200
Cleanup: Editors/Space/Clip, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_clip` module.
No functional changes.
commit f254f66587
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:22 2020 +0200
Cleanup: Editors/Space/Outliner, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_outliner` module.
No functional changes.
commit 3aa53b361d
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:20:08 2020 +0200
Cleanup: Editors/Space/Node, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_node` module.
No functional changes.
commit bf532b1106
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:19:13 2020 +0200
Cleanup: Editors/Space/Text, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_text` module.
No functional changes.
commit 2f6fc5a7e8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 17:18:56 2020 +0200
Cleanup: Editors/Space/View3D, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/space_view3d` module.
No functional changes.
commit b61ecb785c
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 16:34:57 2020 +0200
Cleanup: Explicit return in each `else if` block in `buttons_context()`
This is a similar change as in rB4283da83cc9.
No functional changes.
commit f43fedd400
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 17:35:31 2020 +0200
Cleanup: remove side effect in assertion
commit 4a48939f04
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 11:18:24 2020 -0400
UI: Fix bevel modifier not showing vertex group
commit cad2d32be6
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 17:09:24 2020 +0200
Clang-Tidy: Enable bugprone-misplaced-widening-cast
commit 4a5389816b
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 17:07:01 2020 +0200
Clang-Tidy: enable readability-named-parameter
commit fac2e63bc0
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 16:57:55 2020 +0200
Fix utterly broken code regarding GPUtextures of MovieClip in readfile.c
Treat those as pure runtime code, reset to NULL by reading code, for
now.
Think those could be handled like Image gputextures (i.e. considered
runtime cache and preserved across undo steps), but probably not
critical for now.
commit 1bdabd7b4f
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 16:55:13 2020 +0200
Move MovieClip to new undo cache management system.
commit 1019c9f582
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 16:54:08 2020 +0200
Clang-Tidy: enable bugprone-too-small-loop-variable
commit 883f9dd6e5
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 16:48:04 2020 +0200
Clang-Tidy: enable bugprone-assert-side-effect
Looks like we have no assertions with side effects.
commit 9739fc4d1b
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 16:44:46 2020 +0200
Clang-Tidy: More fixed of redundant check before delete
For some reason got unnoticed in the original cleanup pass.
commit 14fd91e7e8
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 16:38:01 2020 +0200
Clang-Tidy: enable bugprone-argument-comment
It was called `inverted` in the header.
commit f4fdb8efc5
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:38:49 2020 -0400
Cleanup: Remove redundant logic
commit f66aafa391
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:37:58 2020 -0400
Fix memory leak when dragging shaderfx
commit f891d4e2ad
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 16:32:12 2020 +0200
Clang-Tidy: Fix readability-delete-null-pointer warnings
Also enable it in the configuration.
commit 53d41e1a6f
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:28:13 2020 -0400
UI: Use sliders and [0, 1] ranges in ocean modifier
The ocean modifier has two properties that use a [0, 10] hard min and
hard max. The values act as factors though, so it makes more sense to
use sliders and a 0 to 1 range.
This commit also bumps the file subversion to avoid repeatedly applying
the change to the properties' range.
Differential Revision: https://developer.blender.org/D8186
commit 2a39b34a09
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 16:09:51 2020 +0200
Cleanup: Editors/Sculpt/Paint, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/sculpt_paint` module.
No functional changes.
commit fd5b093f84
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 16:01:15 2020 +0200
Cleanup: Editors/Screen, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/screen` module.
No functional changes.
commit 4283da83cc
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 15:59:48 2020 +0200
Cleanup: Explicit return in each `else if` block in `ed_screen_context()`
The `ed_screen_context()` function is approximately 700 lines long, and
its main structure is a huge chain of `else if` statements. Some of the
bodies did not return, but rather fell through and relied on the `return
-1;` at the bottom of the function. This means that in order to truly
understand what is going on in one of those `else if` blocks, it could
be required to scroll past all the following `else if` blocks,
double-checking that they all had an `else`, and then see what happens
below.
By adding explicit `return -1;` everywhere this happened, this is all
avoided, increasing local understandability of the code. Furthermore, it
makes the upcoming cleanup with the Clang-Tidy rule
`readability-else-after-return` a lot easier to do.
No functional changes.
commit de7c9f41e6
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 15:42:22 2020 +0200
Cleanup: Editors/Object, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/object` module.
No functional changes.
commit 19483125f8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 15:19:52 2020 +0200
Cleanup: Editors/Mesh, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/mesh` module.
No functional changes.
commit 7d0a0b8a6d
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 14:52:32 2020 +0200
Cleanup: Editors/Armature, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/armature` module.
No functional changes.
commit f82e52ebc8
Author: Sybren A. Stüvel <sybren@blender.org>
Date: Fri Jul 3 14:51:19 2020 +0200
Cleanup: Editors/Animation, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors/animation` module.
No functional changes.
commit 17ba566018
Author: Pablo Dobarro <pablodp606@gmail.com>
Date: Fri Jul 3 02:15:54 2020 +0200
Fix Pose Brush crashing after disabling connected only in FK mode
This function was returning the ik_chain before disabling the
fake_neighbors, so when the brush was used again with fake neighbors
disabled after rebuilding the PBVH and free them, they were still
enabled in the SculptSession, causing a the crash.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8195
commit 3a59c184b9
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 16:09:58 2020 +0200
Move Scene's cache management during undo to new system.
commit a33756d783
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:09:19 2020 -0400
Cleanup: Unused variables in non-debug build
commit 6a58e15548
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 10:03:16 2020 -0400
Cleanup: Remove obsolete code in interface_panel.c
Some code delt with panel merging in earlier versions of Blender,
which is no longer needed. Other code delt with controls that aren't
used anymore, and in some cases have region-level equivalents.
There's a surprising amount of this unused code in this file, so removing it
will be helpful for the future.
Differential Revision: https://developer.blender.org/D7938
commit 88d358902f
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 15:54:55 2020 +0200
Clang-Tidy: Enable readability-redundant-string-cstr
commit 405e6c6cc9
Author: Antonio Vazquez <blendergit@gmail.com>
Date: Fri Jul 3 15:53:44 2020 +0200
Fix T78555: GPencil bake animation operator loose frame setting
The values were reset for each run
commit 19ff145e66
Author: Hans Goudey <h.goudey@me.com>
Date: Fri Jul 3 09:41:55 2020 -0400
Clang-Tidy: Enable readability-redundant-control-flow
commit ffef562bf7
Author: Sergey Sharybin <sergey.vfx@gmail.com>
Date: Fri Jul 3 15:31:23 2020 +0200
Disable clang-tidy for code-generated RNA files
This needs some extra care, which is probably easier once the initial
pass over integration is done.
commit c9975088a9
Author: Bastien Montagne <bastien@blender.org>
Date: Fri Jul 3 15:27:12 2020 +0200
Move volume to new cache management system for undo.
commit 1e255ce031
Author: Jacques Lucke <jacques@blender.org>
Date: Fri Jul 3 15:27:02 2020 +0200
Fix T72214: Fluids: noise does not work with negative frame numbers
The issue is duplicated code. There are two functions that zero-fill
the frame number. They worked the same for positive frames numbers, but
behaved differently for negative ones.
On frame `-100`, `BLI_path_frame` outputs `-0100` and
`fluid_cache_get_framenr_formatted_$ID$` outputted `-100`.
I changed the behavior of the latter, because we depend on the behavior
of the former for much longer already.
Reviewers: sebbas
Differential Revision: https://developer.blender.org/D8107
Many changes aimed at, broadly, more sharing and less copying;
and having coordinates stored simultaneously in double and multiprecision,
as that will be needed for floating predicate filtering.
Biggest change is that faces are represented by arrays of pointers to
Verts instead of as integer indices into a vertex array.
Also refactored delaunay to put the 2d mesh representation into
an externally visible CDTArrangement class. Not sure yet whether
I will use this; if I end up not using it, will move that part of
the header back into the implementation file.
Now the basic binary booleans work from the tool (not the modifier).
Still to do: (1) coplanar and non-connected-component cases;
(2) dissolve triangulation lines and new verts due only to them;
(3) properly transfer mesh attributes from old to new;
(4) hook up to modifier;
(5) attention to and tuning of performance.
Mainly namespace changes, BLI -> blender, so I changed my
own namespaces to follow that pattern.
ArrayRef -> Span.
Now can have hash() as member of data structures rather
that having to make a DefaultHash for them.
Fixed a bad assumption about Arrays of bool being initialized to false.
The code to partition space into cells is mostly done.
The code to propagate winding numbers and flag cells according to the
boolean function is mostly done.
Only final extraction code is left, and a few other things.
This is a regression in functionality from the previous version,
as I have not yet got anything beyond intersection working (and
that only for triangulated meshes). But want to get this into
the repository now while I continue to work on the functionality,
and then, the performance.
Also changed default epsilon to 1e-5 from 1e-6, as the latter
is too close to hairy edge and anyway produceds really tiny faces
and edges that I doubt users really want. There's even a case for
it being 1e-4 by default.
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.