X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=bvh.h;fp=bvh.h;h=ced346e31af59d3d1bad6af58e890b6629a413dc;hb=a109f126d8adab622e38fbcc2d4281e75255246a;hp=b04c3de2b95f38342259a85d54386854ce295488;hpb=f965094faed4f1828c7a6a6b3ca856bd5f1e5248;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/bvh.h b/bvh.h index b04c3de..ced346e 100644 --- a/bvh.h +++ b/bvh.h @@ -164,7 +164,8 @@ static void bh_subdivide( bh_tree *bh, u32 inode ){ static bh_tree *bh_create( void *lin_alloc, bh_system *system, void *user, u32 item_count, u32 max_per_leaf ){ - assert( max_per_leaf > 0 ); + if( max_per_leaf == 0 ) + vg_fatal_error( "Minimum of 1 per leaf\n" ); u32 alloc_count = VG_MAX( 1, item_count );