Merge branch 'master' of github.com:erwincoumans/bullet3 into master

This commit is contained in:
erwin coumans
2021-03-04 10:31:16 -08:00
40 changed files with 433 additions and 42 deletions

View File

@@ -216,7 +216,8 @@ ELSE(WIN32)
ENDIF(BUILD_CLSOCKET)
IF(NOT APPLE)
LINK_LIBRARIES( pthread ${DL} )
FIND_PACKAGE(Threads)
LINK_LIBRARIES( ${CMAKE_THREAD_LIBS_INIT} ${DL} )
ENDIF(NOT APPLE)
ENDIF(WIN32)

View File

@@ -131,7 +131,8 @@ ELSE(WIN32)
ENDIF(BUILD_CLSOCKET)
IF(NOT APPLE)
LINK_LIBRARIES( pthread ${DL} )
FIND_PACKAGE(Threads)
LINK_LIBRARIES( ${CMAKE_THREAD_LIBS_INIT} ${DL} )
ENDIF(NOT APPLE)
ENDIF(WIN32)

View File

@@ -0,0 +1,19 @@
Copyright (c) 2004 Open Dynamics Framework Group
www.physicstools.org
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided
that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list of conditions
and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
Neither the name of the Open Dynamics Framework Group nor the names of its contributors may
be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS' AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE INTEL OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View File

@@ -0,0 +1,11 @@
Copyright (c) 2007 Francisco Leon Najera. C.C. 80087371.
email: projectileman@yahoo.com
This software is provided 'as-is', without any express or implied warranty.
In no event will the authors be held liable for any damages arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it freely,
subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.

13
Extras/HACD/LICENSE.txt Normal file
View File

@@ -0,0 +1,13 @@
Copyright (c) 2011 Khaled Mamou (kmamou at gmail dot com)
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
3. The names of the contributors may not be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View File

@@ -0,0 +1,12 @@
Bullet Continuous Collision Detection and Physics Library
http://bulletphysics.org
This software is provided 'as-is', without any express or implied warranty.
In no event will the authors be held liable for any damages arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it freely,
subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.

View File

@@ -643,8 +643,8 @@ char *bFile::readStruct(char *head, bChunkInd &dataChunk)
if ((strcmp(oldType, "btShortIntIndexData") == 0))
{
int allocLen = 2;
char *dataAlloc = new char[(dataChunk.nr * allocLen) + 1];
memset(dataAlloc, 0, (dataChunk.nr * allocLen) + 1);
char *dataAlloc = new char[(dataChunk.nr * allocLen) + sizeof(void*)];
memset(dataAlloc, 0, (dataChunk.nr * allocLen) + sizeof(void*));
short *dest = (short *)dataAlloc;
const short *src = (short *)head;
for (int i = 0; i < dataChunk.nr; i++)
@@ -682,8 +682,8 @@ char *bFile::readStruct(char *head, bChunkInd &dataChunk)
// numBlocks * length
int allocLen = (curLen);
char *dataAlloc = new char[(dataChunk.nr * allocLen) + 1];
memset(dataAlloc, 0, (dataChunk.nr * allocLen));
char *dataAlloc = new char[(dataChunk.nr * allocLen) + sizeof(void*)];
memset(dataAlloc, 0, (dataChunk.nr * allocLen) + sizeof(void*));
// track allocated
addDataBlock(dataAlloc);
@@ -719,8 +719,8 @@ char *bFile::readStruct(char *head, bChunkInd &dataChunk)
#endif //
}
char *dataAlloc = new char[(dataChunk.len) + 1];
memset(dataAlloc, 0, dataChunk.len + 1);
char *dataAlloc = new char[(dataChunk.len) + sizeof(void*)];
memset(dataAlloc, 0, dataChunk.len + sizeof(void*));
// track allocated
addDataBlock(dataAlloc);

View File

@@ -1,3 +1,17 @@
/*
Bullet Continuous Collision Detection and Physics Library
http://bulletphysics.org
This software is provided 'as-is', without any express or implied warranty.
In no event will the authors be held liable for any damages arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it freely,
subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
*/
#ifndef DNA_RIGIDBODY_H
#define DNA_RIGIDBODY_H

14
Extras/VHACD/LICENSE.txt Normal file
View File

@@ -0,0 +1,14 @@
Copyright (c) 2011 Khaled Mamou (kmamou at gmail dot com)
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
3. The names of the contributors may not be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View File

@@ -4,6 +4,20 @@
/// this will make it easier to load complex obj files into pybullet
/// see for example export in data/kitchens/fathirmutfak.sdf
///Bullet Continuous Collision Detection and Physics Library
///Erwin Coumans (C) 2018
///http://bulletphysics.org
///
///This software is provided 'as-is', without any express or implied warranty.
///In no event will the authors be held liable for any damages arising from the use of this software.
///Permission is granted to anyone to use this software for any purpose,
///including commercial applications, and to alter it and redistribute it freely,
///subject to the following restrictions:
///
///1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
///2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
///3. This notice may not be removed or altered from any source distribution.
#include <string.h>
#include <stdio.h>
#include <assert.h>