Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-06-23Cleanup: Make function staticHans Goudey
2022-06-23Mesh: Add an explicit "positions changed" functionHans Goudey
We store various lazily calculated caches on meshes, some of which depend on the vertex positions staying the same. The current API to invalidate these caches is a bit confusing. With an explicit set of functions modeled after the functions in `BKE_node_tree_update.h`, it becomes clear which function to call. This may become more important if more lazy caches are added in the future. Differential Revision: https://developer.blender.org/D14760
2022-06-23Animation: Add function to remove all FCurves from an ActionColin Basnett
Add a `BKE_action_fcurves_clear(action)` function, which removes all the Action's FCurves, and expose it as `ActionFCurves.clear()` in RNA. This is more ergonomic than calling `remove` on f-curves until the list is empty. Reviewed By: sybren Differential Revision: https://developer.blender.org/D14660
2022-06-23Cleanup: Clang tidyHans Goudey
Mainly duplicate includes and else after return.
2022-06-22Cleanup: remove unused sculpt texture cache generationBrecht Van Lommel
This has not been used since 5505697ac in 2010.
2022-06-22Fix T98956: Crash removing some builtin attributesHans Goudey
For example, the "id" attribute is stored as a named attribute. If it doesn't exist already, `layer_index` was uninitialized, causing issues with `CustomData_free_layer`. The fix is to use the generic function to free a named layer in that case. Eventually the other case will go away as T95965 is finished.
2022-06-22Cleanup: Remove unused function argumentsSergey Sharybin
Solves the corresponding compiler warning.
2022-06-22Cleanup: clang-formatSergey Sharybin
2022-06-22Revert "LibOverride: Handle dependencies in both directions in partial ↵Dalai Felinto
override cases." This reverts commit f0b4aa5d59e3b3754bfcf3827f7524d34c809c62. This commit was making files to get bigger and bigger every time they were saved and re-opened. In the orphaned data in the outliner new collections would show up there, even after continuously purging it. This would lead to a massive file which get also very slow. This problem will fix itself after a few re-open/re-saves of the files. For anyone also experimenting this you can fix this faster by purging the unused data multiple times in the file. Example of file from the Project Heist (rev. 1014): heist/pro/shots/010_opening/010_0050/010_0050.anim.blend
2022-06-22Mask Editor: Add toggle for mask spline drawingSimon Lenz
Adds an overlay option to show/hide the spline points & lines of masks in the Mask Editor. It also moves the "smooth" option up (its position left of the selection dropdown was missleading). {F11847272} This emerged from a discussion in https://developer.blender.org/D12776 Differential Revision: https://developer.blender.org/D13314
2022-06-22Rigid body physics: Move effector force update into substep loop.Lukas Tönne
The substep loop for rigid bodies causes unequal effects of force fields depedending on the substep setting, larger substep counts cause a diminishing effect of force fields. This is because the force to apply on a body is reset in Bullet after each step and needs to be recomputed. Without this the body will just coast with constant velocity after the first substep. Since the per-step impulse with larger substep counts is smaller, the effect is that more substeps cause a smaller total impulse. The fix is to move external force calculation into the substep loop and update forces for each substep. Note that this may be considered a breaking change, because the breaking commit rB1aa54d4921c2 has been in master for a long time and after this fix force fields will generally have a much larger effect on rigid bodies (10x for the default setting of 10 substeps). Differential Revision: https://developer.blender.org/D15173
2022-06-21Cleanup: removed unused Blender Internal bump/normal mapping texture codeBrecht Van Lommel
The TexResult.nor output does not appear to be used anywhere.
2022-06-21NLA: when searching for active track/strip, shortcut when none is activeSybren A. Stüvel
In the `update_active_track()` function, add a shortcut that just sets `NULL`, instead of searching for `NULL` pointers. Should give a tiny speedup.
2022-06-21Fix 2 for T98700: Crash when recursively nesting NLA meta stripsSybren A. Stüvel
When searching for the active NLA strip, avoid overwriting the found strip pointer with NULL if it was already found in a previous iteration. The active strip is searched for while looping over the NLA tracks. If the active strip was found on a previous track, and not on the current track, this would effectively set `actstrip = NULL`. This is now avoided. Another benefit is that the search for the active strip is stopped as soon as it's found, which should increase performance a tiny bit.
2022-06-21NLA: update comment to reflect the current implementationSybren A. Stüvel
No functional changes.
2022-06-21NLA: add `BLI_assert_msg()` to check for assumptionSybren A. Stüvel
`find_active_strip_from_listbase()` expects two lists of strips with an equal number of items. This is now not only documented, but also checked for in an assertion.
2022-06-20Cleanup: Grammar: a vs anHans Goudey
2022-06-20Fix: assert when deleting all curvesJacques Lucke
2022-06-20Mask Editor: Add mask blending factor for combined overlaySimon Lenz
This adds a new parameter to the "Combined" overlay mode of the mask editor. The "blending factor" allows users to blend the mask exterior with the original footage to visualise the content of the mask in a more intuitive way. The "Alpha" overlay is unaffected by this change. The existing "Combined" overlay is used like before (covering everything outside the mask in black), but can be blended with the slider in the mask overlay to look at the exterior. This is part of an effort to make mask editing more intuitive & easy to use: https://developer.blender.org/T93097 Differential Revision: https://developer.blender.org/D13284
2022-06-18Constraints: handle the custom target at the constraint level.Alexander Gavrilov
Since the custom target is a feature implemented at constraint level, it is more appropriate to handle it in the common wrapper functions, instead of modifying all the type specific callbacks like get_constraint_targets and flush_constraint_targets. Also, tag the special target with a flag so other code can handle it appropriately where necessary. This was split from D9732, and effectively reverts and refactors part of D7437. This patch should cause no functional changes. Differential Revision: https://developer.blender.org/D15168
2022-06-17Cleanup: compiler warningsBrecht Van Lommel
2022-06-17Curves: refactor Add brushJacques Lucke
This splits out the code that samples points on a surface and the code that initializes new curves. This code will be reused by D15134. Differential Revision: https://developer.blender.org/D15216
2022-06-17LibOverride: Handle dependencies in both directions in partial override cases.Bastien Montagne
When creating etc. a liboverride based on a partial hierarchy pre-selection (e.g: override hierarchy on the rig object of a character), now all linked data also using that rig (e.g. all meshes deformed by that armature) will also automatically be overridden. This si achieved by following dependencies in the reversed order (from used IDs to using IDs) when we find one tagged for override.
2022-06-17BKE_main: Relations: Add `TO`/`FROM` variants of processed flags.Bastien Montagne
In some cases, it can be usefull to distinguish when an entry has been processed in which direction (`to` when handling ID pointers used by the entry, `from` when handling ID using this entry). Previous `MAINIDRELATIONS_ENTRY_TAGS_PROCESSED` tag is now a combination of the two new ones.
2022-06-17Geometry Nodes: new Volume Cube nodeChris Clyne
This commit adds a Volume Cube primitive node. It outputs a volume that contains a single "density" float grid. The density per voxel can be controlled with a field that depends on the voxel position (using the existing Position node). Other field inputs are not supported. The density field is evaluated on every voxel. Possible future improvements are listed in D15198. Differential Revision: https://developer.blender.org/D15198
2022-06-17Cleanup: remove redundant string formattingCampbell Barton
2022-06-17Cleanup: spelling in commentsCampbell Barton
2022-06-17Cleanup: unused variable warningCampbell Barton
2022-06-16Geometry Nodes: add 'Intersecting Edges' output for boolean nodePhilipp Oeser
This patch adds a 'Intersecting Edges' output with a boolean selection that only gives you the new edges on intersections. Will work on a couple of examples next, this should make some interesting effects possible (including getting us closer to the "bevel- after-boolean-usecase") To achieve this, a Vector is passed to `direct_mesh_boolean` when the iMesh is still available (and intersecting edges appended), then from those edge indices a selection will be stored as attribute. Differential Revision: https://developer.blender.org/D15151
2022-06-16Fix T98796: avoid unnecessary mesh copyJacques Lucke
The call to `get_component_for_write` would sometimes copy the mesh even when the mesh is replaced with itself. The `replace_mesh` method handles that case already, so just use that instead.
2022-06-15Fix missing translation hint in tracking codeSergey Sharybin
Is likely harmless due to Camera being covered by other areas, but is still good to do a proper hint.
2022-06-15GPencil: Fix crash when using time offset modifierFalk David
This fixes a mistake in 60bf561d379a, which did not account for offset frames by the time offset modifier.
2022-06-15Fix T98853: Blender crashes when moving grease pencil object has any ↵filedescriptor
invisible layers Whats happening is that the modifier keeps adding new frames to the evaluated object resulting in an exponential increase. This is because when preparing the data for the modifiers we only copy visible strokes to the eval object. But the modifiers do not consider visibility and will generate the mirrored strokes even for layers that are hidden. Because those layers have not been copied (only their structure) we run into this issue. The solution is always copy the active frame of all layers (even if the layer is hidden).
2022-06-15Clip editor: Default to average error sort in dopesheetSergey Sharybin
This is what we agreed on during the workshop. Differential Revision: https://developer.blender.org/D15194
2022-06-15Clip editor: Sort tracks alphabetically when they have matched errorSergey Sharybin
Is nice to ensure order of tracks when their error is the same or is not known yet (the clip was not solved yet).
2022-06-15Cleanup: unused argument warningCampbell Barton
2022-06-14Fix T98879: PBVH active attrs only optimization is buggyJoseph Eagar
PBVH draw has an optimization where it only sends the active attribute to the GPU in workbench mode. This fails if multiple viewports are open with a mix of workbench and EEVEE mode; it also causes severe lag if any workbench viewport is in material mode. There are two solutions: either add the code in sculpt-dev that checks for EEVEE viewports at the beginning of each frame, or integrate pbvh draw properly inside the draw manager and let it handle which attributes should go to the GPU.
2022-06-14Cleanup: Fix const correctness of attribute search functionHans Goudey
Retrieving a mutable custom data layer from a const ID should not be possible.
2022-06-14Attributes: Adjustments to duplicate attribute API functionHans Goudey
Use a name argument, for the same reasons as 6eea5f70e3b79e3c668. Also reuse the layer and unique name creation in `BKE_id_attribute_new` instead of reimplementing it. Also include a few miscellaneous cleanups like using const variables and `std::string`.
2022-06-14Fix T98700: Regression: Crash when recursively nesting NLA meta stripsSybren A. Stüvel
The `update_active_strip_from_listbase()` function took meta-strips in the "source" list into account, but didn't recurse into the corresponding meta-strip of the "destination" list. This is now fixed. `update_active_strip_from_listbase()` needed a few changes to resolve the issue: - It was renamed to `find_active_strip_from_listbase()` to limit its reponsibility to just finding the active strip. It now leaves the assignment to the caller. This reduces the number of parameters by 1 and makes recursion simpler. - The destination strips are now, like the source strips, passed as `ListBase`, so that both source & dest can be recursed simultaneously.
2022-06-14Fix T98813: crash with GPU subdiv in edit mode and instanced geometryBrecht Van Lommel
Instancing with geometry nodes uses just the evaluated Mesh, and ignores the Object that it came from. That meant that it would try to look up the subsurf modifier on the instancer object which does not have the subsurf modifier. Instead of storing a session UUID and looking up the modifier data, store a point to the subsurf modifier runtime data. Unlike the modifier data, this runtime data is preserved across depsgraph CoW. It must be for the subdiv descriptor contained in it to stay valid along with the draw cache. As a bonus, this moves various Mesh_Runtime variables into the subsurf runtime data, reducing memory usage for meshes not using subdivision surfaces. Also fixes T98693, issues with subdivision level >= 8 due to integer overflow. Differential Revision: https://developer.blender.org/D15184
2022-06-14Cleanup: spellingCampbell Barton
2022-06-14Cleanup: quiet unused variable warningCampbell Barton
2022-06-13Cleanup: fix various typosBrecht Van Lommel
Found via codespell -q 3 -S ./intern,./extern -L ans,ba,bording,datas,eiter,fiter,hist,inout,lod,ot,parm,parms,pixelx,pres,te Contributed by luzpaz. Differential Revision: https://developer.blender.org/D15155
2022-06-13Cleanup: Remove unused variable and parameter in pbvh_update_draw_buffersJoseph Eagar
2022-06-12Fix T98784: PBVH gpu layout check being ignoredJoseph Eagar
Moved gpu vert format checking outside of pbvh_update_draw_buffers, which isn't called in every code path of BKE_pbvh_draw_cb. This led to the draw cache being partially populated by old draw buffers that were subsequently freed, causing a crash.
2022-06-10LibOverride: Add util to check if a given Override Property is animated.Bastien Montagne
Searches in available animdata for fcuve(s) with matching RNA path.
2022-06-10Liboverride: Add rna array index return value to ↵Bastien Montagne
`BKE_lib_override_rna_property_find`. Very useful e.g. for dealing with FCurves search.
2022-06-10Fix regression in the recent unit system changeRamil Roosileht
Resolves unit tests failure since the D15085. Also addressed API documentation and formatting format. Differential Revision: https://developer.blender.org/D15162
2022-06-10Fix T98727: Dynamic Paint does not update normalsPhilipp Oeser
Caused by {rB6a3c3c77b3eb}. Displacement and wave were tagging the original mesh normals dirty, instead the result's normals need tagging. Seems like a typo in above commit (similar to rBfe43c170831f). Maniphest Tasks: T98727 Differential Revision: https://developer.blender.org/D15165