
Qt 5 and OpenCV 4 Computer Vision Projects
Get up to speed with cross-platform computer vision app development by building seven practical projects
Zhuo Qingliang

BIRMINGHAM - MUMBAI
Qt 5 and OpenCV 4 Computer Vision Projects
Copyright 2019 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing or its dealers and distributors, will be held liable for any damages caused or alleged to have been caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
Commissioning Editor: Richa Tripathi
Acquisition Editor: Sandeep Mishra
Content Development Editor: Digvijay Bagul
Senior Editor: Afshaan Khan
Technical Editor: Abin Sebastian
Copy Editor: Safis Editing
Project Coordinator: Carol Lewis
Proofreader: Safis Editing
Indexer: Rekha Nair
Production Designers: Aparna Bhagat, Alishon Mendonsa
First published: June 2019
Production reference: 1190619
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham
B3 2PB, UK.
ISBN 978-1-78953-258-6
www.packtpub.com
To the one who keeps me motivated.
To my wife and my son for their love, support, and inspiration.
And to the open source communities and the people who are working hard
to build a better world for all of us.
Zhuo Qingliang
Packt.com
Subscribe to our online digital library for full access to over 7,000 books and videos, as well as industry leading tools to help you plan your personal development and advance your career. For more information, please visit our website.
Why subscribe?
Spend less time learning and more time coding with practical eBooks and Videos from over 4,000 industry professionals
Improve your learning with Skill Plans built especially for you
Get a free eBook or video every month
Fully searchable for easy access to vital information
Copy and paste, print, and bookmark content
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.packt.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at customercare@packtpub.com for more details.
At www.packt.com , you can also read a collection of free technical articles, sign up for a range of free newsletters, and receive exclusive discounts and offers on Packt books and eBooks.
Contributors
About the author
Zhuo Qingliang (also known as KDr2 online) is presently working at Beijing Paoding Technology Co. Ltd., a start-up Fintech company in China that is dedicated to improving the financial industry by using artificial intelligence technologies. He has over 10 years experience in Linux, C, C++, Python, Perl, and Java development. He is interested in programming, doing consulting work, participating in and contributing to the open source community (of course, includes the Julia community).
I would like to thank my wife, Feng Xiaoyi, who gave me much encouragement and help while I was writing this book. I would also like to thank my boy, Zhuo Shi; he and his toys played an essential role in the videos of this book.
About the reviewer
Christian Stehno studied computer science, receiving his diploma from Oldenburg University, Germany. Since 2000 he worked in computer science, first as a researcher on theoretical computer science at Oldenburg University, later switching to embedded system design at OFFIS institute. In 2010, he started his own company, CoSynth, which develops embedded sensor and camera systems for industrial automation. In addition, he is a long-time member of the Irrlicht 3D engine developer team.
Packt is searching for authors like you
If you're interested in becoming an author for Packt, please visit authors.packtpub.com and apply today. We have worked with thousands of developers and tech professionals, just like you, to help them share their insight with the global tech community. You can make a general application, apply for a specific hot topic that we are recruiting an author for, or submit your own idea.
Preface
We are entering the age of intelligence. Today, more and more digital devices and applications deliver features facilitated by artificial intelligence technology. Computer vision technology is an important part of artificial intelligence technology, while the OpenCV library is one of the most comprehensive and mature libraries for computer vision technology. OpenCV goes beyond traditional computer vision technology; it incorporates many other technologies, such as DNN, CUDA, OpenGL, and OpenCL, and is evolving into a more powerful library. But, at the same time, its GUI facility, which is not the main feature of the library, isn't evolving very much. Meanwhile, among the many GUI development libraries and frameworks, there is one that is the best at crossing platforms, has the best ease of use, and has the greatest widget diversitythe Qt library. The goal of this book is to combine OpenCV and Qt to develop fully-fledged applications providing many interesting features.
This book is a practical guide to the OpenCV library and GUI application development with Qt. We'll develop a complete application in each chapter. In each of those applications, a number of computer vision algorithms, Qt widgets, and other facilities will be covered, and a well-designed user interface with functional features will be created.
This book is the result of months of hard work, and it would not have been possible without the invaluable help of the Packt team and the technical reviewer.
Who this book is for
This book is designed for all those developers who want to know how to use the OpenCV library to process images and videos, for those who want to learn GUI development with Qt, for those who want to know how to use deep learning in the computer vision domain, and for those who are interested in developing fully-fledged computer vision applications.
What this book covers
, Building an Image Viewer, covers building our first application with Qt. We will build an image viewer, with which we can browse images in a folder. We'll also be able to zoom in or out of the image while viewing it.
Next page