Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. OpenGLES2 3D-Canvas in C++ on Android using Qt 5.2
Qt 6.12 LTS is out! See what's new in the release blog

OpenGLES2 3D-Canvas in C++ on Android using Qt 5.2

Scheduled Pinned Locked Moved Mobile and Embedded
4 Posts 2 Posters 2.2k 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hi All,

    What is the right way to create an OpenGLES2 3D canvas in C++ for custom 3D rendering and to use QtQuick 2.0 for UI programming using Qt 5.2 on Android? Are there some examples for this use case? I was only able to find an "scenegraph/openglunderqml" example (http://qt-project.org/doc/qt-5.0/qtquick/scenegraph-openglunderqml.html). However, it doesn't look compatible with QtQuick 2.0.

    Regards,
    Oleg

    1 Reply Last reply
    0
    • T Offline
      T Offline
      terenty
      wrote on last edited by
      #2

      Hi,
      You are correct, the scenegraph/openglunderqml example shows the right way how things need to be done if you want to mix your custom OpengGL scene & QtQuick 2.0 for UI. But I'm not quite sure what you mean by "it doesn’t look compatible with QtQuick 2.0".
      What is not compatible with QtQuick 2.0 ?
      You can see @import QtQuick 2.0@
      in main.qml of the example...

      1 Reply Last reply
      0
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        Hi Terenty,

        Thanks for your reply and sorry for an imprecise description. It looks like that something went wrong during installation of the Qt library. First

        "import OpenGLUnderQML 1.0"

        failed, then

        "Squircle" class

        from the example code couldn't be found at runtime. However, after reinstalling the library, recompiling the example and redeploying it, it works. I see the animation on my device :-)

        Regards,
        Oleg

        1 Reply Last reply
        0
        • T Offline
          T Offline
          terenty
          wrote on last edited by
          #4

          Nice :) keep it up!

          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
          • Unsolved