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-11-09Fix T101906: Modifier apply not working if target object is in excluded ↵Sergey Sharybin
collection The issue was introduced by the optimization of hidden objects and modifiers in the f12f7800c296. The solution here detects that either an object is hidden or the modifier is disabled and does special tricks to ensure the dependencies are evaluated. This is done by constructing a separate minimal dependency graph needed for the object on which the modifier is being applied on. This minimal dependency graph will not perform visibility optimization, making it so modifier dependencies are ensured to be evaluated. The downside of such approach is that some dependencies which are not needed for the modifier are still evaluated. There is no currently an easy way to avoid this. At least not without introducing possible race conditions with other dependency graphs. If the performance of applying modifiers in such cases becomes a problem the possible solution would be to create a temporary object with a single modifier so that only minimal set of dependencies is pulled in the minimal dependency graph. Differential Revision: https://developer.blender.org/D16421
2022-07-21Fix T99733: Objects with driven visibility are evaluated when not neededSergey Sharybin
The issue was caused by the fact that objects with driven or animated visibility were considered visible by the dependency graph evaluation. This change makes it so the dependency graph evaluation is aware of visibility which might be changing. This is achieved by evaluating the path of the graph which affects objects visibility and adjusts to it before evaluating the rest of the graph. There is some time penalty to this, but there does not seem to be a way to fully avoid this penalty. With the production shot from the heist project the FPS drops by a tenth of a frame (~9.4 vs ~9.3 fps) when adding a driver to an object which keeps it visible. Note that this is a bit hard to measure since the FPS fluctuates quite a bit throughout the playback. On the other hand, having a driver on a visibility of a heavy object from character and setting visibility to false gives big speedup. Also worth noting that there is no penalty at all when there are no animated visibilities in the scene. Differential Revision: https://developer.blender.org/D15498
2022-07-19Depsgraph: Cleanup, Make variable less ambiguous and more clearSergey Sharybin
2022-07-19Depsgraph: Make variable naming more clearSergey Sharybin
Disambiguate from nodes visibility flags.
2022-07-19Depsgraph: Cleanup, use nested namespace definitionSergey Sharybin
2022-02-11File headers: SPDX License migrationCampbell Barton
Use a shorter/simpler license convention, stops the header taking so much space. Follow the SPDX license specification: https://spdx.org/licenses - C/C++/objc/objc++ - Python - Shell Scripts - CMake, GNUmakefile While most of the source tree has been included - `./extern/` was left out. - `./intern/cycles` & `./intern/atomic` are also excluded because they use different header conventions. doc/license/SPDX-license-identifiers.txt has been added to list SPDX all used identifiers. See P2788 for the script that automated these edits. Reviewed By: brecht, mont29, sergey Ref D14069
2021-12-10Cleanup: move public doc-strings into headers for 'depsgraph'Campbell Barton
- Added space below non doc-string comments to make it clear these aren't comments for the symbols directly below them. - Use doxy sections for some headers. Ref T92709
2021-07-12Fix T89040: dependency graph not handling time remapping correctlyBrecht Van Lommel
In this bug report it resulted in rendering animations stopping too early, but this affected more areas. After the previous cleanup commit, it becomes clear that frame and ctime values were mixed up.
2021-06-22Fix T89196: Depsgraph use-after-free after scene switching undoSergey Sharybin
Delay depsgraph visibility update tagging until it is known that graph relations are up to date, and until it is known that the graph is actually needed to be evaluated. Differential Revision: https://developer.blender.org/D11660
2021-04-08Cleanup: spellingCampbell Barton
2021-04-05Render: faster animation and re-rendering with Persistent DataBrecht Van Lommel
For Cycles, when enabling the Persistent Data option, the full render data will be preserved from frame-to-frame in animation renders and between re-renders of the scene. This means that any modifier evaluation, BVH building, OpenGL vertex buffer uploads, etc, can be done only once for unchanged objects. This comes at an increased memory cost. Previously there option was named Persistent Images and had a more limited impact on render time and memory. When using multiple view layers, only data from a single view layer is preserved to keep memory usage somewhat under control. However objects shared between view layers are preserved, and so this can speedup such renders as well, even single frame renders. For Eevee and Workbench this option is not available, however these engines will now always reuse the depsgraph for animation and multiple view layers. This can significantly speed up rendering. These engines do not support sharing the depsgraph between re-renders, due to technical issues regarding OpenGL contexts. Support for this could be added if those are solved, see the code comments for details.
2021-03-04Cleanup: Main `foreach ID` code: Remove `MAX_LIBARRAY` and improve comments.Bastien Montagne
The `MAX_LIBARRAY` define was an annoying doublon to the `INDEX_ID_MAX` enum value now defined in `DNA_ID.h`, and it is no more useful. And comments were somewhat outdated. Also added an explanation about chosen order for the `INDEX_ID_<IDTYPE>` order.
2020-11-17Clang-tidy, fix bugprone-exception-escape.Ankit Meel
Remove redundant call to `ofstream::close()` from `~PSStrokeRenderer` and `~TextStrokeRenderer`. ofstream will be destructed automatically. - For `~Depsgraph`, `std::function`'s constructor can throw. - Passing throwing statements in the lambda will not be detected by clang-tidy. Fix these issues by using lambda as function argument. Reviewed By: sergey, sybren Differential Revision: https://developer.blender.org/D9497
2020-08-20Depsgraph: refactor tagging after time changesJacques Lucke
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
2020-07-03Depsgraph: Use C++ style of guarded allocation of objectsSergey Sharybin
2020-06-29Depsgraph: introduce blender::deg namespaceJacques Lucke
Reviewers: sergey Differential Revision: https://developer.blender.org/D8150
2020-06-10Depsgraph: use blender::Vector instead of std::vectorJacques Lucke
We decided that `blender::Vector` should be the default choice for a vector data structure in Blender. Reviewers: sergey Differential Revision: https://developer.blender.org/D7981
2020-04-28Cleanup: remove unnecessary includesJacques Lucke
2020-04-28Depsgraph: use BLI::Set for entry_tagsJacques Lucke
Reviewers: sergey Differential Revision: https://developer.blender.org/D7555
2020-04-28Depsgraph: Use BLI::Map in more placesJacques Lucke
Reviewers: sergey Differential Revision: https://developer.blender.org/D7519
2020-01-28Cleanup: changed NULL to nullptr in depsgraph C++ codeSybren A. Stüvel
No functional changes.
2020-01-24Depsgraph: Refactor, move debug struct to own fileSergey Sharybin
2020-01-24Depsgrapg: Refactor, move Relation to own fileSergey Sharybin
2020-01-24Depsgraph: Refactor, wrap debug fields into own structureSergey Sharybin
2019-10-11Depsgraph: Cleanup, promote is_evaluating querySergey Sharybin
This way it might be used for sanity checks in RNA API as well.
2019-09-11Depsgraph: Pass bmain to depsgraph object creationSergey Sharybin
Currently unused, but will allow to keep of an owner of the depsgraph. Could also simplify other APIs in the future by avoiding to pass bmain explicitly to relation update functions and things like that.
2019-08-25Cleanup: redundant struct declarationsCampbell Barton
2019-08-01Cleanup: misc spelling fixesCampbell Barton
T68035 by @luzpaz
2019-07-26Fix T66378: Missing animation update when switching view layerSergey Sharybin
Current frame is stored in a scene, and scene might have multiple view layers. The inactive view layers were not informed about scene's frame being changed, so when user switched back to view after changing scene frame it was in an inconsistent state between current scene frame and animation. Now we tag scene for time changes, so dependency graph can catch up and do proper update. Currently tagging is from quite generic place. Probably better approach would be to tag from where frame is actually being assigned. Downside of this is that it's easy to miss some places. Reviewers: brecht, mont29 Reviewed By: brecht Maniphest Tasks: T66378 Differential Revision: https://developer.blender.org/D5332
2019-05-29DrawManager: Cycles+GPencilJeroen Bakker
Fix for GPencil and Cycles Render draw type. GPencil objects were only shown when overlays were turned on. The cause of this is an optimization we did to not populate any draw engine when an external renderer was used with overlays turned off. This will check if there is any visible GPencil object in the scene. if so it will still perform the loop. `DEG_id_type_any_exists` can check if any object of a certain type_id is in the result. This check is also being used to check if there are any visible grease pencil objects as a precheck in `DRW_render_check_grease_pencil`. Reviewed By: brecht, fclem, antoniov Maniphest Tasks: T65191 Differential Revision: https://developer.blender.org/D4962
2019-05-23Render: Use dependency graph for compositor/sequencerSergey Sharybin
This change makes it so a minimal dependency graph which only includes compositor and sequencer is built for the render pipeline purposes. Tricky part here is that it's only compositor itself and sequencer who to use this dependency graph and IDs from it. Render engines are still to be provided original IDs because: - They will create dependency graph for the given scene, and currently it is not possible to create dependency graph from CoW scene. - IDs from the compositor/sequencer dependency graph are "stripped", as in, they wouldn't have all view layers, collections or objects required for proper final render. This creates annoying mess of mixing evaluated and original scene access in various parts of the pipeline. Fixes T63927: Compositing nodes - drivers don't really work Reviewers: brecht Maniphest Tasks: T63927 Differential Revision: https://developer.blender.org/D4911
2019-04-17ClangFormat: apply to source, most of internCampbell Barton
Apply clang format as proposed in T53211. For details on usage and instructions for migrating branches without conflicts, see: https://wiki.blender.org/wiki/Tools/ClangFormat
2019-02-18doxygen: add newline after \fileCampbell Barton
While \file doesn't need an argument, it can't have another doxy command after it.
2019-02-15Depsgraph: Move RNA lookup to an own query classSergey Sharybin
Currently should have no functional changes, but allows to implement runction optimizations more localized and easily.
2019-02-15Cleanup: IndentationSergey Sharybin
2019-02-08Fix T61231: File open and undo looses unkeyed changesSergey Sharybin
Only flush copy-on-write to animation when user makes changes.
2019-02-07Cleanup: sort struct blocks, descriptionCampbell Barton
2019-02-06Cleanup: remove redundant doxygen \file argumentCampbell Barton
Move \ingroup onto same line to be more compact and make it clear the file is in the group.
2019-02-01Cleanup: remove original authorCampbell Barton
Missed when removing contributors.
2019-02-01Cleanup: remove redundant, invalid info from headersCampbell Barton
BF-admins agree to remove header information that isn't useful, to reduce noise. - BEGIN/END license blocks Developers should add non license comments as separate comment blocks. No need for separator text. - Contributors This is often invalid, outdated or misleading especially when splitting files. It's more useful to git-blame to find out who has developed the code. See P901 for script to perform these edits.
2019-01-31Depsgraph: Comb code to a better state all overSergey Sharybin
Some summary of changes: - Don't use DEG prefix for types and enumerator values: the code is already inside DEG namespace. - Put code where it locally belongs to: avoid having one single header file with all sort of definitions in it. - Take advantage of modern C++11 enabled by default.
2019-01-31Depsgraph: Specify whether RNA path to be resolved as entry or exitSergey Sharybin
Makes it more explicit whether RNA property is used as a source dependency for something else, or whether some other dependency is being hooked up to evaluate that property.
2019-01-31Cleanup: Spelling in commentSergey Sharybin
2019-01-28Cleanup: sort forward declarations of enum & structCampbell Barton
Done using: source/tools/utils_maintenance/c_sort_blocks.py
2018-12-03Depsgraph: assert that mesh_get_eval_final/deform aren't used in eval.Alexander Gavrilov
Using those functions during multithreaded evaluation is a sure way to have a race condition and crash.
2018-11-22Depsgraph: Cleanup, make it easier to create relations with flagsSergey Sharybin
2018-11-16Fix T56673: Tara.blend from Blender cloud crashes on loadSergey Sharybin
The issue was caused by dependency cycle solver killing relation which was guaranteed various things: i.e. copy-on-write component orders and pose evaluation order (which must first run pose init function). Now it is possible to prevent such relations from being ignored. This is not a complete fix, but is enough to make this specific rig to work. Ideally, we also need to run copy-on-write operation prior to anything else.
2018-11-14Depsgraph: Fix missing point cache reset when physics changesSergey Sharybin
Among all the lines moved around, the general idea is quite simple. Actually, there are two ideas implemented there. First one, is when object itself is tagged for update, we tag its point cache component for evaluation, which makes it so point cache is properly reset. We do it implicitly because otherwise we'll need to go everywhere and add explicit tag in almost all the properties. Second thing is, we link all collider and force fields to a point cache component using special type of link. This type of link only allows flush if change is caused by a user update. This way reset does not happen when change is caused due to animation, but will properly happen when user causes indirect change to the objects which are part of physics simulation.
2018-11-07Cleanup/Refactor: move Main stuff into BKE's new main.c file (and header).Bastien Montagne
We already had a BKE_main.h header, no reason not to put there Main-specific functions, BKE_library has already more than enough to handle with IDs and library management!
2018-06-25Cleanup: refactor depsgraph physics API functions.Brecht Van Lommel