Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt shaders wont compile
Forum Updated to NodeBB v4.3 + New Features

Qt shaders wont compile

Scheduled Pinned Locked Moved General and Desktop
2 Posts 1 Posters 992 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.
  • O Offline
    O Offline
    OmniDragon
    wrote on last edited by
    #1

    For whatever reason I cant seem to load my fragment shaders.
    since it doesn't give me any errors for the vertex shaders I'll just post the fragment shader code. This is from the openGL core profile example code.
    from glwidget.cpp
    @// imagine some code here
    if ( !prepareShaderProgram( ":/Shaders/simple.vert", ":/Shaders/simple.frag" ) )
    return;
    // more code here
    bool GLWidget::prepareShaderProgram( const QString& vertexShaderPath,
    const QString& fragmentShaderPath )
    result = m_shader.addShaderFromSourceFile( QGLShader::Fragment, fragmentShaderPath );@
    from resources.qrc
    @<RCC>
    <qresource prefix="/Shaders">
    <file>simple.frag</file>
    <file>simple.vert</file>
    </qresource>
    </RCC>
    @

    1 Reply Last reply
    0
    • O Offline
      O Offline
      OmniDragon
      wrote on last edited by
      #2

      Nevermind Just faulty error checking. Neither will compile for me.

      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