Game programming using Qt : a complete guide to designing and building fun games with Qt and Qt Quick 2 using their associated toolsets /


Witold Wysota, Lorenz Haas.
Bok Engelsk 2016 · Electronic books.
Medvirkende
Haas, Lorenz, (author.)
Omfang
1 online resource (512 p.)
Utgave
1st edition
Opplysninger
Includes index.. - Cover; Copyright; Credits; About the Authors; About the Reviewers; www.PacktPub.com; Table of Contents; Preface; Chapter 1: Introduction to Qt; The cross-platform programming; Qt Platform Abstraction; Supported platforms; A journey through time; New in Qt 5; Restructured codebase; Qt Essentials; Qt Add-ons; Qt Quick 2.0; Meta-objects; C++11 support; Choosing the right license; An open source license; A commercial license; Summary; Chapter 2: Installation; Installing the Qt SDK; Time for action - installing Qt using an online installer; Setting up Qt Creator. - Declaring a propertyUsing a property; Time for action - adding properties to the board class; Designing GUIs; Time for action - designing the game configuration dialog; Time for action - polishing the dialog; Accelerators and label buddies; The tab order; Signals and slots; Using designer forms; Direct approach; The multiple-inheritance approach; The single inheritance approach; Time for action - the logic of the dialog; An application's main window; The Qt resource system; Time for action - the main window of the application; Time for action - adding a pull-down menu. - DevicesTime for action - implementing a device to encrypt data; Text streams; Data serialization; Binary streams; Time for action - serialization of a custom structure; XML streams; Time for action - implementing an XML parser for player data; JSON files; Time for action - the player data JSON serializer; Time for action - implementing a JSON parser; QSettings; Summary; Chapter 5: Graphics with Qt; Raster painting; Painter attributes; Widget painting; Time for action - custom-painted widgets; Time for action - transforming the viewport; Time for action - drawing an oscillogram; Input events. - Time for action - creating a toolbarTime for action - filling in the central widget; Time for action - putting it all together; Summary; Chapter 4: Qt Core Essentials; Text handling; Manipulating strings; Encoding and decoding text; Basic string operations; The string search and lookup; Dissecting strings; Converting between numbers and strings; Using arguments in strings; Regular expressions; Time for action - a simple quiz game; Extracting information out of a string; Finding all pattern occurrences; Data storage; Files and devices; Traversing directories; Getting access to the basic file. - Time for action - loading an example projectTime for action - running the Affine Transformations project; Building Qt from sources; Time for action - setting up Qt sources using Git; Time for action - configuring and building Qt; Summary; Chapter 3: Qt GUI Programming; Windows and dialogs; Creating a Qt project; Time for action - creating a Qt Desktop project; Adding child widgets to a window; Managing widget content; Time for action - implementing a tic-tac-toe game board; Qt meta-objects; Signals and slots; Time for action - functionality of a tic-tac-toe board; Properties. - Time for action - making oscillograms selectable. - A complete guide to designing and building fun games with Qt and Qt Quick 2 using associated toolsets About This Book Learn to create simple 2D to complex 3D graphics and games using all possible tools and widgets available for game development in Qt Understand technologies such as QML, Qt Quick, OpenGL, and Qt Creator, and learn the best practices to use them to design games Learn Qt with the help of many sample games introduced step-by-step in each chapter Who This Book Is For If you want to create great graphical user interfaces and astonishing games with Qt, this book is ideal for you. Any previous knowledge of Qt is not required, however knowledge of C++ is mandatory. What You Will Learn Install Qt on your system Understand the basic concepts of every Qt game and application Develop 2D object-oriented graphics using Qt Graphics View Build multiplayer games or add a chat function to your games with Qt's Network module Script your game with Qt Script Program resolution-independent and fluid UI using QML and Qt Quick Control your game flow as per the sensors of a mobile device See how to test and debug your game easily with Qt Creator and Qt Test In Detail Qt is the leading cross-platform toolkit for all significant desktop, mobile, and embedded platforms and is becoming more popular by the day, especially on mobile and embedded devices. Despite its simplicity, it's a powerful tool that perfectly fits game developers' needs. Using Qt and Qt Quick, it is easy to build fun games or shiny user interfaces. You only need to create your game once and deploy it on all major platforms like iOS, Android, and WinRT without changing a single source file. The book begins with a brief introduction to creating an application and preparing a working environment for both desktop and mobile platforms. It then dives deeper into the basics of creating graphical interfaces and Qt core concepts of data processing and display before you try creating a game. As you progress through the chapters, you'll learn to enrich your games by implementing network connectivity and employing scripting. We then delve into Qt Quick, OpenGL, and various other tools to add game logic, design animation, add game physics, and build astonishing UI for the games. Towards the final chapters, you'll learn to exploit mobile device features such as accelerators and sensors to build engaging user experiences. If you are planning to learn about Qt and its associated toolsets to build apps a...
Emner
Sjanger
ISBN
1-78216-888-5

Bibliotek som har denne