Possibly (code in issue does not fail on my machine) fix #486. Please test.

This commit is contained in:
vrld
2012-10-15 17:13:08 +02:00
parent 9a15ca3998
commit 6c850fdc98
+6 -3
View File
@@ -139,9 +139,12 @@ void *VBO::map()
void VBO::unmap()
{
glBufferSubDataARB(getTarget(), 0, getSize(), mapped);
free(mapped);
mapped = 0;
if (mapped)
{
glBufferSubDataARB(getTarget(), 0, getSize(), mapped);
free(mapped);
mapped = 0;
}
}
void VBO::bind()