Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Game Development
  4. [Solved] QGLShader, Program completely crashes
Forum Updated to NodeBB v4.3 + New Features

[Solved] QGLShader, Program completely crashes

Scheduled Pinned Locked Moved Game Development
3 Posts 2 Posters 1.3k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    S0urc3C0de
    wrote on last edited by
    #1

    Hello guys,

    I'm trying to create a simulation program which should demonstrate the orbits of the planets in the heliocentric and geocentric models.

    However, I'm stuck at the beginning. I have implemented everything correctly so far, at least, I didn't have any problems and I could already see changes in my window (QWindow).
    The problems came when I tried to implement a loader-function for the vertex and fragment shaders.

    I guess the code itself is right because I've found it on the internet and it doesn't give me any error, however, I am not able to create a QGLShader-Object.
    Whenever I try to create it as follows, the program simply crashes. No error, no further message.
    @m_VertexShader.reset(new QGLShader(QGLShader::Vertex));@

    I even tried it without the QScopedPointers but same problem.

    It would be easier if it was a error in the code but I've absolutly no idea what's going wrong...
    If you need more of my code or more details about how I've implemented the rest of the program, just tell me :)
    I don't really know if it's important for this...

    I'm using Qt 5.3.0 x64 MSVC 2013

    1 Reply Last reply
    0
    • J Offline
      J Offline
      jiangcaiyang
      wrote on last edited by
      #2

      Why use QGL*? Try use QOpenGL*.

      1 Reply Last reply
      0
      • S Offline
        S Offline
        S0urc3C0de
        wrote on last edited by
        #3

        Didn't even know both ways existed :o
        But thanks, it works now :)

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved