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
2016-05-13Correct assertsCampbell Barton
2016-05-11Correct check for tree being in BVH cacheCampbell Barton
2016-05-11Remove pointer typedef from BVHCacheCampbell Barton
Used ** arguments unnecessarily, also replace BLI_linklist_apply with while loop.
2016-05-06Correct in-range assert (zero is valid)Campbell Barton
2016-05-05Missed last commitCampbell Barton
2016-05-05bvhutils: remove bitmap countingCampbell Barton
All callers pass in valid number
2016-05-05Add asserts to check bvhutils args are correctCampbell Barton
Would have prevented previous error going unnoticed.
2016-05-05Transform/Snap: EditMesh/BKE_bvhutils API improvementsGermano Cavalcante
Separate the creation of trees from EditMesh from the creation of trees from DerivedMesh. This was meant to simplify the API, but didn't work out so well. `bvhtree_from_mesh_*` actually is working as `bvhtree_from_derivedmesh_*`. This is inconsistent with the trees created from EditMesh. Since for create them does not use the DerivedMesh. In such cases the dm is being used only to cache the tree in the struct DerivedMesh. What is immediately released once bvhtree is being used in functions that change(tag) the DM cleaning the cache. - Use a filter function so users of SnapObjectContext can define how edit-mesh elements are handled. - Remove em_evil. - bvhtree of EditMesh is now really cached in the snap functions. - Code becomes organized and easier to maintain. This is an important patch for future improvements in snapping functions.
2016-01-28Cleanup: warnings & styleCampbell Barton
2016-01-25Transform: optimize vertex snap w/ nearest-to-rayGermano Cavalcante
Use BLI_bvhtree_find_nearest_to_ray for vertex snapping, avoids doing screen-space lookup on each vertex.
2015-10-09Correct own error in editmesh bvhCampbell Barton
Flag mix-up and uninitialized var.
2015-10-09Fix leak creating 'empty' looptri bvh treeCampbell Barton
2015-10-06Fix T46389: Shrinkwrap fails in editmodeCampbell Barton
Own regression caused by fix for T46067, edit-mode bvh only contained unselected faces. This commit adds support for an edit-mode bvh containing all faces.
2015-08-27Use correct size for BVH insertionCampbell Barton
2015-08-21BVH-raycast: Use watertight intersectionsCampbell Barton
By default watertight intersections are used, For callbacks where its not needed, BLI_bvhtree_ray_cast_ex can be called without the BVH_RAYCAST_WATERTIGHT flag. Fixes T45286
2015-08-20Cleanup: remove unused BVH_ONQUAD flagCampbell Barton
2015-07-29Expose bvhtree_sphereray_tri_intersection for general useCampbell Barton
2015-07-23Cleanup: arg namesCampbell Barton
2015-07-23Missed adding BVH callbacks in recent commitCampbell Barton
2015-07-22Add bvhtree_from_mesh_looptri utility functionCampbell Barton
2015-07-22Use doxy sections in bvhutilsCampbell Barton
2015-07-22Use const for BVH mesh arraysCampbell Barton
2015-01-09BKE bvhutils: cleanup and refactor to make it more flexible.Bastien Montagne
You can now use lower-level '_ex' versions of bvh creators to only use part of the mesh's elements in the BVH, and/or create bvh from non-DM sources. Needed for transfer data. Note edges extend version of bvh creator is not added here, not needed so far.
2014-12-27cleanup: redundant tri-normal calculationCampbell Barton
2014-08-19Fix T41479: BLI_bvhtree_find_nearest inaccurateCampbell Barton
Gives noticeably better results for shrink-wrap (even in simple cases)
2014-05-03Fix T39997: Multiple boolean modifiers sharing the same right operand crashesSergey Sharybin
The issue was caused by the temporary CD layers being allocated for subsurf meshes, same as we've got back in 881fb43. In the long run this temporary storage is to be re-considered, but it'll also imply re-considering of the Derivedmesh interaction as well. For now let's use a simpler solution which is forbidding modifiers to call getArray for other objects' derivedMeshes but use an API calls which would allocate local copy of the data preventing race condition of shared data in DM.
2014-04-26Code cleanup: use 'const' for arrays (blenkernel)Campbell Barton
2014-04-20Code cleanup: correct abs useCampbell Barton
also minor cleanup to rotation code
2014-02-02Code cleanup: suffix vars to make obvious they are squaredCampbell Barton
2014-01-22Fix T38312: Crash when using snap transform in edit modeSergey Sharybin
Issue was caused by uninitialized boolean flag.
2014-01-13Make bvhutil safe for multi-threaded usageSergey Sharybin
There were couple of reasons why it wasn't safe for usage from multiple threads. First of all, it was trying to cache BVH in derived mesh, which wasn't safe because multiple threads might have requested BVH tree and simultaneous reading and writing to the cache became a big headache. Solved this with RW lock so now access to BVH cache is safe. Another issue is causes by the fact that it's not guaranteed DM to have vert/edge/face arrays pre-allocated and when one was calling functions like getVertDataArray() array could have been allocated and marked as temporary. This is REALLY bad, because NO ONE is ever allowed to modify data which doesn't belong to him. This lead to situations when multiple threads were using BVH tree and they run into race condition with this temporary allocated arrays. Now bvhtree owns allocated arrays and keeps track of them, so no race condition happens with temporary data stored in the derived mesh. This solved threading issues and likely wouldn't introduce noticeable slowdown. Even when DM was keeping track of this arrays, they were re-allocated on every BVH creation anyway, because those arrays were temporary and were freed with dm->release() call. We might re-consider this a bit and make it so BVH trees are allocated when DM itself is being allocated based on the DAG layout, but that i'd consider an optimization and not something we need to do 1st priority. Fixes crash happening with 05_4g_track.blend from Mango after the threaded object update landed to master.
2013-11-19Fix T37445: Crash with snapping and shrink-wrap modifier.Campbell Barton
Developer note: BVHTREE_FROM_FACES was being used for both edit-mesh and derived-mesh bvh-trees, this could cause index lookup errors in editmode. Fix by adding a new type for editmesh so theres no confusion.
2013-10-31code cleanup: spellingCampbell Barton
2013-10-05rename presets not to use '+' character, also some typo fixes.Campbell Barton
2013-05-08code cleanup: remove unused 'dm' arg from BVHTreeFromMesh.Campbell Barton
2013-04-24simple optimizations for bvhtree_from_mesh_faces() for editmesh, was quite ↵Campbell Barton
inefficient (unneeded loops, not breaking out of face loop early). also correct own oversight - use TRANSFORM_DIST_MAX_RAY rather then when checking for max value in snapDerivedMesh.
2013-04-24alternate fix for [#24887] - r33294.Campbell Barton
Casting a ray onto an editmesh was building a derivedMesh, raytree, then freeing for every ray-cast. Noticed while using ruler+snapping in editmode. Instead of attempting to align the MFace and edit-mesh tessfaces, just use editmesh for ray-casting.
2013-04-14code cleanup: rename BKE_tessmesh -> BKE_editmesh, rename ↵Campbell Barton
EditDerivedBMesh.tc -> em. ('tc' is odd name which isn't used elsewhere).
2013-01-25header cleanup, include BLI before BKE, also use bool for ntreeShaderExecTreeCampbell Barton
2012-10-21style cleanup: trailing tabs & expand some non prefix tabs into spaces.Campbell Barton
2012-10-21style cleanup: commentsCampbell Barton
2012-07-07style cleanup: use c style comments in C codeCampbell Barton
2012-05-30Provide ray hit/nearest information on which side of the quad the ray hit.Daniel Genrich
Patch by MiikaH.
2012-05-06style cleanup: blenkernelCampbell Barton
2012-04-29style cleanup: function calls & whitespace.Campbell Barton
2012-04-29style cleanup: whitespace / commasCampbell Barton
2012-04-28style cleanup: changes to brace placement / newlines - for/while/if/switchCampbell Barton
2012-04-19remove BM_ITER, BM_ITER_INDEX macros, use ELEM or MESH variants only (the ↵Campbell Barton
maceros had unused args in both cases).
2012-04-19style cleanup: BM_ITER / BM_ITER_INDEX / BMO_ITERCampbell Barton
2012-03-24style cleanup: follow style guide for formatting of if/for/while loops, and ↵Campbell Barton
else if's