Git Product home page Git Product logo

opencsg's People

Contributors

floriankirsch avatar t-paul avatar thefloweringash avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

opencsg's Issues

Kill OpenGL 1.x support?

OpenCSG has a bunch of code for supporting OpenGL 1.x (e.g. texture rectangle and non-power-of-two textures).
Is this still needed by anyone, or could we rip out the 1.x support and require OpenGL 2.x+ ?

FYI: OpenSCAD recently deprecated OpenGL 1.x support (openscad/openscad#4550)

Missing header file for gcc-11

While packaging 1.5.0 for Gentoo Linux, I encountered an error for a missing cstddef header file in batch.h, likely for using gcc-11:

In file included from batch.cpp:25:
batch.h:49:9: error: ‘size_t’ does not name a type
   49 |         size_t size() const;
      |         ^~~~~~
batch.h:1:1: note: ‘size_t’ is defined in header ‘<cstddef>’; did you forget to ‘#include <cstddef>’?
  +++ |+#include <cstddef>
    1 | // OpenCSG - library for image-based CSG rendering for OpenGL
batch.cpp: In constructor ‘OpenCSG::Batcher::Batcher(const std::vector<OpenCSG::Primitive*>&)’:
batch.cpp:47:15: error: ‘size_t’ does not name a type
   47 |         const size_t numberOfPrimitives = primitives.size();
      |               ^~~~~~
batch.cpp:27:1: note: ‘size_t’ is defined in header ‘<cstddef>’; did you forget to ‘#include <cstddef>’?
   26 | #include "primitiveHelper.h"
  +++ |+#include <cstddef>
   27 | 
batch.cpp:48:26: error: ‘numberOfPrimitives’ was not declared in this scope
   48 |         mBatches.reserve(numberOfPrimitives);
      |                          ^~~~~~~~~~~~~~~~~~
batch.cpp: At global scope:
batch.cpp:121:5: error: ‘size_t’ does not name a type
  121 |     size_t Batcher::size() const {
      |     ^~~~~~
batch.cpp:121:5: note: ‘size_t’ is defined in header ‘<cstddef>’; did you forget to ‘#include <cstddef>’?

and later directly from batch.h:

In file included from renderGoldfeather.cpp:28:
batch.h:49:9: error: ‘size_t’ does not name a type
   49 |         size_t size() const;
      |         ^~~~~~
batch.h:1:1: note: ‘size_t’ is defined in header ‘<cstddef>’; did you forget to ‘#include <cstddef>’?
  +++ |+#include <cstddef>
    1 | // OpenCSG - library for image-based CSG rendering for OpenGL
In file included from renderSCS.cpp:28:
batch.h:49:9: error: ‘size_t’ does not name a type
   49 |         size_t size() const;
      |         ^~~~~~
batch.h:1:1: note: ‘size_t’ is defined in header ‘<cstddef>’; did you forget to ‘#include <cstddef>’?
  +++ |+#include <cstddef>
    1 | // OpenCSG - library for image-based CSG rendering for OpenGL
make[1]: *** [Makefile:931: renderGoldfeather.o] Error 1

Including the cstddef header after vector solves the issue.

For a full build log, please see the attached file.
opencsg-1.5.0:20220415-095958.log

Make GLEW optional

GLEW is problematic on Linux, as it's built either against EGL or GLX, and Linux distros tend to ship only the GLX build. This makes it hard to ship EGL-based software using OpenCSG.

Feature request: Make GLEW optional, and allow using another GL wrangler instead, which isn't tied to GLX or EGL exclusively. GLAD is an option: https://github.com/Dav1dde/glad

This is related to #1 but calls out a feature request rather than a symptom.

Z fighting when applications render using GLSL

OpenCSG transforms vertices (and hence produces depth values) using the legacy OpenGL fixed pipeline.
On common GPUs (Tested modern Intel iGPU and nVidia), the fixed function pipeline produces slightly different vertex positions than the programmable pipeline. Since OpenCSG relies on applications rendering final images using a GL_EQUAL depth test, this causes z buffer tearing for applications rendering using a programmable pipeline.

For more info, see openscad/openscad#4595

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.