From 9e9d3cd2491f1e9aa57c4e6b492fe28c4406b8d9 Mon Sep 17 00:00:00 2001 From: Julien Valentin Date: Mon, 31 Jul 2017 03:15:03 +0200 Subject: [PATCH] fix a bug : indices pre incremented should be post --- examples/osgsimpleMDI/osgsimpleMDI.cpp | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/examples/osgsimpleMDI/osgsimpleMDI.cpp b/examples/osgsimpleMDI/osgsimpleMDI.cpp index 13ca86dbb..be7bd2c31 100644 --- a/examples/osgsimpleMDI/osgsimpleMDI.cpp +++ b/examples/osgsimpleMDI/osgsimpleMDI.cpp @@ -47,11 +47,6 @@ - -/////////////////////////////////////////////////////////////////////////// -//#define MAXX 1000 -//#define MAXY 1000 - int main( int argc, char**argv ) { @@ -69,9 +64,10 @@ int main( int argc, char**argv ) return 1; } - int MAXX=200;int MAXY=200; - arguments.read("--numX",MAXX); - arguments.read("--numY",MAXY); + int MAXX=200; + int MAXY=200; + arguments.read("--numX",MAXX); + arguments.read("--numY",MAXY); bool MDIenable=true; if(arguments.read("--classic")) @@ -132,10 +128,10 @@ int main( int argc, char**argv ) } else for(int i=0; isetElementBufferObject(ebo); geom->addPrimitiveSet(dre); + for(int z=0; z<4; z++)myIndicesUI[z]+=4; } root->addChild(geom); osgViewer::Viewer viewer;