Point lights no longer disappear when the camera is too close (within their sphere of influence)

--HG--
extra : convert_revision : svn%3A7752d6cf-9f14-4ad2-affc-04f1e67b81a5/trunk%4092
This commit is contained in:
kearwood
2012-09-11 06:45:02 +00:00
parent 754496fe06
commit 377fd8e6b5
13 changed files with 187 additions and 39 deletions

View File

@@ -66,13 +66,11 @@ std::map<std::string, KRModel *> KRModelManager::getModels() {
}
void KRModelManager::bindVBO(const GLvoid *data, GLsizeiptr size) {
assert(size > 0);
if(m_currentVBO.data != data || m_currentVBO.size != size) {
if(m_vbos.find(data) != m_vbos.end()) {
m_currentVBO = m_vbos[data];
assert(m_currentVBO.size == size);
glBindBuffer(GL_ARRAY_BUFFER, m_currentVBO.handle);
} else {
m_vboMemUsed += size;