diff --git a/cocos/physics3d/CCPhysics3DDebugDrawer.cpp b/cocos/physics3d/CCPhysics3DDebugDrawer.cpp index 5d97f096d9..8fcf00b45d 100644 --- a/cocos/physics3d/CCPhysics3DDebugDrawer.cpp +++ b/cocos/physics3d/CCPhysics3DDebugDrawer.cpp @@ -106,7 +106,7 @@ void Physics3DDebugDrawer::draw( Renderer *renderer) _dirty = false; } - _customCommand.setIndexDrawInfo(0, _buffer.size()); + _customCommand.setVertexDrawInfo(0, _buffer.size()); CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1, _buffer.size()); diff --git a/cocos/physics3d/CCPhysics3DDebugDrawer.h b/cocos/physics3d/CCPhysics3DDebugDrawer.h index e7283b5201..63e76c84dc 100644 --- a/cocos/physics3d/CCPhysics3DDebugDrawer.h +++ b/cocos/physics3d/CCPhysics3DDebugDrawer.h @@ -46,7 +46,6 @@ NS_CC_BEGIN * @{ */ -class GLProgram; class Renderer; /** @brief Physics3DDebugDrawer: debug draw the physics object, used by Physics3DWorld */