--- a/src/glCompiler.cpp Thu Feb 09 00:32:24 2017 +0200 +++ b/src/glCompiler.cpp Thu Feb 09 00:43:30 2017 +0200 @@ -216,11 +216,11 @@ } -void GLCompiler::compileDocument (LDDocument* doc) +void GLCompiler::compileModel (Model* model) { - if (doc) + if (model) { - for (LDObject* obj : doc->objects()) + for (LDObject* obj : model->objects()) compileObject (obj); } } @@ -235,7 +235,7 @@ } -void GLCompiler::prepareVBO (int vbonum) +void GLCompiler::prepareVBO (int vbonum, Model* model) { // Compile anything that still awaits it compileStaged(); @@ -253,7 +253,7 @@ continue; } - if (it.key()->model() == currentDocument() and not it.key()->isHidden()) + if (it.key()->model() == model and not it.key()->isHidden()) vbodata += it->data[vbonum]; ++it;