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
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-07-12Cleanup: improve naming and comments of scene frame/ctime functionsBrecht Van Lommel
Confusingly, BKE_scene_frame_get did not match the frame number as expected by BKE_scene_frame_set. Instead it return the value after time remapping, which is commonly named "ctime". * Rename BKE_scene_frame_get to BKE_scene_ctime_get * Add a new BKE_scene_frame_get that matches BKE_scene_frame_set * Use int/float depending if fractional frame is expected
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-08-18Depsgraph: simplify DEG_evaluate_* APIJacques Lucke
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
2020-08-18Cleanup: remove outdated commentsJacques Lucke
2020-08-18Cleanup: remove TimeSourceNode->cfra which is never readJacques Lucke
2020-06-29Depsgraph: introduce blender::deg namespaceJacques Lucke
Reviewers: sergey Differential Revision: https://developer.blender.org/D8150
2020-05-08Cleanup: take includes out of 'extern "C"' blocksJacques Lucke
Surrounding includes with an 'extern "C"' block is not necessary anymore. Also that made it harder to add any C++ code to some headers, or include headers that have "optional" C++ code like `MEM_guardedalloc.h`. I tested compilation on linux and windows (and got help from @LazyDodo). If this still breaks compilation due to some linker error, the header containing the symbol in question is probably missing an 'extern "C"' block. Differential Revision: https://developer.blender.org/D7653
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-14Cleanup: spellingCampbell Barton
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2019-10-08Depsgraph: Cleanup, de-duplicate time source taggingSergey Sharybin
2019-09-05Depsgraph: Free user code from worry about updates flushSergey Sharybin
2019-09-05Depsgraph: Pass bmain to evaluation functionSergey Sharybin
Currently unused, makes code ready for an upcoming change.
2019-07-31Depsgraph: Fix wrong check for need-to-be-evaluatedSergey Sharybin
Was missing since 1693a5efe91.
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-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-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.
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-09-21Depsgraph: update frame in scene on frame change.Brecht Van Lommel
Normally the time can be read from DEG_get_ctime(depsgraph), but this is a bit more forgiving for e.g. addons that don't care too much about the details of the COW depsgraph.
2018-04-16Depsgraph: remove EvaluationContext, pass Depsgraph instead.Brecht Van Lommel
The depsgraph was always created within a fixed evaluation context. Passing both risks the depsgraph and evaluation context not matching, and it complicates the Python API where we'd have to expose both which is not so easy to understand. This also removes the global evaluation context in main, which assumed there to be a single active scene and view layer. Differential Revision: https://developer.blender.org/D3152
2018-04-13Depsgraph: don't pass evaluation context to update functions.Brecht Van Lommel
The depsgraph now contains all the state needed to evaluate it. Differential Revision: https://developer.blender.org/D3147
2018-04-13Depsgraph: remove engine type from evaluation context.Brecht Van Lommel
This was only used for viewport rendering, where we can just pass the engine type directly. There is no technical reason why we can't draw the same depsgrpah with different render engines. It also led to some weird things like requiring a render engine for snapping and raycast API functions. Differential Revision: https://developer.blender.org/D3145
2018-04-13Depsgraph: store mode and time in depsgraph, add view layer / scene accessors.Brecht Van Lommel
Scene, view layer and mode are now set in the constructor and never changed. Time is updated on frame changes to indicate which frame is being or has been evaluated last. This is a step towards making EvaluationContext obsolete. Differential Revision: https://developer.blender.org/D3144
2018-04-05Remove workspace object mode, reverts changes w/ 2.8Campbell Barton
This caused too many problems syncing object modes with multiple objects/windows/workspaces, see: D3130 for details.
2018-02-28Point cache: Pass EvaluationContext for all the related functionsDalai Felinto
Now the only missing bit seems to be in Cycles to pass depsgraph to builtin_image_float_pixels(). Ideally we could get evaluation context instead of using depsgraph + settings. But for the other rna EvaluationContext functions this is how we are doing. Reviewers: sergey, brecht Differential Revision: https://developer.blender.org/D3087
2018-02-28Refactor depsgraph/render logic to serve evaluated depsgraph to enginesDalai Felinto
User notes ---------- Compositing, rendering of multi-layers in Eevee should be fully working now. Development notes ----------------- Up until now we were still using the same depsgraph for rendering and viewport evaluation. And we had to go out of our ways to be sure the depsgraphs were updated. Now we iterate over the (to be rendered) view layers and create a depsgraph to each one, fully evaluated and call the render engines (Cycles, Eevee, ...) with this viewlayer/depsgraph/evaluation context. At this time we are not handling data persistency, Depsgraph is created from scratch prior to rendering each frame. So I got rid of most of the partial update calls we had during the render pipeline. Cycles: Brecht Van Lommel did a patch to tackle some of the required Cycles changes but this commit mark these changes as TODOs. Basically Cycles needs to render one layer at a time. Reviewers: sergey, brecht Differential Revision: https://developer.blender.org/D3073
2018-02-15Merge branch 'master' into blender2.8Sergey Sharybin
2018-02-15Cleanup: use '_len' instead of '_size' w/ BLI APICampbell Barton
- When returning the number of items in a collection use BLI_*_len() - Keep _size() for size in bytes. - Keep _count() for data structures that don't store length (hint this isn't a simple getter). See P611 to apply instead of manually resolving conflicts.
2018-02-06Use eObjectMode for function argumentsCampbell Barton
2018-02-06Object Mode: Add to EvaluationContext & DRWContextStateCampbell Barton
2017-12-21Merge branch 'master' into blender2.8Sergey Sharybin
2017-12-21Depsgraph: Remove evaluation priority completelySergey Sharybin
2017-12-20Merge branch 'master' into blender2.8Sergey Sharybin
2017-12-20Depsgraph: Move time source node to own fileSergey Sharybin
2017-12-13Depsgraph: Ensure dependency graph is allocated for evaluation contextSergey Sharybin
This is something what we would need to ensure anyway, so doesn't seem to make sense to NOT allocate depsgraph and then worry about this externally. Steps to reproduce: add cube, change it's size in redo panel. Found by Campbell during code review session.
2017-11-28Cleanup, naming of engine type variableSergey Sharybin
2017-11-23Rename any instance of scene layer or render layer in code with view layerDalai Felinto
The RenderResult struct still has a listbase of RenderLayer, but that's ok since this is strictly for rendering. * Subversion bump (to 2.80.2) * DNA low level doversion (renames) - only for .blend created since 2.80 started Note: We can't use DNA_struct_elem_find or get file version in init_structDNA, so we are manually iterating over the array of the SDNA elements instead. Note 2: This doversion change with renames can be reverted in a few months. But so far it's required for 2.8 files created between October 2016 and now. Reviewers: campbellbarton, sergey Differential Revision: https://developer.blender.org/D2927
2017-11-08Depsgraph: Move storage from single per-scene depsgraph to a hash storageSergey Sharybin
Depsgraph itself is still created fer the whole scene rather than for a single layer, this is to be addressed next. The storage for those dependency graphs is in scene, but now it is a hash indexed by layer. In the future we can extend hash key to include extra information (workspace? window?).
2017-11-07Depsgraph: Simplify some workarounds and make API closer to finalSergey Sharybin
2017-11-06Depsgraph: Cleanup, remove depgraph_legacy from evaluation routinesSergey Sharybin
2017-10-24Depsgraph: Remove scene from refresh APISergey Sharybin
Scene is already stored in the graph.
2017-10-20Depsgraph: Reduce number of depsgraph_legacy usages outside of depsgraphSergey Sharybin
2017-10-16Workspace: Move engines to workspace and Properties Editor cleanupDalai Felinto
Engine is not stored in WorkSpaces. That defines the "context" engine, which is used for the entire UI. The engine used for the poll of nodes (add node menu, new nodes when "Use Nodes") is obtained from context. Introduce a ViewRender struct for viewport settings that are defined for workspaces and scene. This struct will be populated with the hand-picked settings that can be defined per workspace as per the 2.8 design. * use_scene_settings * properties editor: workshop + organize context path Use Scene Settings ================== For viewport drawing, Workspaces have an option to use the Scene render settings (F12) instead of the viewport settings. This way users can quickly preview the final render settings, engine and View Layer. This will affect all the editors in that workspace, and it will be clearly indicated in the top-bar. Properties Editor: Add Workspace and organize context path ========================================================== We now have the properties of: Scene, Scene > Layer, Scene > World, Workspace [Scene | Workspace] > Render Layer > Object [Scene | Workspace] > Render Layer > Object > Data (...) Reviewers: Campbell Barton, Julian Eisel Differential Revision: https://developer.blender.org/D2842
2017-07-26Depsgraph: Add utility function to initialize evaluation context from scene ↵Sergey Sharybin
and layer