Results 1 to 2 of 2

Thread: Qt OpenGL

  1. #1
    Join Date
    Sep 2015
    Posts
    6
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default Qt OpenGL

    Hey Community,

    since Im new to Qt/openGL I really could need some help.

    Its really hard to find proper tutorials which tell you how to work with initializeGL() and paintGL().. the only tutorials i found just hardcoded a triangle inside of paintGL().
    My problem is that i want to load .obj files, writing a loader should not be a problem.
    I already have a little experience with openGL and know how to draw there but I dont know how to draw with QtWidget.

    Is there any proper tutorial how to use buffer and bind vertices/normals/indices and of which type?
    In openGL i used Gfloat [] to store the vertices and other stuff but i could not get it working in QtGL.

    so my main question is:

    Where to store my data?
    How to use this data in initializeGL()? -> proper binding etc
    How to use this data in paintGL()? -> again binding and other stuff i need

    I would really appreciate if someone could just give me a hint or a little example.


    Greetings

  2. #2
    Join Date
    Jan 2008
    Location
    Alameda, CA, USA
    Posts
    5,230
    Thanks
    302
    Thanked 864 Times in 851 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Qt OpenGL

    You might want to start with this tutorial and this from the Qt examples.

Similar Threads

  1. Replies: 2
    Last Post: 5th July 2017, 13:28
  2. Replies: 0
    Last Post: 17th May 2015, 18:03
  3. Conversion from opengl to opengl es2 (Shapefile rendering)?
    By swapan_gh in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 5th December 2013, 06:59
  4. converting GLUT/OpenGL to Qt/OpenGL - displaying issue
    By yoti13 in forum Qt Programming
    Replies: 1
    Last Post: 25th November 2012, 00:45
  5. Qt with OpenGL ES for ARM9 - All OpenGL ES tests have failed!
    By vinpa in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 3rd December 2009, 10:10

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.