background preloader

Processing

Facebook Twitter

HTTProcessing. Augmented Reality with #Processing - Tutorial by Amnon Owed. All of the visuals in the above video were created using NyArtoolkit for Processing. NyARToolkit is an augmented reality toolkit built with 100% pure Java. It is derived from ARToolkit-2.72.1. Like Processing itself it’s open source and free! In this tutorial you will learn how to use it to place computer generated imagery correctly onto real world footage. To do this in real-time NyArtoolkit uses markers – black and white images – to determine the three-dimensional position and orientation in the real world. Most likely you will have seen something like this before, but now you will learn how to do it yourself using freely available software.

All right so let’s start with the general setup. 1. 2. 3. 4. All right, time to recap. Example 1: Basic The first example is basic, but holds all of the important techniques that are necessary for more advanced uses of the NyArtoolkit. If you input the following image (place it in the sketch’s data subdirectory)… Main Sketch ARObject. Night #6: Image Sequence Object (with variable speed) I have an example from Learning Processing which demonstrates how to package a “pre-made” animation (i.e. sequence of images) into an object in Processing so that it can be duplicated many times on screen. For tonight’s example, I’m going to make a new version that improves a few key points. First, in the original example the the image files are loaded in the class itself. This is problematic. Sure, if you make one object then you are loading files from the hard drive once. However, if you make many objects, then you are loading the same images over and over again which is totally unnecessary (and can cause problems like using too much memory, stuttering if objects are made during draw(), taking too long to start up, etc.).

We can fix this by loading an array of images in setup() and passing it to the object. Animation a; void setup() { // Load the image sequence first! The class then receives the array in the constructor and passes it to its own array. Here is the example. Ben Fry & Casey Reas - Eyeo Festival 2011. Toxiclibs. Ani - An animation library for Processing. An animation library by Benedikt Groß for the programming environment Processing. Last update, 2013/02/28. Ani 2.5 is a lightweight library for creating animations and transitions.

Easily spoken Ani helps you to move things around on the screen or a bit more abstract, to animate any numeric variable. Most of the time a single line of code like the following one is enough: Ani.to(object, duration, variable name, target position, easing); Target object ("this" or any reference to an object), duration of animation specified in seconds or frames, variable name (which numeric variable is used), easing (the characteristic of motion) ...

The syntax of Ani is created with simplicity of use in mind. Feedback is very welcome, but please use the processing discourse forum for that. Installation ↑Up Unzip and put the extracted Ani folder into the libraries folder of your processing sketches. Demos Check the demos in the distribution of Ani (zip file), or have a look at them by watching the videos. Ani. Fritzing. Processing introduction. Design Génératif. Your Random Numbers – Getting Started with Processing and Data Visualization. Over the last year or so, I’ve spent almost as much time thinking about how to teach data visualization as I’ve spent working with data. I’ve been a teacher for 10 years – for better or for worse this means that as I learn new techniques and concepts, I’m usually thinking about pedagogy at the same time. Lately, I’ve also become convinced that this massive ‘open data’ movement that we are currently in the midst of is sorely lacking in educational components.

The amount of available data, I think, is quickly outpacing our ability to use it in useful and novel ways. How can basic data visualization techniques be taught in an easy, engaging manner? This post, then, is a first sketch of what a lesson plan for teaching Processing and data visualization might look like. I’m going to start from scratch, work through some examples, and (hopefully) make some interesting stuff. Let’s Start With the Data We’re not going to work with an old, dusty data set here. Got it? Now we see the two compared: Processing.org. Nest. Nest A library by Eric Socolofsky for the Processing programming environment. Last update, 10/28/2013. Nest provides a high-level, simple scenegraph for Processing, modeled on the API for the scenegraph and display list implemented by ActionScript 3. Nest is targeted toward developers familiar with AS3, who wish to organize on-screen objects in a display list hierarchy.

As with the AS3 display list, Nest establishes parent-child relationships, applies parent transformations to children, and allows easy manipulation of on-screen objects through member variables such as x, y, rotation, and scale. In addition to the scenegraph, Nest also includes an event-based communication system (built on the Observer pattern as implemented by Java's Observer interface), and some minimal UI components. Download Download Nest version 0.7.0 (9) in .zip format. Installation Unzip and put the extracted Nest folder into the libraries folder of your Processing sketches. Reference. Source. Tested.