From de53382a3d1a7f47684cdda7c27d976c2e234ce9 Mon Sep 17 00:00:00 2001 From: Don Bright Date: Sat, 15 Oct 2011 20:22:06 -0500 Subject: small cleanup diff --git a/tests/OffscreenContextWGL.cc b/tests/OffscreenContextWGL.cc index f120384..844c073 100644 --- a/tests/OffscreenContextWGL.cc +++ b/tests/OffscreenContextWGL.cc @@ -151,14 +151,12 @@ OffscreenContext *create_offscreen_context(int w, int h) // This call alters ctx->window and ctx->openGLContext // and ctx->dev_context if successfull if (!create_wgl_dummy_context( *ctx )) { - fflush(stderr); return NULL; } GLenum err = glewInit(); // must come after Context creation and before FBO calls. if (GLEW_OK != err) { cerr << "Unable to init GLEW: " << glewGetErrorString(err) << "\n"; - fflush(stderr); return NULL; } glewCheck(); diff --git a/tests/cgalpngtest.cc b/tests/cgalpngtest.cc index 7f505a6..41e7eaf 100644 --- a/tests/cgalpngtest.cc +++ b/tests/cgalpngtest.cc @@ -223,8 +223,9 @@ int main(int argc, char **argv) if (cgalRenderer.polyhedron) { CGAL::Bbox_3 cgalbbox = cgalRenderer.polyhedron->bbox(); bbox = BoundingBox(Vector3d(cgalbbox.xmin(), cgalbbox.ymin(), cgalbbox.zmin()), - Vector3d(cgalbbox.xmax(), cgalbbox.ymax(), cgalbbox.zmax())); - } else if (cgalRenderer.polyset) { + Vector3d(cgalbbox.xmax(), cgalbbox.ymax(), cgalbbox.zmax())); + } + else if (cgalRenderer.polyset) { bbox = cgalRenderer.polyset->getBoundingBox(); } diff --git a/tests/csgtestcore.cc b/tests/csgtestcore.cc index e87558d..6c3a7d0 100644 --- a/tests/csgtestcore.cc +++ b/tests/csgtestcore.cc @@ -219,12 +219,12 @@ int csgtestcore(int argc, char *argv[], test_type_e test_type) QDir::setCurrent(original_path.absolutePath()); - try { - csgInfo.glview = new OffscreenView(512,512); - } catch (int error) { - fprintf(stderr,"Can't create OpenGL OffscreenView. Code: %i. Exiting.\n", error); - exit(1); - } + try { + csgInfo.glview = new OffscreenView(512,512); + } catch (int error) { + fprintf(stderr,"Can't create OpenGL OffscreenView. Code: %i. Exiting.\n", error); + exit(1); + } BoundingBox bbox = csgInfo.root_chain->getBoundingBox(); Vector3d center = (bbox.min() + bbox.max()) / 2; -- cgit v0.10.1