Giter Site home page Giter Site logo

qmlplotting's People

Contributors

pwuertz avatar tlausch avatar

Stargazers

 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

qmlplotting's Issues

CLANG: Compilation fails with variable length array

Hi Peter,
compilation with Clang of paintPolygon fails, because you are using a variable length array called points
in the paintPolygon() function:

static void paintPolygon(QImage& img, int segments, bool border) {
    int size = img.width();
    QPainter p(&img);
    if (!border) p.setPen(Qt::NoPen);
    p.setBrush(QColor(Qt::white));

    if (segments) {
        QPointF points[segments];

As far as I understand, Clang C++ 11 supports just POD type vaiable length arrays.
The recommendation is to use a Vector in case variable lengh is needed.

Could you please tell me what compiler you are using ?
I am using the latest Mac Yosemite toolchain.

Thanks,
Thomas

Need some direction porting to QT6

I was wondering what your general thoughts are on where to start porting this to QT6. My thought right now is to try and rewrite it to not use the OpenGL specific classes. I am also running into issues with the materialshaders which api has been changed quite a lot. What would you recommend as an approach?

GLSL version 130 is not supported on OSX with legacy profile

Hi Peter,

I tried to run you test examples, but I do get this error:

QOpenGLShader::compile(Fragment): ERROR: 0:1: '' :  version '130' is not supported

This seems to be connected to the OSX running in Legacy Profile, which only supports GLSL up to 1.20.
The Core Profile would have to be activated.
On this Apple page you can switch between Legacy and Core profile:
https://developer.apple.com/opengl/capabilities/GLInfo_1090.html

Core profile can be activated in Qt:
https://wiki.qt.io/How_to_use_OpenGL_Core_Profile_with_Qt

For fun I have reverted GLSL 1.20 in your code and the plots are much better, but the GLSL syntax has changed, so it is no solution.

Run the feature deprecation list on page 2 of the GLSL 1.30 spec backwards:

#version 130 -> #version 120
in -> attribute
out -> varying
Remove fragColor declaration, replace fragColor usage with gl_FragColor

I do not know anything about openGL or GLSL, so I have no idea what to do now.
Do you have any simple solution ?

BR,
Thomas

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.