Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Cinder Creative Coding Cookbook
Cinder Creative Coding Cookbook

Cinder Creative Coding Cookbook: If you know C++ this book takes your creative potential to a whole other level. The practical recipes show you how to create interactive and visually dynamic applications using Cinder which will excite and delight your audience.

eBook
S$53.98 S$59.99
Paperback
S$74.99
Subscription
Free Trial

What do you get with eBook?

Product feature icon Instant access to your Digital eBook purchase
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Billing Address

Table of content icon View table of contents Preview book icon Preview Book

Cinder Creative Coding Cookbook

Chapter 1. Getting Started

In this chapter we will cover:

  • Creating a project for a basic application

  • Creating a project for a screensaver application

  • Creating a project for an iOS touch application

  • Understanding the basic structure of an application

  • Responding to mouse input

  • Responding to key input

  • Responding to touch input

  • Accessing the files dropped onto the application window

  • Adjusting a scene after resizing the window

  • Using resources on Windows

  • Using resources on OSX and iOS

  • Using assets

Introduction


In this chapter we'll learn the fundamentals of creating applications using Cinder.

We'll start by creating different types of applications on the different platforms that Cinder supports using a powerful tool called TinderBox.

We'll cover the basic structure of an application and see how to respond to user input events.

Finally, we will learn how to use resources on Windows and Mac.

Creating a project for a basic application


In this recipe, we'll learn how to create a project for a basic desktop application for Windows and Mac OSX.

Getting ready

Projects can be created using a powerful tool called TinderBox. TinderBox comes bundled in your Cinder download and contains templates for creating projects for different applications for both Microsoft Visual C++ 2010 and OSX Xcode.

To find Tinderbox, go to your Cinder folder, inside which you will find a folder named tools with, TinderBox application in it.

The first time you open TinderBox, you'll be asked to specify the folder where you installed Cinder. You'll need to do this only the first time you open TinderBox. If you need to redefine the location of Cinder installation, you can do so by selecting the File menu and then Preferences on Windows or selecting the TinderBox menu and then Preferences on OS X.

How to do it…

We'll use TinderBox, a utility tool that comes bundled with Cinder that allows for the easy creation of projects. Perform the following steps to create a project for a basic application:

  1. Open TinderBox and choose your project's location. In the main TinderBox window select BasicApp as Target and OpenGL as Template, as shown in the following screenshot:

  2. Choose your project's location. The Naming Prefix and Project Name fields will default to the project's name, as shown in the following screenshot:

  3. Select the compilers you want to use for your project, either Microsoft Visual C++ 2010 and/or OS X Xcode.

  4. Click on the Create button and TinderBox will show you the folder where your new project is located. TinderBox will remain open; you can close it now.

How it works...

TinderBox will create the selected projects for the chosen platforms (Visual C++ 2010 and OS X Xcode) and create references to the compiled Cinder library. It will also create the application's class as a subclass of ci::app::AppBasic. It will also create some sample code with a basic example to help you get started.

There's more...

Your project name and naming prefix will be, by default, the name of the folder in which the project is being created. You can edit this if you want, but always make sure both Project Name and Naming Prefix fields do not have spaces as you might get errors.

The naming prefix will be used to name your application's class by adding the App suffix. For example, if you set your Naming Prefix field as MyCinderTest, your application's class will be MyCinderTestApp.

Creating a project for a screensaver application


In this recipe, we will learn how to create a project for a desktop screensaver for both Windows and Mac OS X.

Getting ready

To get ready with TinderBox, please refer to the Getting ready section of the previous Creating a project for a basic application recipe.

How to do it…

We'll use TinderBox, a utility tool that comes bundled with Cinder that allows easy creation of projects. Perform the following steps to create a project for a screensaver application:

  1. Open TinderBox and choose your project's location. In the main TinderBox window select Screensaver as Target and OpenGL as Template, as shown in the following screenshot:

  2. Select the compilers you want to create a project to, either Microsoft Visual C++ 2010 and/or OS X Xcode.

  3. Click on Create and TinderBox will direct you to the folder where your project was created.

How it works...

TinderBox will create both a project for you and link it against the compiled Cinder library. It will also create the application's class and make it a subclass of ci::app::AppScreenSaver, which is the class with all the basic functionality for a screensaver application. It will also create some sample code with a basic example to help you get started.

Creating a project for an iOS touch application


In this recipe, we'll learn how to create a project for an application that runs on iOS devices such as iPhone and iPad.

Getting ready

To get ready with TinderBox, please refer to the Getting ready section of the Creating a project for a basic application recipe.

Please note that the iOS touch application will only work on iOS devices such as iPhones and iPads, and that the projects created with TinderBox will be for OSX Xcode only.

How to do it…

We'll use TinderBox, a utility tool that comes bundled with Cinder that allows easy creation of projects. Perform the following steps to create a project for an iOS touch application:

  1. Open TinderBox and choose your project's location. In the main TinderBox window select Cocoa Touch as Target and Simple as Template, as shown in the following screenshot:

  2. Select the compilers you want to create a project to, either Microsoft Visual C++ 2010 and/or OS X Xcode.

  3. Click on Create and TinderBox will direct you to the folder where your project was created.

How it works...

TinderBox will create an OS X Xcode project and create the references to link against the compiled Cinder library. It will also create the application's class as a subclass of ci::app::AppCocoaTouch, which is the class with all the basic functionality for a screensaver application. It will also create some sample code with a basic example to help you get started.

This application is built on top of Apple's Cocoa Touch framework to create iOS applications.

Left arrow icon Right arrow icon

Key benefits

  • Learn powerful techniques for building creative applications using motion sensing and tracking
  • Create applications using multimedia content including video, audio, images, and text
  • Draw and animate in 2D and 3D using fast performance techniques

Description

Cinder is one of the most exciting frameworks available for creative coding. It is developed in C++ for increased performance and allows for the fast creation of visually complex, interactive applications."Cinder Creative Coding Cookbook" will show you how to develop interactive and visually dynamic applications using simple-to-follow recipes.You will learn how to use multimedia content, draw generative graphics in 2D and 3D, and animate them in compelling ways. Beginning with creating simple projects with Cinder, you will use multimedia, create animations, and interact with the user.From animation with particles to using video, audio, and images, the reader will gain a broad knowledge of creating applications using Cinder.With recipes that include drawing in 3D, image processing, and sensing and tracking in real-time from camera input, the book will teach you how to develop interesting applications."Cinder Creative Coding Cookbook" will give you the necessary knowledge to start creating projects with Cinder that use animations and advanced visuals.

Who is this book for?

This book is for artists, designers, and programmers who have previous knowledge of C++, but not necessarily of Cinder.

What you will learn

  • Process and analyze images and draw graphics in 2D or 3D
  • Create applications that use multimedia content including video, images, audio, and text
  • Draw and render particles to create powerful simulations
  • Animate using tweens, timeline, paths, and cameras
  • Create interesting animations with particle systems and physics
  • Interact with the user by tracking and sensing from the camera in real-time
  • Generate audio and create sound visualizations

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : May 23, 2013
Length: 352 pages
Edition : 1st
Language : English
ISBN-13 : 9781849518710
Concepts :
Tools :

What do you get with eBook?

Product feature icon Instant access to your Digital eBook purchase
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Billing Address

Product Details

Publication date : May 23, 2013
Length: 352 pages
Edition : 1st
Language : English
ISBN-13 : 9781849518710
Concepts :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
$19.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
$199.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just S$6 each
Feature tick icon Exclusive print discounts
$279.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just S$6 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total S$ 208.97
Cinder Creative Coding Cookbook
S$74.99
Mastering openFrameworks: Creative Coding Demystified
S$66.99
Processing 2: Creative Coding Hotshot
S$66.99
Total S$ 208.97 Stars icon

Table of Contents

12 Chapters
Getting Started Chevron down icon Chevron up icon
Preparing for Development Chevron down icon Chevron up icon
Using Image Processing Techniques Chevron down icon Chevron up icon
Using Multimedia Content Chevron down icon Chevron up icon
Building Particle Systems Chevron down icon Chevron up icon
Rendering and Texturing Particle Systems Chevron down icon Chevron up icon
Using 2D Graphics Chevron down icon Chevron up icon
Using 3D Graphics Chevron down icon Chevron up icon
Adding Animation Chevron down icon Chevron up icon
Interacting with the User Chevron down icon Chevron up icon
Sensing and Tracking Input from the Camera Chevron down icon Chevron up icon
Using Audio Input and Output Chevron down icon Chevron up icon

Customer reviews

Top Reviews
Rating distribution
Full star icon Full star icon Full star icon Full star icon Half star icon 4.3
(14 Ratings)
5 star 50%
4 star 28.6%
3 star 21.4%
2 star 0%
1 star 0%
Filter icon Filter
Top Reviews

Filter reviews by




Efrain Astudillo Jan 11, 2014
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Excellent book you can learn a lot with the basic theory that contains it. It's really easy to learn and very well explain with images. Believe me, you won't bore with this book
Amazon Verified review Amazon
john Jul 07, 2013
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Hi , i just want to start by a thankful to the author for his book. I'm new to Cinder, already i've done some projects with Processing and OpenFrameworks. This book is a very good starting point. In the first chapters everything is describe to start with cinder : make a new project ( for OSX WINDOWS , IOS). Then it work's like a real cookbook , " what you wanna do today :) ? " so you can jump between the chapters to make what you want ( and there is a lot of things, more than i could thought) . I've read some of chapter a this time and i discovered a powerful environment and great tips and workflow process .Each chapter is constructed with a "how to" , the part where you write the code with some little explanation of the different parts so you start with the magic and it's good to learn then a "how it works" to explain the code with subtlety and for the end some stuff to have More Fun with this code !!!!So what i think ? I recommended this book for anybody who wants to start or got an advanced level with Cinder.
Amazon Verified review Amazon
Thomas Helzle Jun 20, 2013
Full star icon Full star icon Full star icon Full star icon Full star icon 5
I work with 3D for 20+ years, have coded in C and C++, Processing and other langauages and recently found out about Cinder through the work of Robert Hodgin (http://roberthodgin.com/) who's a real master of the art.The framework appealed to me, the available tutorials are very well written and inspiring...But you may know the moment when you understood the basics and the principles, but suddenly find out when you try to create your own projects, that you don't have the right questions to ask? You want to do something specific but are not sure yet where to look. The main cinder documentation beyond the tutorials and basic explanations is rather nerdy: namespaces, classes, files... so there's a serious gap between the tutorials and this main part.I know I can hack myself through this (and did so in the past), learn a lot by trial and error about things I never imagined, but it will take me a rather long time and sometimes this time would be better spent on other work.Enter stage left: "Cinder Creative Coding Cookbook" :-)On the cinder forum, the book was offered for review. I read the chapter list and it read basically like everything I wanted to do with Cinder - Not bad. So I applied and got the book.Now I can be pretty critical with books. Often they seem to be written for dummies or repeat themself all the time or overexplain stuff. I get impatient with such books really fast. ;-)No such things here: There isn't even a "hello world" example (which is a good sign IMO).From the first lines of code, you are expected to know what common stuff does and how things work in general programming.And right from the first chapter you do useful things: create your application files with Tinderbox, respond to mouse, key and touch input, deal with drag and drop, resize the window adjusting your content and use resources on windows and OSX/iOS. And that's just the first chapter of 12!The book continues at the same pace showing how to create a GUI, save and load parameters and presets as XML, use 3D space. In the third chapter you already use OpenCV to track features and recognize faces in images...It's well written, short and to the point, perfect for people like me who want to create right away without going through explanations what variables are...So to my great pleasure, I can wholeheartedly recommend this book to people coming from processing or other frameworks that have a general understanding of coding and audio-visual art, but want to take the next step with this very powerful C++ library.And that Cinder is worth your while was nicely proven some days ago, when it won the first "Innovation Grand Prix" at the "Cannes Lions International Festival of Creativity".Have fun creating!
Amazon Verified review Amazon
Sarith Demuni Jul 30, 2013
Full star icon Full star icon Full star icon Full star icon Full star icon 5
The title of this book is exactly what it is -- a cookbook -- and boy is it delicious.That said, I would definitely follow the advice in the product description -- I think this book is a great buy for a beginner, but maybe don't crack it open until after you've spent a few months with creative coding (and C++).BUT -- if you've spent a good amount of time playing with other creative coding frameworks like Processing or openFrameworks, this book is a fantastic run-through of how Cinder handles things. More importantly, and wonderfully, it's chock full of great (general) creative coding recipes. Literally every single lesson is useful in some way and the ideas here are easily translatable to any creative coding language or framework. The book also manages to cut right to the good stuff after some of the intro materials which, as a post-beginner, I really appreciate.
Amazon Verified review Amazon
SuJo Jul 16, 2013
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Creative Coding Cookbook[...]I absolutely LOVED reading this book! I really enjoy the cause and effect style the author uses. When you a presented with an issue and given the work around it really helps cement your knowledge. All of the examples in the book are all usable and you can adapt them as you learn more.I like to keep my reviews short and simple but this book really is worth the cost!
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

How do I buy and download an eBook? Chevron down icon Chevron up icon

Where there is an eBook version of a title available, you can buy it from the book details for that title. Add either the standalone eBook or the eBook and print book bundle to your shopping cart. Your eBook will show in your cart as a product on its own. After completing checkout and payment in the normal way, you will receive your receipt on the screen containing a link to a personalised PDF download file. This link will remain active for 30 days. You can download backup copies of the file by logging in to your account at any time.

If you already have Adobe reader installed, then clicking on the link will download and open the PDF file directly. If you don't, then save the PDF file on your machine and download the Reader to view it.

Please Note: Packt eBooks are non-returnable and non-refundable.

Packt eBook and Licensing When you buy an eBook from Packt Publishing, completing your purchase means you accept the terms of our licence agreement. Please read the full text of the agreement. In it we have tried to balance the need for the ebook to be usable for you the reader with our needs to protect the rights of us as Publishers and of our authors. In summary, the agreement says:

  • You may make copies of your eBook for your own use onto any machine
  • You may not pass copies of the eBook on to anyone else
How can I make a purchase on your website? Chevron down icon Chevron up icon

If you want to purchase a video course, eBook or Bundle (Print+eBook) please follow below steps:

  1. Register on our website using your email address and the password.
  2. Search for the title by name or ISBN using the search option.
  3. Select the title you want to purchase.
  4. Choose the format you wish to purchase the title in; if you order the Print Book, you get a free eBook copy of the same title. 
  5. Proceed with the checkout process (payment to be made using Credit Card, Debit Cart, or PayPal)
Where can I access support around an eBook? Chevron down icon Chevron up icon
  • If you experience a problem with using or installing Adobe Reader, the contact Adobe directly.
  • To view the errata for the book, see www.packtpub.com/support and view the pages for the title you have.
  • To view your account details or to download a new copy of the book go to www.packtpub.com/account
  • To contact us directly if a problem is not resolved, use www.packtpub.com/contact-us
What eBook formats do Packt support? Chevron down icon Chevron up icon

Our eBooks are currently available in a variety of formats such as PDF and ePubs. In the future, this may well change with trends and development in technology, but please note that our PDFs are not Adobe eBook Reader format, which has greater restrictions on security.

You will need to use Adobe Reader v9 or later in order to read Packt's PDF eBooks.

What are the benefits of eBooks? Chevron down icon Chevron up icon
  • You can get the information you need immediately
  • You can easily take them with you on a laptop
  • You can download them an unlimited number of times
  • You can print them out
  • They are copy-paste enabled
  • They are searchable
  • There is no password protection
  • They are lower price than print
  • They save resources and space
What is an eBook? Chevron down icon Chevron up icon

Packt eBooks are a complete electronic version of the print edition, available in PDF and ePub formats. Every piece of content down to the page numbering is the same. Because we save the costs of printing and shipping the book to you, we are able to offer eBooks at a lower cost than print editions.

When you have purchased an eBook, simply login to your account and click on the link in Your Download Area. We recommend you saving the file to your hard drive before opening it.

For optimal viewing of our eBooks, we recommend you download and install the free Adobe Reader version 9.