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
path: root/intern
AgeCommit message (Collapse)Author
2021-03-26Cleanup: redundant expressionKévin Dietrich
2021-03-26Fix T86939: Cycles objects bounds not updated when transforming objectsKévin Dietrich
As a rather premature optimization from rBbbe6d4492823, Object bounds were only computed when either the Object or its Geometry were modified. Prior to rB42198e9eb03b, this would work, as the Geometry was tagged as modified if the Object's transform was also modified. Since this tagging is not done anymore due to side effects, and since at the time bounds are computed Objects were already processed and tag as unmodified, the check on the modified status was always false. For now remove this check, so the bounds are always unconditionally updated. If this ever becomes a performance problem in large scenes with motion blur, we will then try to find a way to nicely optimize it. This would only affect BHV2 as OptiX and Embree handle object bounds themselves.
2021-03-26Cleanup: use code doxy command for Python snippetCampbell Barton
2021-03-26Cleanup: clang-formatCampbell Barton
2021-03-25Geometry Nodes: rename attribute domainsJacques Lucke
This patch renames two domains: * `Polygon` -> `Face` * `Corner` -> `Face Corner` For the change from `polygon` to `face` I did a "deep rename" where I updated all (most?) cases where we refere to the attribute domain in code as well. The change from `corner` to `face corner` is only a ui change. I did not see a real need to update all code the code for that. It does not seem to improve the code, more on the contrary. Ref T86818. Differential Revision: https://developer.blender.org/D10803
2021-03-24Alembic procedural: deduplicate cached data accross framesKévin Dietrich
Currently the procedural will add an entry to the cache for every frame even if the data only changes seldomly. This means that in some cases we will have duplicate data accross frames. The cached data is now stored separately from the time information, and an index is used to retrieve it based on time. This decoupling allows for multiple frames to point to the same data. To check if two arrays are the same, we compute their keys using the Alembic library's routines (which is based on murmur3), and tell the cache to reuse the last data if the keys match. This can drastically reduce memory usage at the cost of more processing time, although processing time is only increased if the topology may change.
2021-03-24Cleanup: clang-tidy errors.Jeroen Bakker
2021-03-24Cleanup: unused variableKévin Dietrich
2021-03-24Fix T86601: Cycles accumulates displacement when transforming an ObjectKévin Dietrich
In order to update the BVH when only the transformations are changing, we would tag the Object's Geometry as modified. However, when displacement is used, and the vertices were not themselves modified, this would cause us to redo the displacement on already displaced vertices. To fix this, use a specific update flag for detecting and notifying that transformations were modified. Regression caused by rBbbe6d44928235cd4a5cfbeaf1a1de78ed861bb92.
2021-03-24Cleanup: remove stdio.h header from MEM_guardedalloc.hCampbell Barton
This was included for `FILE *` which isn't used in the header. Ref D10799
2021-03-23Fix T86567: Cycles crashes when playing back animated volumesKévin Dietrich
The crash is caused by an out of bound access in the kernel due to missing data update when a Volume's voxel data changes. Although the previous bounding mesh is cleared, the Volume Node was not tagged as modified, and therefore never rebuilt. To fix this, tag the Geometries (not just Volumes, to be more robust) as modified in Geometry.clear(). Regression caused by rBbbe6d44928235cd4a5cfbeaf1a1de78ed861bb92.
2021-03-23Nodes: Add Refract and Faceforward functions to Vector Maths nodesCharlie Jolly
Cycles, Eevee, OSL, Geo, Attribute Based on outdated refract patch D6619 by @cubic_sloth `refract` and `faceforward` are standard functions in GLSL, OSL and Godot shader languages. Adding these functions provides Blender shader artists access to these standard functions. Reviewed By: brecht Differential Revision: https://developer.blender.org/D10622
2021-03-22Fix T86591: Tracking backwards is slowerSergey Sharybin
The root of the issue was caused by the PredictMarkerPosition() always returning false when tracking backwards. This was making it so tracker always had to run brute initialization, which is an expensive operation. From own timing here: - Tracking forward takes 0.667637 seconds - Tracking backward used to take 2.591856 seconds - Tracking backward now takes 0.827724 seconds This is a very nice speedup, although the tracking backwards is still somewhat slower. Will be investigated further as part of a regular development.
2021-03-22Cleanup: clang-formatCampbell Barton
2021-03-22Revert "Disable clang-format for objective-C bits in GHOST."Campbell Barton
This reverts commit 1cb9612d736f8513d7d4cfc01da6c4e386efcc4f. We can now rely on the clang-format version as it's distributed with pre-compiled binaries.
2021-03-22Cleanup: disable clang-format for 'intern/libmv/third_party' headersCampbell Barton
2021-03-21Cleanup: spelling, doxygen comment formattingCampbell Barton
2021-03-21Fix T86643: Win32 Entering Full Screen While MaximizedHarley Acheson
SetWindowPos must be called after SetWindowLongPtr in order to see changes to window frame style. Differential Revision: https://developer.blender.org/D10756 Reviewed by Ray Molenkamp
2021-03-19Fix Cycles NaN assert in random walk SSS due to very small throughputBrecht Van Lommel
Now terminate if there are many bounces and the throughput gets so small that we get precision issues.
2021-03-18Cleanup: spellingCampbell Barton
2021-03-17Nodes: Add support to mute node wiresCharlie Jolly
This patch adds the ability to mute individual wires in the node editor. This is invoked like the cut links operator but with a new shortcut. Mute = Ctrl + Alt Cut = Ctrl Dragging over wires will toggle the mute state for that wire. The muted wires are drawn in red with a bar across the center. Red is used in the nodes context to indicate invalid links, muted links and internal links. When a wire is muted it exposes the original node buttons which are normally hidden when a wire is connected. Downstream and upstream links connected using reroute nodes are also muted. Outside scope of patch: - Add support for pynodes e.g. Animation Nodes - Requires minor change to check for muted links using the `is_muted` link property or the `is_linked` socket property. Maniphest Tasks: T52659 Differential Revision: https://developer.blender.org/D2807
2021-03-16Revert removal of lambda usage for Python RNA callbacksCampbell Barton
This reverts commits - 476be3746e85b4891189c8d480501905b9400c66 - 8d50a3e19e025ef470132e7edadd7b180db833f5 - 08dbc4f996e4e95f3ab64f7bb3e1193700c585f5 (partially).
2021-03-15Fix T86121: Cycles Attribute returning wrong results with OSLBrecht Van Lommel
Fix uninitialized variable in the OSL shader.
2021-03-15Fix (apparently harmless) Cycles asan warningsBrecht Van Lommel
2021-03-15Cycles: optimize ensure_valid_reflection(), reduces render time by about 1%Mikhail
This is an implementation that is about 1.5-2.1 times faster. It gives a result that is on average 6° different from the old implementation. The difference is because normals (Ng, N, N') are not selected to be coplanar, but instead reflection R is lifted the least amount and the N' is computed as a bisector. Differential Revision: https://developer.blender.org/D10084
2021-03-15Fix T56925: Cycles banding artifacts in dense volumesMikhail Matrosov
Offset the starting point of segments by a random amount to avoid the bounding box shape affecting the result and creating artifacts. Differential Revision: https://developer.blender.org/D10576
2021-03-15Fix Cycles rendering crash on OpenBSDBrecht Van Lommel
Static initialization order was not guaranteed to be correct for node base types. Now wrap all initialization in accessor functions to ensure the order is correct. Did not cause any known bug on Linux/macOS/Windows, but showed up on this platform.
2021-03-15Fix Libmv tests after recent fixSergey Sharybin
Forgot to update regression test to the changed API.
2021-03-15Fix T86262: Tracking backwards fails after gap in trackSergey Sharybin
The issue was caused by a prediction algorithm detecting tracking the wrong way. Solved by passing tracking direction explicitly, so that prediction will always happen correctly regardless of the state of the Tracks context.
2021-03-15Refactor Libmv C-API motion model conversionSergey Sharybin
Mode to an own utility function and guard missing enumerator values with a LOG(FATAL).
2021-03-15Cleanup: Spelling in Libmv commentsSergey Sharybin
2021-03-14CMake/guardedalloc: add header file to TEST_SRCAnkit Meel
2021-03-12Fix T86332: setting Cycles dicing camera fails after recent changesBrecht Van Lommel
Somehow "from __future__ import annotations" and "lambda" are not working together well here, work around it by not using a lambda function.
2021-03-12CLOG: add support for substring matching.Bastien Montagne
So that `--log "*undo*"` matches any log identifier containing `undo`. Reviewed By: campbellbarton Differential Revision: https://developer.blender.org/D10647
2021-03-12Fix compiler warning when building Cycles without EmbreeBrecht Van Lommel
2021-03-12Alembic procedural: specific result type for cache lookupsKévin Dietrich
This type, CacheLookupResult, holds the data for the current time, or an explanation as to why no data is available (already loaded, or simply nothing available). This is useful to document the behavior of the code but also, in future changes, to respond appropriately for missing data.
2021-03-12Alembic procedural: add support for instancingKévin Dietrich
Inside of the procedural, instances are AlembicObjects which point to the AlembicObject that they instance. In Alembic, an instance is an untyped Object pointing to the original (instanced) one through its source path. During the archive traversal we detect such instances and, only if the instanced object is asked to be rendered, set the instance's AlembicObject to point to the original's AlembicObject. Cycles Object Nodes are created for each AlembicObject, but only for non-instances are Geometries created, which are then shared between Object Nodes. It is supposed, and expected, that all instances share the same shaders, which will be set to be the ones found on the original object. As for caching, the data cache for an AlembicObject is only valid for non-instances and should not be read to or from as it is implicitly shared.
2021-03-12Alembic procedural: move cache building out of object update methodsKévin Dietrich
This will help support instancing as cache building is now decoupled from the logic to update the Nodes' sockets as data (and cache) will need to be shared by different Geometries somehow, and also simplify implementing different data caching methods by centralizing this operation.
2021-03-12Alembic procedural: fix missing attribute updateKévin Dietrich
We need to explicitely tag the Attribute and AttributeSet as modified if we change or add/remove data. This is more of a bandaid until attributes handling is refactored to be able to reuse routines from the Attribute API.
2021-03-12Cleanup: unused variableKévin Dietrich
2021-03-12Alembic procedural: fix potential zero scale matrix generationKévin Dietrich
This can happen during user edits or with files missing the global scale property.
2021-03-11Cleanup: spellingCampbell Barton
2021-03-11Cycles: Change device-only memory to actually only allocate on the devicePatrick Mours
This patch changes the `MEM_DEVICE_ONLY` type to only allocate on the device and fail if that is not possible anymore because out-of-memory (since OptiX acceleration structures may not be allocated in host memory). It also fixes high peak memory usage during OptiX acceleration structure building. Reviewed By: brecht Maniphest Tasks: T85985 Differential Revision: https://developer.blender.org/D10535
2021-03-10Fix wrong white point of Linear ACES in config reading and the bundled configBrecht Van Lommel
The Blender/Cycles XYZ color space has a D65 white point instead of E, and this was not correctly accounted for both in the OpenColor config reading code and the bundled config. This meant that since the OpenColorIO v2 upgrade, the Linear ACES color space was not working correctly, and other OpenColorIO configs defining aces_interchange were not interpreted correctly.
2021-03-09macOS/Ghost: Simplify pasteboard and screen count codeCorbin Dunn
Reviewed By: #platform_macos, sebbas, ankitm Differential Revision: https://developer.blender.org/D10616
2021-03-09macOS/Ghost: Remove unnecessary nil checks.Corbin Dunn
Reviewed By: #platform_macos, sebbas, ankitm Differential Revision: https://developer.blender.org/D10616
2021-03-09macOS/Ghost: Replace NSAutoreleasePool with @autoreleasepoolCorbin Dunn
- Automatic and guaranteed cleanup. - Improves readability and reduces chances of errors by removing `[pool drain]` statements. Reviewed By: #platform_macos, sebbas, ankitm Differential Revision: https://developer.blender.org/D10616
2021-03-08Fix Cycles CUDA build error with Visual Studio 2019 v16.9Brecht Van Lommel
Something in this update broke the floor() function in CUDA, instead use floorf() like we do everywhere else in the kernel code. Thanks to Ray Molenkamp for identifying the solution.
2021-03-07Cleanup: do not pass class member to class methodsKévin Dietrich
2021-03-07Alembic procedural: fix missing update when only the transforms changeKévin Dietrich
The missing update has two sources: The TimeSampling used for looking up transformations in the cache was uninitialized. To fix this, simply use the TimeSampling from the last transformation in the hierarchy (that is the object's parent), which should also contain the time information for all of its parents. The objects are not tagged for update when their trasformations change.