Tag Archives: NativeApplication

QuadDistrust

onedayitwillmake No Comments

This is a project I recently created for an installation. It uses the kinect to place the user into a world that has many particles in it – and they basically interact with the particles which are also being influenced by some perlin noise.

It was a spin off of my previous project, CinderRibbons which I never finished because it was getting a little too out of hand.
For this project my goal was simple: Quads influenced by a 3d mapped human skeleton, and perlin noise
I figured that if i scaled down my previous goal, and made it something that was actually attainable i would actually be able to finish the project.

I also decided to put the project on Github, however the code inside is rather messy because as the installation deadline got closer I had to make some, ahem sacrifices. I was actually coding and changing it up until 1 minute before the performer started her dance, while my computer was already hooked up to the projector. That part was pretty frantic.

Here are some images, they are sort of in chronological order, sort of:

Initial “get something on the screen”

Creating a floor plane:


Making quads ‘rise’ from the floor plane

Now add some beautiful perlin noise (Actually this is simplex noise technically)

 

The view from above:

 

All hail the glowing cube:

 

User controlled gravity swarms using the kinect skeleton data mapped back into 3d space:

Project Source Code

https://github.com/onedayitwillmake/QuadDistrust

Using Eclipse with Cinder – A better c++ editor

onedayitwillmake 10 comments

I was really having a hard time with Xcode lately, specifically how its C++ code-completion leaves much to be desired especially if you have a very bad memory. I find myself constantly painfully looking through the header files to find the exact name/case of a function or property.

So I decided to try and see If i could get up and running with Cinder in Eclipse instead, it wasn’t too bad either !!! Just a couple of issues getting the linking right, but that was about it.

Download / Github


Xcode is a great IDE, however it is not great at C++ editing

It provides only very barebones syntax highlighting, even more barebones code completion, and no edit-time error checking.

Cinder is a great library, but it’s very vast – Without code-completion I was very lost/ nearly all the time poking through the header files and opening the .cpp files in other editors so I could learn it more thouroughly.

(Re)-Enter EclipseIDE for C++

This project is presented as is for anyone else who would like to use a C++ editor on osx that is actually aware of your classes.
From what I’ve used it so far, it is much better – but compile times are a little slower, however the time you save while editing is well worth it imo.

Usage

  1. http://www.eclipse.org/downloads/packages/eclipse-ide-cc-developers/heliossr2
  2. Download this project
  3. Import into eclipse workspace (select import existing project in the ‘general’ drop down)
  4. In terminal browse to the projects path and create a symbolic link named ‘CINDER_PATH_LINK’ to where cinder is located
    1. “ln -s foo/bar CINDER_PATH_LINK”
    2. Where ‘foo/bar’ is the path to Cinder such as ‘~/GIT/LIBRARY/CINDER’
  5. [Optional] – RightClick project root, select properties
    1. Select C/C++ Build
    2. Select Settings
    3. Replace ‘g++’ with ‘clang++’ and ‘gcc’ with ‘clang’ for the:
      • MacOS X C++ Linker
      • GCC C++ Compiler
      • GCC C Compiler
    • [Optional] Do the same for the discovery tab
  6. After hitting, apply/ok and closing that window select Project->Build All and project should build successfully.

Screenshots

Debugger / Hitting a breakpoint

Editor

OpenNIStarterKit Block

Editor

Better syntax highlighting, and code sense

Editor

Cinder + threaded OpenNI Skeletontracking

onedayitwillmake 2 comments

Here is some stuff I’ve put together that does Skeletontracking via OpenNI on a separate thread in cinder.
This is based on some code that was posted by Sector9 on the cinder forums, and which is based on the example code that comes with the Nite module.

For some reason my skeleton is offset by some seemingly random number. I’m not sure what’s causing that if someone could take a look
https://github.com/onedayitwillmake/CinderOpenNIBarebones

In order to get this to work, you’ll need to get OpenNI working on it’s own first.
I recommend following these steps, http://c4c.posterous.com/installing-openni-kinect-drivers-and-nite-on

PostADay-Round2#2 – Cinder/C++ Boid class port

onedayitwillmake No Comments

It’s weird porting something that was written into, c++ ported to AS3, back to C++. However If you’ve ever tried to find the C++ version of a boids class. They’re all too complicated for my needs, and i really like the way @soulwire ‘s version works so I started porting it into C++. Based largely on my iOS port of the same class.

https://github.com/onedayitwillmake/CinderBoid

VIDEO DEMOS

WanderSeek

BoidTrailTest from mario gonzalez on Vimeo.

Basic Usage

.cpp

Creation

 
<code>
float boidMaxSpeed = 100;
float boidMaxForce = 25;
 
// Create
_boid = new Boid( boidMaxSpeed, boidMaxForce );
_boid-&gt;setPosition( _target.x, _target.y, _target.z );
 
// Set wander properties
_boid-&gt;setWanderRadius( 75.0f );
_boid-&gt;setWanderMaxTurningSpeed( M_PI / 32 ); // 
_boid-&gt;setWanderLookAheadDistance( 300 );
 
</code>

Update



_boid->wander( 0.3f );
_boid->seek( _mousePositionXYZ, 0.8f );
_boid->update();



One Day It Will Make

onedayitwillmake No Comments

One Day It Will Make

One Day from mario gonzalez on Vimeo.

Ribbon Paint

onedayitwillmake No Comments

I’m very happy to share a new painting application I have created for OSX called RibbonPaint