Commit Graph

70 Commits

Author SHA1 Message Date
d786fead10 Fixed double inflation in case of co_moving points 2008-08-04 11:50:36 +00:00
c2cd6bebe6 added openmp support for bvhtree build (max processes = tree_type) 2008-08-03 15:37:24 +00:00
0703d9aad1 Following the same optimization as bvh raycast:
*Made nearest surface also use "quad" bvh tree (instead of splitting quads in 2 bvh nodes).
 Again that leaded to improvements in build and query time.

*BLI_bvhtree_find_nearest api is now following the same concept as BLI_bvhtree_ray_cast

removed code relative to bvhtree_from_mesh_tris.
2008-07-19 15:22:38 +00:00
59a2b50171 *Added "kept" mesh above surface option on shrinkwrap to nearest surface
changed a few code relative to project over normal mode (to try to kept code generic and more independent of modifier itself)
2008-07-18 22:24:20 +00:00
785123cc5a Improved build time on BLI_kdopbvh
Its now faster than raytree (both on build and query)

Things tryed:
 X=>Y=>Z=>X split (reduces build time.. but increases query time)
 bucket sorts
	(initial sorts for fast usage of bucket take a long time)
	(nth is linear.. so its quite fast already)

Best times archieve with:
 *usage of 4-ary trees.. reduces build time and tree size but didnt decreased query time
 *quads are on the same node instead of splitting in 2 tris..
	(this actually turned on speedup on query time.. since tree size is reduced by a factor of 2)
 *test ray-bb before ray-primitive gives better times on both tris and quads

Notes:
 measures where made projecting a sphere from inside the head of suzanne.
2008-07-14 18:42:53 +00:00
70730c7226 svn merge -r 15392:15551 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2008-07-13 13:21:01 +00:00
d674041f2b Add raycast ability for BLI_kdopbvh
small bvh fixes:
*allow to create any tree type >= 2
*save split axis

changed shrinkwrap to perform normal cast with raytree and bvh tree and print both times:

Shrinkwrap (OBCube)24578 over (OBSuzanne)504482
target = raytree_create_from_mesh(calc->target): 1260.000000ms
shrinkwrap_calc_normal_projection_raytree(&calc): 1850.000000ms
tree = bvhtree_from_mesh_tri(calc->target): 3330.000000ms
shrinkwrap_calc_normal_projection(&calc): 3780.000000ms

On general query time is bit smaller on bvh tree..
but the build time of bvh is pretty big.
(build time can be removed from both if a cache system is added)
But I am still trying to see how fast I can make the bvh build
2008-07-09 19:43:09 +00:00
39d35edbe6 Merge from trunk
svn merge -r 15104:15202 https://svn.blender.org/svnroot/bf-blender/trunk/blender
2008-06-11 22:53:52 +00:00
a39c8de24b Reason of last commits kdopbvh tree is now on trunk.
Added those files to the branch and added code for NearestNeighbour, needed for shrinkwrap
2008-06-03 19:56:19 +00:00
c84c0201e1 Collisions: Commit of collision cleanup, put kdop-bvh structure into BLI_kdopbvh (just like kdtree interface now), huge speedup for selfcollisions, also better normal collisions (merge from cloth branch) 2008-06-03 18:48:54 +00:00
da36e8abca -= KDOP / Collisions =-
1. Fix for face with index=0 not handled
2008-05-27 22:42:38 +00:00
2666ff7075 -== kdop ==-
1. fix crash on collision
2008-05-25 14:34:03 +00:00
fcea4573dd -== Cloth / kdop ==-
1. Bugfix for crash on enabling cloth on object
2. Correcting kdop nth element sorting function (fix provided by André Pinto)
2008-05-25 13:15:54 +00:00
4bf01e8162 Commit of selfcollisions using new kdop design. Should result in nice speedup. 2008-05-23 20:20:14 +00:00
4d8b5587b8 Pre merge commit (includes commented moving stuff) 2008-05-14 16:09:56 +00:00
83c2acccfb stupid me - i left the wrong line in. 2008-05-13 22:30:59 +00:00
3bb43aaaaf bug in bvhkdop (bad diff merged, pointed out by jaguarandi) 2008-05-13 22:29:50 +00:00
e02bca73d7 New speed imrovements by Mr. Pinto/jaguarandi 2008-05-13 00:42:51 +00:00
db3712a2d8 svn merge -r 14721:14810 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2008-05-12 12:24:52 +00:00
a68c03e409 Reason of all this work: Commiting my work-in-progress on reviewed collision system (better + general access to kdop, uses less memory, put it into BLI_* namespace and usage defined like existing BLI_kdtree_*). Deleted old kdop.c 2008-05-07 20:42:16 +00:00