summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--RELEASE_NOTES2
-rw-r--r--src/openscad.cc12
-rw-r--r--tests/OffscreenContext.mm12
-rw-r--r--tests/OffscreenView.cc14
4 files changed, 33 insertions, 7 deletions
diff --git a/RELEASE_NOTES b/RELEASE_NOTES
index cc6d99e..d67766c 100644
--- a/RELEASE_NOTES
+++ b/RELEASE_NOTES
@@ -30,7 +30,7 @@ o dxf_linear_extrude() and dxf_rotate_extrude() are now deprecated.
o The file, layer, origin and scale parameters to linear_extrude() and rotate_extrude()
are now deprecated. Use an import() child instead.
o import_dxf(), import_stl() and import_off() are now deprecated. Use import() instead.
-o When exporting geometry from the cmd-line, use the universal -o option. It will export to the correct file format based on the given suffix (dxf, stl, off).
+o When exporting geometry from the cmd-line, use the universal -o option. It will export to the correct file format based on the given suffix (dxf, stl, off). The -x and -s parameters are still working but deprecated.
o F2 and F3 for Save and Reload is now deprecated
OpenSCAD 2011.06
diff --git a/src/openscad.cc b/src/openscad.cc
index 678d87a..d708a8e 100644
--- a/src/openscad.cc
+++ b/src/openscad.cc
@@ -134,6 +134,8 @@ int main(int argc, char **argv)
("help,h", "help message")
("version,v", "print the version")
("o,o", po::value<string>(), "out-file")
+ ("s,s", po::value<string>(), "stl-file")
+ ("x,x", po::value<string>(), "dxf-file")
("d,d", po::value<string>(), "deps-file")
("m,m", po::value<string>(), "makefile")
("D,D", po::value<vector<string> >(), "var=val");
@@ -160,6 +162,16 @@ int main(int argc, char **argv)
if (output_file) help(argv[0]);
output_file = vm["o"].as<string>().c_str();
}
+ if (vm.count("s")) {
+ fprintf(stderr, "DEPRECATED: The -s option is deprecated. Use -o instead.\n");
+ if (output_file) help(argv[0]);
+ output_file = vm["s"].as<string>().c_str();
+ }
+ if (vm.count("x")) {
+ fprintf(stderr, "DEPRECATED: The -x option is deprecated. Use -o instead.\n");
+ if (output_file) help(argv[0]);
+ output_file = vm["x"].as<string>().c_str();
+ }
if (vm.count("d")) {
if (deps_output_file)
help(argv[0]);
diff --git a/tests/OffscreenContext.mm b/tests/OffscreenContext.mm
index eb2f777..2bbaffa 100644
--- a/tests/OffscreenContext.mm
+++ b/tests/OffscreenContext.mm
@@ -48,20 +48,20 @@ OffscreenContext *create_offscreen_context(int w, int h)
glewInit();
#ifdef DEBUG
- cout << "GLEW version " << glewGetString(GLEW_VERSION) << "\n";
- cout << (const char *)glGetString(GL_RENDERER) << "(" << (const char *)glGetString(GL_VENDOR) << ")\n"
+ std::cout << "GLEW version " << glewGetString(GLEW_VERSION) << "\n";
+ std::cout << (const char *)glGetString(GL_RENDERER) << "(" << (const char *)glGetString(GL_VENDOR) << ")\n"
<< "OpenGL version " << (const char *)glGetString(GL_VERSION) << "\n";
- cout << "Extensions: " << (const char *)glGetString(GL_EXTENSIONS) << "\n";
+ std::cout << "Extensions: " << (const char *)glGetString(GL_EXTENSIONS) << "\n";
if (GLEW_ARB_framebuffer_object) {
- cout << "ARB_FBO supported\n";
+ std::cout << "ARB_FBO supported\n";
}
if (GLEW_EXT_framebuffer_object) {
- cout << "EXT_FBO supported\n";
+ std::cout << "EXT_FBO supported\n";
}
if (GLEW_EXT_packed_depth_stencil) {
- cout << "EXT_packed_depth_stencil\n";
+ std::cout << "EXT_packed_depth_stencil\n";
}
#endif
diff --git a/tests/OffscreenView.cc b/tests/OffscreenView.cc
index e34fbce..46951c1 100644
--- a/tests/OffscreenView.cc
+++ b/tests/OffscreenView.cc
@@ -16,6 +16,20 @@ OffscreenView::OffscreenView(size_t width, size_t height)
for (int i = 0; i < 10; i++) this->shaderinfo[i] = 0;
this->ctx = create_offscreen_context(width, height);
if ( this->ctx == NULL ) throw -1;
+
+#ifdef DEBUG
+ GLint rbits, gbits, bbits, abits, dbits, sbits;
+ glGetIntegerv(GL_RED_BITS, &rbits);
+ glGetIntegerv(GL_GREEN_BITS, &gbits);
+ glGetIntegerv(GL_BLUE_BITS, &bbits);
+ glGetIntegerv(GL_ALPHA_BITS, &abits);
+ glGetIntegerv(GL_DEPTH_BITS, &dbits);
+ glGetIntegerv(GL_STENCIL_BITS, &sbits);
+
+ fprintf(stderr, "FBO: RGBA(%d%d%d%d), depth(%d), stencil(%d)\n",
+ rbits, gbits, bbits, abits, dbits, sbits);
+#endif
+
initializeGL();
resizeGL(width, height);
}
contact: Jan Huwald // Impressum