add preliminary glut replacement test for Bullet 2.x demos

This commit is contained in:
Erwin Coumans
2014-07-03 16:42:50 -07:00
parent 87d44cbb74
commit bae303c5da
12 changed files with 416 additions and 37 deletions

View File

@@ -36,6 +36,11 @@ public:
///rgba input is in range [0..1] for each component
inline void setPixel(int x,int y,const btVector4& rgba)
{
btAssert(x>=0);
btAssert(y>=0);
btAssert(x<m_width);
btAssert(x<m_height);
unsigned char* pixel = &m_buffer[ (x+y*m_width) * 4];
pixel[0] = (unsigned char)(255.*rgba.getX());