Book Image

OpenCV for Secret Agents

By : Joseph Howse
Book Image

OpenCV for Secret Agents

By: Joseph Howse

Overview of this book

Table of Contents (15 chapters)
OpenCV for Secret Agents
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Creating Unity assets and adding them to the scene


Custom properties and behaviors in a Unity project are defined through various types of files that are generically called Assets. Our project has four remaining questions and requirements that we must address by creating and configuring assets:

  1. What is the appearance of the surfaces in the scene—namely, the video feed, the detected circles and lines, and the simulated balls and lines? We need to write Shader code and create Material configurations to define the appearance of these surfaces.

  2. How bouncy are the balls? We need to create a Physics Material configuration to answer this all-important question.

  3. Which objects represent a simulated ball and simulated line? We need to create and configure Prefab objects that the simulation can instantiate.

  4. How does it all behave? We need to write Unity Scripts—specifically, code that subclasses a Unity class called MonoBehaviour—in order to control objects in the scene at various stages in their life...