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. How and Where to start to build a game using Qt

How and Where to start to build a game using Qt

Scheduled Pinned Locked Moved Game Development
16 Posts 6 Posters 9.0k Views
  • 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.
  • D Offline
    D Offline
    Dinesh Balu
    wrote on 18 May 2011, 13:13 last edited by
    #1

    Hi Everyone...
    I wanna create a game using Qt for Symbian 60
    I have some knowledge in application development in Qt
    I have some questions for you ?

    What is QML?What's that for?
    Is QML must in game development?
    Where to get OpenGL libraries for Qt C++? How to import it into project?
    How to create the project for game?
    How to use Accelerometer?
    Can anyone list some free library packages for physics ,audio ,controls and render engine?

    Please help me.... Thank you....

    :)

    1 Reply Last reply
    1
    • C Offline
      C Offline
      Chuck Gao
      wrote on 18 May 2011, 13:24 last edited by
      #2
      1. QML is a declarative language, just like javascript. It's more easier to create UIs than Qt C++.
      2. You can use it every where, and it's also good for game development
      3. I think it's depend on what kind of game you want to develop.Qt also have a OpenGL implementation, so you can use the OpenGL native APIs
      4. You can find the introduction in the Help doc. Qt Assistant specially.
      5. For physics engine, Box2D i think it's for you. And it also have a QML Plugin, you can check the Gitorious. For audio, you can just use Qt MultiMediaKit or QML Audio element.

      Chuck

      1 Reply Last reply
      1
      • P Offline
        P Offline
        Peppy
        wrote on 18 May 2011, 13:27 last edited by
        #3

        That was quite a quick answer Chuck ;-) :-D

        1 Reply Last reply
        0
        • D Offline
          D Offline
          Dinesh Balu
          wrote on 18 May 2011, 13:35 last edited by
          #4

          bq. Where to get OpenGL libraries for Qt C++? How to import it into project?
          bq. I think it’s depend on what kind of game you want to develop.Qt also have a OpenGL implementation, bq. so you can use the OpenGL native APIs

          You mean we can use the OpenGL libraries that we use with Visual Studio ( the dlls and headers ).

          :)

          1 Reply Last reply
          0
          • C Offline
            C Offline
            Chuck Gao
            wrote on 18 May 2011, 13:47 last edited by
            #5

            [quote author="Dinesh Balu" date="1305725722"]
            You mean we can use the OpenGL libraries that we use with Visual Studio ( the dlls and headers ).
            [/quote]

            Actually, it's difference between OpenGL in Windows(which Qt use Mesa, one implementation of OpenGL standards) and OpenGL ES in Symbian.

            And talking about Windows, you just need add "opengl" to .pro file, then use it with QGLWidget. And for simple OpenGL game with QML in both Windows and Symbian, you can try "Qt3D" at "Qt3D Gitorious":git://gitorious.org/qt-labs/qt3d.git.

            Chuck

            1 Reply Last reply
            0
            • Z Offline
              Z Offline
              ZapB
              wrote on 18 May 2011, 14:43 last edited by
              #6

              Qt uses whatever OpenGL implementation is on your system. Qt does not provide it's own OpenGL implementation at all. Commonly, OpenGL implementations are provided by yoru graphics card vendor and are installed along with the other driver components.

              If the vendor does not provide a hardware accelerated implementation of OpenGL then it is possible to use a completle ysoftware based version such as mesa although this will of course not be as fast.

              To you OpenGL with Qt take a look at the QGLWidget class.

              Nokia Certified Qt Specialist
              Interested in hearing about Qt related work

              1 Reply Last reply
              0
              • D Offline
                D Offline
                Dinesh Balu
                wrote on 19 May 2011, 12:49 last edited by
                #7

                Thanks Chuck.Gao and ZapB...

                I tried to run the 5 in a row game given by Qt and I'm getting this error

                bq. Cannot open include file :'QGLWidget' No such file or directory

                does the QtOpenGL module libraries come with the Qt SDK or we have to include like a plugin...

                I'm using Nokia's Qt Creator 2.0.1 - Based on Qt 4.7.0 (32 bit)

                :)

                1 Reply Last reply
                0
                • Z Offline
                  Z Offline
                  ZapB
                  wrote on 19 May 2011, 12:52 last edited by
                  #8

                  You need to add:

                  @
                  QT += opengl
                  @

                  to your .pro file and re-run qmake if you wish to use OpenGL. This tells qmake to append the necessary include and library search paths to the generated Makefiles.

                  I've not looked at the example to see if this does so or even needs OpenGL.

                  Nokia Certified Qt Specialist
                  Interested in hearing about Qt related work

                  1 Reply Last reply
                  0
                  • D Offline
                    D Offline
                    Dinesh Balu
                    wrote on 19 May 2011, 13:02 last edited by
                    #9

                    Thanks ZapB... It worked.....
                    but it now shows multiple errors in 'gl.h'...

                    one that is

                    bq. syntax error: 'void' should be preceeded by ';'

                    when I checked this error... it points to this line in gl.h

                    bq. WINGDIAPI void APIENTRY glAccum (GLenum op, GLfloat value);

                    :)

                    1 Reply Last reply
                    0
                    • Z Offline
                      Z Offline
                      ZapB
                      wrote on 19 May 2011, 13:20 last edited by
                      #10

                      Can you post the code (or point me to it) that is causing this error please? I am not familiar with the example you are talking about.

                      Nokia Certified Qt Specialist
                      Interested in hearing about Qt related work

                      1 Reply Last reply
                      0
                      • D Offline
                        D Offline
                        Dinesh Balu
                        wrote on 19 May 2011, 13:30 last edited by
                        #11

                        I got this project from this link:
                        "5 in a row":http://quitcoding.com/?page=work#5inarow

                        get the source code tar.gz file of the title 5 in a row

                        :)

                        1 Reply Last reply
                        0
                        • L Offline
                          L Offline
                          lexan
                          wrote on 8 Jun 2011, 10:21 last edited by
                          #12

                          is it easy to create a game using QT quick?

                          1 Reply Last reply
                          0
                          • X Offline
                            X Offline
                            xsacha
                            wrote on 25 Jun 2011, 05:03 last edited by
                            #13

                            It depends on the complexity of the game.
                            For your game, I would recommend QML. Do you need to learn Qt/C++ for your class though?

                            Here is a QML game that uses 'levels' so you can see how transitions work:
                            http://qt-apps.org/content/show.php?content=134799

                            • Sacha
                            1 Reply Last reply
                            0
                            • L Offline
                              L Offline
                              lexan
                              wrote on 25 Jun 2011, 05:26 last edited by
                              #14

                              ah. so it will all depend on the "transitions"?

                              I might need to learn Qt/c++ I assume

                              1 Reply Last reply
                              0
                              • X Offline
                                X Offline
                                xsacha
                                wrote on 25 Jun 2011, 06:02 last edited by
                                #15

                                By transitions I just mean how they change from one level to the other. Basically, generating each level.
                                That game I linked to is written in QML/Javascript rather than Qt/C++.

                                P.S. Did you get the email?

                                • Sacha
                                1 Reply Last reply
                                0
                                • L Offline
                                  L Offline
                                  lexan
                                  wrote on 26 Jun 2011, 23:10 last edited by
                                  #16

                                  Yeah I did. Thanks :D It really helped me a lot :)

                                  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