mirror of
https://github.com/bulletphysics/bullet3.git
synced 2026-11-10 09:55:34 +00:00
Merge branch 'bulletphysics:master' into master
This commit is contained in:
@@ -1327,8 +1327,8 @@ public:
|
||||
}
|
||||
for (int k = 0; k < m_faceNodeContacts.size(); ++k)
|
||||
{
|
||||
int i = indices[k];
|
||||
btSoftBody::DeformableFaceNodeContact& c = m_faceNodeContacts[i];
|
||||
int idx = indices[k];
|
||||
btSoftBody::DeformableFaceNodeContact& c = m_faceNodeContacts[idx];
|
||||
btSoftBody::Node* node = c.m_node;
|
||||
btSoftBody::Face* face = c.m_face;
|
||||
const btVector3& w = c.m_bary;
|
||||
|
||||
@@ -82,6 +82,10 @@ typedef BOOL(WINAPI* Pfn_GetLogicalProcessorInformation)(PSYSTEM_LOGICAL_PROCESS
|
||||
void getProcessorInformation(btProcessorInfo* procInfo)
|
||||
{
|
||||
memset(procInfo, 0, sizeof(*procInfo));
|
||||
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) && !WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
|
||||
// Can't dlopen libraries on UWP.
|
||||
return;
|
||||
#else
|
||||
Pfn_GetLogicalProcessorInformation getLogicalProcInfo =
|
||||
(Pfn_GetLogicalProcessorInformation)GetProcAddress(GetModuleHandle(TEXT("kernel32")), "GetLogicalProcessorInformation");
|
||||
if (getLogicalProcInfo == NULL)
|
||||
@@ -160,6 +164,7 @@ void getProcessorInformation(btProcessorInfo* procInfo)
|
||||
}
|
||||
}
|
||||
free(buf);
|
||||
#endif
|
||||
}
|
||||
|
||||
///btThreadSupportWin32 helps to initialize/shutdown libspe2, start/stop SPU tasks and communication
|
||||
|
||||
@@ -25,7 +25,7 @@ subject to the following restrictions:
|
||||
#include <float.h>
|
||||
|
||||
/* SVN $Revision$ on $Date$ from http://bullet.googlecode.com*/
|
||||
#define BT_BULLET_VERSION 319
|
||||
#define BT_BULLET_VERSION 320
|
||||
|
||||
inline int btGetVersion()
|
||||
{
|
||||
|
||||
@@ -480,8 +480,8 @@ public:
|
||||
}
|
||||
|
||||
buffer[9] = '3';
|
||||
buffer[10] = '1';
|
||||
buffer[11] = '9';
|
||||
buffer[10] = '2';
|
||||
buffer[11] = '0';
|
||||
}
|
||||
|
||||
virtual void startSerialization()
|
||||
@@ -499,7 +499,6 @@ public:
|
||||
writeDNA();
|
||||
|
||||
//if we didn't pre-allocate a buffer, we need to create a contiguous buffer now
|
||||
int mysize = 0;
|
||||
if (!m_totalSize)
|
||||
{
|
||||
if (m_buffer)
|
||||
@@ -511,14 +510,12 @@ public:
|
||||
unsigned char* currentPtr = m_buffer;
|
||||
writeHeader(m_buffer);
|
||||
currentPtr += BT_HEADER_LENGTH;
|
||||
mysize += BT_HEADER_LENGTH;
|
||||
for (int i = 0; i < m_chunkPtrs.size(); i++)
|
||||
{
|
||||
int curLength = sizeof(btChunk) + m_chunkPtrs[i]->m_length;
|
||||
memcpy(currentPtr, m_chunkPtrs[i], curLength);
|
||||
btAlignedFree(m_chunkPtrs[i]);
|
||||
currentPtr += curLength;
|
||||
mysize += curLength;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user