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
2018-12-12Cleanup: use colon separator after parameterCampbell Barton
Helps separate variable names from descriptive text. Was already used in some parts of the code, double space and dashes were used elsewhere.
2018-12-02Cleanup: BKE_effect.h namingCampbell Barton
2018-11-14Cleanup: comment block tabsCampbell Barton
2018-08-26Cleanup: styleCampbell Barton
2018-07-24Fix T55958: allow the user to select between spring and spring2.Alexander Gavrilov
The old springs with damping 1.0 operate in a special way that is more similar to plastic deformation than a spring. Some users rely on that, so let the user choose which implementation to use. This also restores full backward compatibility with 2.79. Reviewers: sergof Differential Revision: https://developer.blender.org/D3544
2018-06-17Cleanup: trailing space for blenkernelCampbell Barton
2018-05-28Windows: Add support for building with clang.Ray Molenkamp
This commit contains the minimum to make clang build/work with blender, asan and ninja build support is forthcoming Things to note: 1) Builds and runs, and is able to pass all tests (except for the freestyle_stroke_material.blend test which was broken at that time for all platforms by the looks of it) 2) It's slightly faster than msvc when using cycles. (time in seconds, on an i7-3370) victor_cpu msvc:3099.51 clang:2796.43 pavillon_barcelona_cpu msvc:1872.05 clang:1827.72 koro_cpu msvc:1097.58 clang:1006.51 fishy_cat_cpu msvc:815.37 clang:722.2 classroom_cpu msvc:1705.39 clang:1575.43 bmw27_cpu msvc:552.38 clang:561.53 barbershop_interior_cpu msvc:2134.93 clang:1922.33 3) clang on windows uses a drop in replacement for the Microsoft cl.exe (takes some of the Microsoft parameters, but not all, and takes some of the clang parameters but not all) and uses ms headers + libraries + linker, so you still need visual studio installed and will use our existing vc14 svn libs. 4) X64 only currently, X86 builds but crashes on startup. 5) Tested with llvm/clang 6.0.0 6) Requires visual studio integration, available at https://github.com/LazyDodo/llvm-vs2017-integration 7) The Microsoft compiler spawns a few copies of cl in parallel to get faster build times, clang doesn't, so the build time is 3-4x slower than with msvc. 8) No openmp support yet. Have not looked at this much, the binary distribution of clang doesn't seem to include it on windows. 9) No ASAN support yet, some of the sanitizers can be made to work, but it was decided to leave support out of this commit. Reviewers: campbellbarton Differential Revision: https://developer.blender.org/D3304
2018-04-09Use the newer version of the bullet 6dof spring constraint for rigidbody.Alexander Gavrilov
The new constraint is slower and not backward compatible, but should be better, especially in the damping side. The new constraint also has a different valid range of the damping coefficient, and a limit implementation that bounces instead of making the object stationary. Reviewers: sergof Differential Revision: https://developer.blender.org/D3125
2018-03-16Depsgraph: Move evaluation debug prints to depsgraphSergey Sharybin
This way we can easily control format and keep it consistent. And also possibly do other trickery, like coloring addresses!
2018-02-21Depsgraph: Split debug flagsSergey Sharybin
Now it's possible to have debug messages for following things: - Graph construction - Graph evaluation - Graph tagging
2018-02-07Cleanup: add _types.h suffix to DNA headersCampbell Barton
2017-09-05Fix T52374: Changes of rigid body related settings during simulation will ↵Sergej Reich
break the simulation Revert 9cd6b03, 3edc8c1, b87d10d and do a better fix for T50230.
2017-08-11Cleanup: remove useless `DM_ensure_looptri()`.Bastien Montagne
That one was doing exactly same thing as `dm->getLoopTriArray()`, no point in having twice the same code here...
2017-08-07Fix compilation error when rigid body is disabledSergey Sharybin
2017-08-07Refactor ID copying (and to some extent, ID freeing).Bastien Montagne
This will allow much finer controll over how we copy data-blocks, from full copy in Main database, to "lighter" ones (out of Main, inside an already allocated datablock, etc.). This commit also transfers a llot of what was previously handled by per-ID-type custom code to generic ID handling code in BKE_library. Hopefully will avoid in future inconsistencies and missing bits we had all over the codebase in the past. It also adds missing copying handling for a few types, most notably Scene (which where using a fully customized handling previously). Note that the type of allocation used during copying (regular in Main, allocated but outside of Main, or not allocated by ID handling code at all) is stored in ID's, which allows to handle them correctly when freeing. This needs to be taken care of with caution when doing 'weird' unusual things with ID copying and/or allocation! As a final note, while rather noisy, this commit will hopefully not break too much existing branches, old 'API' has been kept for the main part, as a wrapper around new code. Cleaning it up will happen later. Design task : T51804 Phab Diff: D2714
2017-07-04Fix T51703: Rigid body with delta transform jumps when transformingLuca Rood
When doing any transformation on a rigid body object that has delta transforms, the object would be offset by the amount of the delta transform.
2017-07-04Better fix for rigid body not resimulatingLuca Rood
Last fix only accounted for direct changes to the RB settings, but failed for, say, object transformations. This fix accounts for any change that might invalidate the RB cache.
2017-07-04Fix rigid body not resimulating after cache invalidationLuca Rood
Fix 9cd6b03187b91bb2c267a45eac3cee7738e0e220 introduced a bug that prevented simulation after a cache invalidation (for instance when changing a setting after simulating). This fixes that.
2017-06-30Fix T50230: Rigid Body simulation shouldn't step when time is beyond cached areaLuca Rood
This makes the last time (`ltime`) stored in the rigid body world (`rbw`) only be updated once a simulation step actually occurs, this prevents another simulation step from being solved unless the current time is exactly one frame after the last cached frame. Thus this prevents the formation of gaps in the cache, such as seen in T50230. Reviewers: mont29, sergey, angavrilov Tags: #physics Maniphest Tasks: T50230 Differential Revision: https://developer.blender.org/D2458
2017-06-15Fix compilation error with strict cflags after recent const changesSergey Sharybin
2017-06-14Make whole ID copying code use const source pointer.Bastien Montagne
Noisy change, but safe, and better do it sooner than later if we are to rework copying code. Also, previous commit shows this *is* useful to catch some mistakes.
2017-05-20CMake: Use GCC7's -Wimplicit-fallthrough=5Campbell Barton
Use to avoid accidental missing break statements, use ATTR_FALLTHROUGH to suppress.
2017-01-31Cleanup: Rename callback flags from library_query to `IDWALK_CB_...`Bastien Montagne
Better to have clear way to tell whether flag is parameter for BKE_library_foreach_ID_link(), parameter for its callback function, or return value from this callback function.
2016-12-13Fix strict compiler error when building without bulletSergey Sharybin
2016-12-12Cleanup: Get rid of unused BKE_rigidbody_relink_constraint().Bastien Montagne
Also use proper ID_NEW_REMAP macro in BKE_rigidbody_world_groups_relink()!
2016-11-30Cleanup id->newid usage, initial work.Bastien Montagne
This aims at always ensuring that ID.newid (and relevant LIB_TAG_NEW) stay in clean (i.e. cleared) state by default. To achieve this, instead of clearing after all id copy call (would be horribly noisy, and bad for performances), we try to completely remove the setting of id->newid by default when copying a new ID. This implies that areas actually needing that info (mainly, object editing area (make single user...) and make local area) have to ensure they set it themselves as needed. This is far from simple change, many complex code paths to consider, so will need some serious testing. :/
2016-11-08Fix memory leak when Blender is build without Bullet and files with RB is openedSergey Sharybin
2016-11-07Expose Bullet rotational spring settings in the UI.Alexander Gavrilov
Bullet spring constraint already supports rotational springs, but they are not exposed in blender UI, likely due to a simple oversight. Supporting them is as simple as adding a few DNA/RNA properties with appropriate UI and passing them on to Bullet. Reviewers: sergof Reviewed By: sergof Differential Revision: https://developer.blender.org/D2331
2016-08-11Fix T49004 and motion blur of cloth, softbody, etc past the end frame.Alexander Gavrilov
Point cache read code contains checks designed to prevent it reading stale data when the relevant simulation code should instead compute the next frame from the previous one. However in some situations like motion blur subframes the simulation can't possibly do it and just exits. This causes completely incorrect motion blur at or after the last cached frame. To fix, add a parameter that tells the cache code whether it should apply the checks and exit, or read what it can even if stale (true means exactly same as old behavior). Doing this in cache rather than clamping the frame number better in the caller lets it handle the case of incomplete cache that stops before the official last frame. Reviewed By: mont29, lukastoenne Maniphest Tasks: T49004 Differential Revision: https://developer.blender.org/D2144
2015-10-08Fix compilation error with bullet disabledSergey Sharybin
2015-10-08Add rigidbodyworld to id looper.Bastien Montagne
2015-07-21Cleanup: styleCampbell Barton
2015-07-20Minor edits for consistencyCampbell Barton
2015-07-19Cleanup: styleCampbell Barton
Also 'com' as abbreviation for center-of-mass is a bit confusing, rename to 'center'.
2015-07-19Convert rigidbody conversion to looptri.Antony Riakiotakis
Patch D1417 by Martin Felke, with minor edits thanks!
2015-05-12Depsgraph: Add evaluation callbacks for granular nodes updateSergey Sharybin
This commit only adds callbacks which then later be used with major dependency graph commit, keeping the upcoming commit more clean to follow. Should be no functional changes so far still.
2015-02-10Fix T43611: Collision shape of rigid bodies changes inadvertentlySergey Sharybin
The issue was caused by the fix for T34108, which modified DNA in order to get a fallback box collision shape. Not sue why it's needed, we can just get box shape directly, without modifying user's settings.
2014-11-29Cleanup: unused headersCampbell Barton
2014-11-16Cleanup: use BLI_listbase_*** prefix for count,sort,sort_rCampbell Barton
2014-10-29Cleanup: warnings, typosCampbell Barton
2014-07-19Defines: replace ELEM3-16 with ELEM(...), that can take varargsCampbell Barton
2014-07-18Code cleanupCampbell Barton
2014-07-17Cleanup: dead codeCampbell Barton
2014-07-16Clean up of dead code.Bastien Montagne
dm can’t be NULL here (found by Coverity).
2014-07-11Fix T41019: Calculate Mass does not calculate actual volume.Lukas Tönne
This was a ToDo item, for mesh-based rigid body shapes (trimesh, convex) the operator was simply using the bounding box volume, which can grossly overestimate the volume and mass. Calculating the actual volume of a mesh is not so difficult after all, see e.g. http://research.microsoft.com/en-us/um/people/chazhang/publications/icip01_ChaZhang.pdf This patch also allows calculating the center-of-mass in the same way. This is currently unused, because the rigid body system assumes the CoM to be the same as the geometric object center. This is fine most of the time, adding such user settings for "center-of-mass offset" would also add quite a bit of complexity in user space, but it could be necessary at some point. A number of other physical properties could be calculated using the same principle, e.g. the moment of inertia.
2014-05-29Cleanup: Use doxy for more structured commentsCampbell Barton
2014-05-14Dirty fix for memory corruption in the rigid body API.Lukas Tönne
Problem happens when removing a rigid body reference in a constraint, and then jumping to the start frame right away. This will cause a full rebuild of the rigid body world. However, the btRigidBodys are removed before the constraints, and this leaves dangling pointers in the btTypedConstraints, which causes corruption when deleting those constraints later. Fix for now is to explicitly delete constraints in advance when rebuilding, while they still have valid btRigidBody pointers. Ultimately the whole memory management and ownership of Bullet data needs redesign. This is already happening in the particles_refactor branch and could be ported to master separately: https://developer.blender.org/diffusion/B/browse/particles_refactor/source/blender/blenkernel/intern/rigidbody.c
2014-05-12Fix crash removing objects rigid body constraintsCampbell Barton
2014-04-30Code cleanup: remove unused includesCampbell Barton
Opted to keep includes if they are used indirectly (even if removing is possible).
2014-04-01Code cleanup: remove TRUE/FALSE & WITH_BOOL_COMPAT defineCampbell Barton