34,79 €
Papervision3D is a powerful real-time 3D engine for Flash. Papervision3D can take externally created 3D models and render them as Flash content, without requiring end-users to download or install an additional plug-in. It has an outstanding reputation within the Flash community and its ease of use has even impressed experienced 3D game developers. However, getting started with Papervision3D can be daunting and mastering it can be challenging. This book guides you through the easiest way to tackle challenges that you may normally face with Papervision3D and master them effectively.
The book will show you how to build Papervision3D applications from scratch in the easiest way, providing plenty of examples that make sense even if you're not a Flash expert. Papervision3D Essentials serves as a comprehensive guide to getting you started, as well as being an invaluable reference for every Papervision3D user and developer. By the end of this book you will be able to create your own projects with real-time 3D rendering.
Since the first release of Papervision3D in 2007, the authors have been involved in various commercial projects with Papervision3D, building up a deep understanding of the engine. In Papervision3D Essentials, the authors share their knowledge to help you create stunning 3D content in Flash and teach you how to work with one of the most exciting open-source Flash projects around. Papervision3D Essentials shows you how to download Papervsion3D and make it work in Flash, Flash Builder and Flex Builder. It provides a short introduction to Object Oriented Programming and classes for those who are new to non-timeline programming. Then, it takes a closer look at the engine, discussing a broad range of topics from how to work with built-in 3D objects to using and animating cameras, 3D objects, and light. Applying materials and textures, using filters and effects, particles and performance optimizations are also covered. Ultimately, this book will provide you with the information you need to build your first Papervision3D application. Covering the basics, but by no means limited to beginners, Papervision3D Essentials provides a thorough explanation of the engine and numerous tips and tricks, making it a valuable resource for every Papervision3D user.
Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:
Seitenzahl: 534
Veröffentlichungsjahr: 2009
Copyright © 2009 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 authors, Packt Publishing, nor its dealers or distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: September 2009
Production Reference: 1240809
Published by Packt Publishing Ltd.
32 Lincoln Road
Olton
Birmingham, B27 6PA, UK.
ISBN 978-1-847195-72-2
www.packtpub.com
Cover Image by Vinayak Chittar (<[email protected]>)
Authors
Paul Tondeur
Jeff Winder
Reviewers
Trevor Burton
Stuart Caunt
Patrick Rushton
Acquisition Editor
James Lumsden
Development Editor
Darshana D. Shinde
Technical Editor
Gaurav Datar
Indexer
Rekha Nair
Editorial Team Leader
Gagandeep Singh
Project Team Leader
Priya Mukherji
Project Coordinator
Zainab Bagasrawala
Proofreader
Camille Guy
Graphic Coordinator
Nilesh Mohite
Production Coordinator
Aparna Bhagat
Cover Work
Aparna Bhagat
Jeff Winder is an independent Flash developer living and working in Amsterdam, the Netherlands. He discovered Flash and ActionScript in 2003, mainly creating timeline animation, but was soon gripped by non-timeline coding. He has a special interest in new technologies that are related to Flash, especially open source projects such as WiiFlash, FLARToolKit, and Papervision3D. Jeff acquired an MSc in Social Psychology at the University of Amsterdam. He is also a passionate musician, playing guitar and drums. Since 2006, Jeff has been self employed and working for leading agencies. You can contact him at http://www.jeffwinder.nl.
Jeff wrote chapters 1, 3, 5, 6, 10, 11, and 12.
I am not sure whether I should thank my close friends and family for their warm support, or apologize, for not being there for a while. Anyway, I deeply appreciate your patience and understanding, so to everyone who kept asking how the book was coming along—thank you!
I would also like to thank Paul. Writing this book together has been a rewarding experience.
Paul Tondeur is as an Internet entrepreneur who lives and works in Amsterdam, the Netherlands.
He started as a freelance PHP and Flash developer during his study of multimedia technology in 2003. After successfully completing his study, he was asked to become the CTO of a Dutch online marketing agency in 2004. At this company, he developed a strong interest for 3D and got the chance to get professionally involved as the technical lead for serious Second Life projects. However, Second Life was too limited to fulfill his needs to create accessible interactive multiplayer 3D content on the Web, and this is when he found out about Papervision3D during the early days. Because of his passion for the Flash platform, this was love at first sight.
At the beginning of 2009, Paul decided he had to take more advantage of his technical skills as an Internet entrepreneur. Currently he helps other companies as a Unity, Papervision3D, Red5, and mobile streaming consultant. Together with a team of people around him, he is also involved in creating a browser-based MMO, incorporating the usage of Red5, Unity, Flash, and Papervision3D. You can contact him at http://www.paultondeur.com.
Paul is the initiator of this book and wrote chapters 2, 4, 7, 8, 9, and 13.
I would like to thank my family and friends who have been enormously patient and supportive while I was working on this book and had no time for social life. Especially my girlfriend—Marloes—has been of great support. She kept me inspired and motivated when I was working around the clock to finish this challenging task. Last, but not least I want to thank Jeff for being such an encouraging partner to write this book with.
We both would like to thank the following people or groups of people. First of all, this book would never have been possible without the knowledge shared by the Papervision3D community, which we experienced as open and enthusiastic. The many blogs and tutorials have been an important source of information, along with all the questions and answers on the mailing list.
We also would like to express our gratitude towards the reviewers, proofreaders, editors and modelers. The meticulous inspection of the manuscript by the reviewers—Stuart, Trevor, and Patrick—has been of great value. The cooperation with the editors at Packt Publishing —James, Darshana, Zainab, and Gaurav—has been inspiring and satisfying.
We very much appreciate the answers that the Papervision3D team gave us when we had some questions left. Finally, a special thanks to Janneke de Koning and Job Steggink, who created and animated the 3D model used in the book.
Trevor Burton lives in the North of England and currently works as a Senior Software Engineer at Infrared5. He works primarily in Actionscript and Java, and has been working with Flash since Flash 4. He has also worked with Papervision3D since it was released as an open source project in 2006 and has a wealth of experience developing Flash games, from banner adver-games to multi-million pound online gambling applications. In his spare time, he experiments with multiuser and human-computer interaction (http://www.flashmonkey.org).
Stuart Caunt's interest in 3D computer graphics started a long time ago, sometime around the release of Tron in 1982. His interest in 3D modeling lead to him obtaining a Ph.D. in astrophysics and from there the development of parallel-processing models of magnetized fluidflows.
After leaving research he became a software engineer at a research institute in France. From the development of OpenGL 3D data visualization tools, he has pursued other projects of his own in the domain of 3D computer graphics. Most recently this has been web-oriented and he has published a popular series of tutorials at http://blog.tartiflop.com for both Papervision3D and Away3D.
Patrick Rushton is a user-experience designer living in Amsterdam. He works as Interaction Director at communications agency Dynamic Zone, where he uses Flash to create brand-building online experiences that combine interactivity, motion graphics, gaming, and 3D. He blogs about web design, music, 3D modeling, and interactive television on his web site http://www.patrickrushton.com.
This book is about Papervision3D, an open source engine that brings 3D to the Flash Player. Papervision3D is an easy-to-use library written in ActionScript 3.0 that allows developers to create 3D in Flash. Papervision3D lets you build real-time 3D, giving you the tools to create exciting and interactive 3D experiences. From simple banners to advanced online campaigns and from creative portfolios to shooter or racing games, the possibilities are numerous. Because it runs in Flash, you can easily put it on the web, or make it available as installable AIR application.
Getting started with Papervision3D can be quite a challenge due to several initial steps that need to be taken such as downloading the source, installing new tools, and unfamiliarity with custom classes. This book shows you how to download Papervision3D and how to make it work in Flash, Flex Builder, and Flash Builder. A short and down-to-earth introduction to working with classes is included and in a walk-through you will build your first application. From here on, we take a closer look at the engine, discussing a broad range of topics. We will examine how to work with built-in 3D objects, use cameras, and apply materials. Many examples and demos are included, illustrating how to animate cameras, objects and light, and load custom-made models. To add more realism to your objects, you will learn how to add special effects and shaders. After reading this book, you will also know how to optimize the performance and quality of your projects.
This book covers the basics, but is by no means only for beginners. The thorough explanation of the engine and the numerous tricks and tips make it a valuable resource for every Papervision3D user.
Chapter 1—Setting Up is a step-by-step introduction on how to configure Flash CS3, Flash CS4, Flex Builder, or Flash Builder for creating Papervision3D projects. Several ways of downloading the Papervision3D source code are discussed and you will publish an example project to make sure you have configured your authoring tool correctly to get along with this book.
Chapter 2—Building Your First Application will guide you through the steps that lead to building your first Papervision3D application. If you are new to working with classes and object-oriented programming, a brief introduction will help you on your way. Once this topic has been covered, the chapter continues by explaining what a scene in Papervision3D is made of and how to build a basic application.
Chapter 3—Primitives covers primitives, which are basic building blocks for Papervision3D applications. It shows how to create a plane, sphere, cylinder, cone, cube, paper plane, and an arrow. An explanation about how vertices and triangles form a 3D object is included.
Chapter 4—Materials examines how to use the available Papervision3D materials and properties such as interactivity, smoothing, animation, and tiling. You will build a 3D carrousel, made of materials that are discussed throughout this chapter.
Chapter 5—Cameras explains how to affect the way you see objects in 3D space by altering the settings of the camera. Some of these settings originate in real-world cameras such as focus, zoom, and field of view. Other settings are common in 3D, but don't have an equivalent in the real world. All available camera types will be discussed. By the end of this chapter, you will know how to work with a target camera, free camera, debug camera, and spring camera.
Chapter 6—Moving Things Around discusses how to animate your 3D objects and camera by moving or rotating them. You will not only learn how to manually animate objects on enter frame but will also be shown how to use Tweener—a tweening engine that makes it very easy to animate your objects and add all kinds of easing.
Chapter 7—Shading introduces the presence of light in order to add several levels of shade to 3D objects. All available shading types will be discussed, from very lightweight flat shading, to better looking but heavier shading types such as Gouraud shading, cell shading, Phong shading, bump maps, and environment maps.
Chapter 8—External Models is about working with models and animated models that have been created in external programs. A handy list of advice is included that can be used by modelers who are in need of creating a model for use in Papervision3D. The workflow between a few modeling tools and Papervision3D is explained in detail. You will learn how to export models from Autodesk 3ds Max, Maya, SketchUp, and Blender. Several models will be imported into Papervision3D such as the Utah teapot and an animated mill.
Chapter 9—Z-Sorting covers how Papervision3D draws its renders to the viewport and the issues with determining which object should be drawn first. Several strategies to solve these issues are discussed such as viewport layers and quad tree rendering. Examples that are made with an external 3D model will be used to demonstrate these solutions.
Chapter 10—Particles discusses the lightweight particle object, which is a 2D graphic that always faces the camera. The concept of a particle is discussed in detail and we will walk through several examples that demonstrate how you create particle materials, particle fields, emitters, and billboards. We will take a look at Flint, which is an external particle system that provides easy ways to emit particles.
Chapter 11—Filters and Effects covers how you can add all kinds of filters and effects to your renders. Adding glows, shadows, blurs, blend modes and alphas are demonstrated in detail, as well as effects like fire, fog and reflection. We will create an illusion of depth of field by applying several levels of blurs to objects, depending on their distance to the camera.
Chapter 12—3D Vector Drawing and Text covers vector-based shapes in 3D space. They can either be lines, shapes, built-in vector text, or vector text generated by an external typography tool.
Chapter 13— Optimizing Performance discusses how to speed up the performance of your Papervision3D applications. An introduction on what performance exactly is will be given, followed by a broad range of tips and tricks that guarantee the best possible performance.
While reading through chapters you might come across the following icon: . The icon will be combined with the name of an example. The name in between the icons refers to two things—to the full working example in the code bundle and to an appendix in the code bundle. For example, if you see something like Text3DExample, this indicates that the code for Text3DExample is available as a working project that can be found in the code download.
To get along with this book, you need to have Flash CS3, Flash CS4, Flex Builder 3, or Flash Builder 4 installed. All examples run on Mac, Windows, and Linux. Where needed, the book demonstrates how to set up things under Windows and Mac only.
You should also be able to make the examples work with FDT, Flash Develop, and previous Flex Builder versions, although these have not been tested and might require some extra work.
The code and examples in the book have been tested for Papervision3D 2.1 revision 920. Read in Chapter 1 how and where you can download this version.
This book is aimed at Flash and 3D developers who want to get started with creating interactive 3D experiences in Flash, and for those who have already worked with Papervision3D, but want to extend their knowledge and understanding. The book assumes that you have some experience with ActionScript 3.0, but you do not have to be familiar with classes and OOP, an introduction on these topics is included.
Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or may have disliked. Reader feedback is important for us to develop titles that you really get the most out of.
To send us general feedback, simply drop an email to <[email protected]>, and mention the book title in the subject of your message.
If there is a book that you need and would like to see us publish, please send us a note in the SUGGEST A TITLE form on www.packtpub.com or email <[email protected]>.
If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide on www.packtpub.com/authors.
Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.
Visit http://www.packtpub.com/files/code/5722_Code.zip to directly download the example code.
The downloadable files contain instructions on how to use them.
Although we have taken every care to ensure the accuracy of our contents, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in text or code—we would be grateful if you would report this to us. By doing so, you can save other readers from frustration, and help us to improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/support, selecting your book, clicking on the let us know link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata added to any list of existing errata. Any existing errata can be viewed by selecting your title from http://www.packtpub.com/support.
Piracy of copyright material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works in any form on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.
Please contact us at <[email protected]> with a link to the suspected pirated material.
We appreciate your help in protecting our authors, and our ability to bring you valuable content.
You can contact us at <[email protected]> if you are having a problem with any aspect of the book, and we will do our best to address it.
We'll first go over downloading and installing an SVN client that is appropriate for your system (especially Windows and Mac OS X) and then use the client to download the non-compiled source code. If you choose to work with the ZIP or the SWC, you can skip this section and continue reading Downloading the non-compiled source using the ZIP or Downloading the compiled source.
There are a whole bunch of SVN clients available on the Internet. We will first choose a client for Windows, then for Mac OS X.
We will use TortoiseSVN as the SVN client for Windows. We will download and install this program and then use it to download the Papervison3D source code.
A frequently asked question is whether you should download and install Subversion next to TortoiseSVN. The answer is NO. Subversion is included in TortoiseSVN.
Now that you have installed an SVN client, let's use it to download the Papervison3D source code.
Create a new folder somewhere on your computer. You can call it whatever you want. In this book, we'll call it papervision3d_source. It's the folder that will contain the Papervision3D source code.Right-click on this folder. You'll notice that your context menu now has some extra options involving TortoiseSVN.Select SVN Checkout….A window pops up asking for the URL of repository. Fill in: http://papervision3d.googlecode.com/svn/trunk/as3/trunkThe structure and names of the folders on the SVN server may vary over time. If the address above is not valid, please visit Papervision3D's Google Code page or the errata page that accompanies this book.
The download may take a while to complete due to the size of the files included. The Papervision3D team added not only the source code to the SVN server, but also examples and documentation for the project. When the download has completed, open the papervision3d_source folder and take a quick look at what's inside. You will see quite an amount of folders and files. These are the folders and files you have just downloaded.
Every now and then you may want to download the latest version of the source code to keep the code up-to-date. Similar to your first checkout, go to the papervision3d_source folder and right-click on it. But this time select TortoiseSVN | Update. The latest revision on the SVN server will now get incorporated in your local working copy.
Next, we will configure the authoring tool of your choice so that we can actually use the code. You can continue reading Configuring your authoring tool for Papervison3D.
For Mac OS X, we will use svnX as our SVN client. We will download and install this program and then use it to download the Papervison3D source code.
If you visit the download page of svnX at http://www.lachoseinteractive.net/en/community/subversion/svnx/download/, it will tell you that there are two requirements for using svnX. It assumes you have Mac OS X 10.4 or higher and you'll need a working install of Subversion. Although there are several others available, the svnX download page links to a working install that was made by Martin Ott. So, let's get this one first.
Now that we have successfully installed svnX as our SVN client, we're ready to download the Papervision3D source code.
The structure and names of the folders on the SVN server may vary over time. If the address above is not valid, svnX will display an error message: Not a valid URL. If so, please visit the errata page that accompanies this book.
The download may take a while to complete, due to the size of the files included. The Papervision3D team added not only the source code to the SVN server, but also examples and documentation for the project. When the download is complete, open the papervision3d_source folder and take a quick look at what's inside. These are the folders and files you have just downloaded.
If you want to download the latest version of the source code to keep the code up-to-date, open svnX and go to Window | Working Copies. Double-click the working copy of Papervision3D and a new window will appear. Click the green Update button to replace the local copy in your papervision3d_source folder with the latest revision on the SVN server.
Next, we will configure the authoring tool of your choice, so that we can actually use the code. Continue reading Configuring your authoring tool for Papervision3D.
The ZIP file holds non-compiled source code. You can find it on the Google Code pages of Papervision3D. As discussed before, the examples in this book are based on Papervision3D 2.1, revision 920. We will download this version to make sure that all the examples work. The next steps demonstrate how to get the ZIP with this revision.
At a certain moment, for instance when you need features that are incorporated in the most recent revision, you may decide you want to replace the code with the latest available version of the ZIP. Just look for the most recent, featured ZIP file on the list, repeat the download and extract process, and replace the folders in your papervision3d_source folder by your newly extracted folders. The source code will automatically be updated.
Next, we will configure the authoring tool of your choice so that we can actually use the code. Continue reading Configuring your authoring tool for Papervision3D.
If your authoring tool is Flex Builder, Flash Builder, or Flash CS4, both the non-compiled and the compiled source code will work for you. If you've decided to work with the compiled source code, you can download the SWC that contains this code from the Google Code page of Papervision3D. As the examples in this book are based on Papervision3D 2.1, revision 920, we will download this version to make sure that all the examples work. The next steps demonstrate how to get the SWC with revision 920.
Every now and then you may want to download the latest version of the SWC to keep up with the changes that are being made to the project. Just look for the most recent, featured SWC file on the list, repeat the download process and replace your current SWC with the updated SWC.
Now that we have downloaded the source code, we will configure the authoring tool of our choice so that we can actually use Papervision3D. If your authoring tool is Flex Builder or Flash Builder, you can continue reading Configuring Flex Builder and Flash Builder.
We have downloaded the source code, but how can we make it work? Normally, if you download a software program, like we did with our SVN client, you would need to install it. But keep in mind that Papervision3D is not a software program—it's a library of folders and classes. What we need to do now is tell Flash where these folders are located so that we can access them when we work in the Flash IDE. In other words, within Flash we must set the path to the source code in our papervision3d_source folder. This is what we mean by configuring Flash.
We have downloaded the source code, but how can we make it work? Normally, if you download a software program, like we did with our SVN client, you would need to install it. But keep in mind that Papervision3D is not a software program—it's a library of folders and classes. What we need to do now is tell Flash where these folders are located so that we can access them when we work in the Flash IDE. In other words, within Flash we must set the path to the source code in our papervision3d_source folder. This is what we mean by configuring Flash.
Flash can handle the following two ways of setting such a path:
We will use the second approach in this book, so we'll only have to set the path once.
Both Flash CS3 and CS4 lets you set the path to the non-compiled source, but only Flash CS4 allows for setting the path to a SWC or SWC folder. If you decided to work with the SWC, you can continue reading Set the path to the compiled source code in Flash (only CS4).
If you've downloaded the ZIP or used SVN, the following steps will set the path to the source code from within Flash:
Now that the dialog windows are closed, it's a good idea to check if the process of downloading and setting paths went right. To do this, we will take a look at one of the examples that comes with this book. Continue reading Running an example in Flash.
Now that the dialog windows are closed and the path to the SWC is set, it may be a good idea to check if everything went right. To do this, we will take a look at one of the examples that comes with this book.
Let's open the example that is shipped with this book using the Flash IDE. By doing this, we'll be able to find out if we installed and configured everything correctly. More than that, it gives us the chance to see some Papervision3D at work!
Do you see the earth turning and a 3D text? Congratulations, you've set up Papervision3D correctly!
If you get errors when compiling this project, please read the previous sections again. The most common error is:
Type was not found or was not a compile-time constant: [ class name ]
If you get this error, you probably have not set the path correctly.
By configuring Flex Builder and Flash Builder, we mean that we need to set the path to the Papervision3D source code. We will first import an existing project (that is, the example that is shipped with this book) and then set the path to the source code for this project.
Both Flex Builder and Flash Builder allow you to import projects. Let's import one of the examples that come with this book.
Take a look at the Problems view. Chances are that you will see some errors.
The project we imported uses the Papervision3D source code. The developer has set the path to the code from his authoring tool. But this path could be, and probably is, different on your computer, as it's most likely that we named our source folder differently and stored it somewhere else than the developer did. Therefore, let's fix that by changing the path.
Whether you import an existing project, or create a new one, you must always set the correct path to the external source code you would like to use. Keep in mind that in this example we are importing an existing project and that we will change the path that has previously been added. However, if you create a new project, no path has been added yet. Therefore, every time you create a new project, you must add the path to the source code that you want to access.
Setting the path to the SWC requires a different approach than setting it to the non-compiled source code. We'll first set the path to the non-compiled source. If you decided to use the SWC, you can continue reading Setting the path to the SWC in Flex Builder and Flash Builder.
If you've downloaded the ZIP or used SVN, the following steps will set the path to the source code from your project:
The path that we've changed was set by the developer of the project, but would not have worked for us. We needed to set the path to the source folder on our computer.
If you've downloaded the SWC, the following steps will set the path to it from your project:
The path we removed pointed to the Papervision3D source code that was stored on the developer's computer. We needed to remove this path because we have decided to use the SWC instead of the non-compiled source code.
The errors in the Problems view should be gone now. But what just happened? First we imported an existing project that came with the examples. Then we edited the path so that it points to our Papervision3D source code. Now that we have configured this project correctly, we're ready to run the example. Select the project and publish it.
Your browser should open and show the compiled SWF. Do you see the earth turning accompanied by a 3D text? Congratulations, you've set up Papervision3D correctly!
If you get errors when compiling this project, please re-read the previous sections. The most common error is:
The definition of [ class name ] was not found.
If you get this error, you probably have not set the path correctly.
If you're familiar with the ActionScript 3.0 Language Reference, you will undoubtedly know that it's a good source for looking things up about ActionScript. It's an extensive and handy reference manual for the API's for Flash Player and Adobe Air.
Papervision3D also provides documentation. If you have downloaded the source code through SVN, you can find it inside the papervision3d_source | docs folder. Opening index.html gives you an overview of all the packages and classes.
In case you didn't choose to work with SVN, there is also an online version of the documentation. You can find it here: http://docs.pv3d.org/.
The address of the online documentation may vary over time. If the address above is not valid, please visit the errata page that accompanies this book.
You can use documentation to look up how to use methods and properties, along with event handlers and listeners. It's a good idea to add either of the index.html pages as a bookmark in your browser. That way you always have easy access to the documentation. Keep in mind though that many open source projects are a constant work in progress. This may result in incomplete documentation and a lack of sample code.
Papervision3D is not a software program—it's basically a library of ActionScript classes. This open source library is available in two forms—compiled and non-compiled. The compiled code is downloadable as an SWC, which is compatible with Flex Builder, Flash Builder, and Flash CS4, but not with Flash CS3. The non-compiled code is downloadable through Subversion and as a ZIP file, and works for all four authoring tools.
We have discussed how to download and install SVN clients for both Windows and Mac OS X. With those clients we downloaded the non-compiled source code through SVN. We've also seen how to download the SWC and the ZIP. Then we configured the authoring tool of our choice by setting paths to Papervision3D. To test if our setup was done correctly, we ran some examples. Finally, we shed some light on where to find documentation.
In the next chapter, we're going to get our hands dirty by creating our first Papervision3D scene. Before we build this simple application, we will walk through some basics of 3D theory and object-oriented programming.
In this chapter, we will get our hands dirty by programming our first lines of code. Those who are new to object-oriented programming and classes can start with a short introduction about this subject. If you are already familiar with working with classes, you can skip these sections and learn what a 3D scene in Papervision3D is made of. Once this has been made clear, we can write our first basic application! Parts of this application will be wrapped up as the default class that we will use throughout the book.
This chapter covers the following:
