Skip to content

Commit

Permalink
Merge branch 'kintel-offscreen-refactor' of github.com:openscad/opens…
Browse files Browse the repository at this point in the history
…cad into kintel-offscreen-refactor
  • Loading branch information
kintel committed Mar 30, 2023
2 parents 48e9616 + d004991 commit 0d81c0a
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/glview/Renderer.cc
Expand Up @@ -132,7 +132,7 @@ bool Renderer::getColor(Renderer::ColorMode colormode, Color4f& col) const

std::string Renderer::loadShaderSource(const std::string& name) {
std::string shaderPath = (PlatformUtils::resourcePath("shaders") / name).string();
std::stringstream buffer;
std::ostringstream buffer;
std::ifstream f(shaderPath);
if (f.is_open()) {
buffer << f.rdbuf();
Expand Down
2 changes: 1 addition & 1 deletion src/glview/offscreen-old/OffscreenContextEGL.cc
Expand Up @@ -58,7 +58,7 @@ class OffscreenContextEGL : public OffscreenContext {

std::string get_gl_info(EGLDisplay display)
{
std::stringstream result;
std::ostringstream result;

const char *vendor = eglQueryString(display, EGL_VENDOR);
const char *version = eglQueryString(display, EGL_VERSION);
Expand Down
2 changes: 1 addition & 1 deletion src/glview/offscreen-old/OffscreenContextGLX.cc
Expand Up @@ -72,7 +72,7 @@ std::string OffscreenContextGLX::getInfo() const {
return {"No GL Context initialized. No information to report\n"};
}

std::stringstream result;
std::ostringstream result;

int major, minor;
glXQueryVersion(this->xdisplay, &major, &minor);
Expand Down
2 changes: 0 additions & 2 deletions src/glview/offscreen-old/OffscreenContextNSOpenGL.mm
Expand Up @@ -21,8 +21,6 @@

NSOpenGLContext *openGLContext;
NSAutoreleasePool *pool;
int width;
int height;
};

std::string OffscreenContextNSOpenGL::getInfo() const {
Expand Down
3 changes: 2 additions & 1 deletion src/glview/offscreen-old/OffscreenContextWGL.cc
Expand Up @@ -43,9 +43,10 @@ class OffscreenContextWGL : public OffscreenContext {
};

std::string OffscreenContextWGL::getInfo() const {
std::stringstream result;
// should probably get some info from WGL context here?
result << "GL context creator: WGL\n"
<< "PNG generator: lodepng\n";
<< "PNG generator: lodepng\n";

return result.str();
}
Expand Down
4 changes: 2 additions & 2 deletions src/platform/PlatformUtils-mac.mm
Expand Up @@ -55,7 +55,7 @@

const std::string PlatformUtils::user_agent()
{
std::stringstream result;
std::ostringstream result;

result << "OpenSCAD/" << openscad_detailedversionnumber
<< " (" << sysinfo(false) << ")";
Expand All @@ -65,7 +65,7 @@

const std::string PlatformUtils::sysinfo(bool extended)
{
std::stringstream result;
std::ostringstream result;

NSOperatingSystemVersion version = [[NSProcessInfo processInfo] operatingSystemVersion];
struct utsname name;
Expand Down

0 comments on commit 0d81c0a

Please sign in to comment.