summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDon Bright <hugh.m.bright@gmail.com>2011-10-16 01:22:06 (GMT)
committerDon Bright <hugh.m.bright@gmail.com>2011-10-16 01:22:06 (GMT)
commitde53382a3d1a7f47684cdda7c27d976c2e234ce9 (patch)
treebdc7ae6f0e6974bee207ffc5dd55697ab15dbf13
parent7332ec9fe260140ff74506fa2ba95e0a2bbf352e (diff)
small cleanup
-rw-r--r--tests/OffscreenContextWGL.cc2
-rw-r--r--tests/cgalpngtest.cc5
-rw-r--r--tests/csgtestcore.cc12
3 files changed, 9 insertions, 10 deletions
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;
contact: Jan Huwald // Impressum