Image Image Image Image Image
Scroll to Top

To Top

2013 December

16

Dec
2013

No Comments

In code

By admin

FPLib FRP – new mouse and keyboard event sources and signals

On 16, Dec 2013 | No Comments | In code | By admin

Inspired by the signals provided by elm for mouse and keyboard interaction I’ve revised the corresponding event sources and signals in FPLib and updated them to be usable with ENDef.

Mouse:

  • mouseClicksENInputES – EventSource – fires when mouse clicks come in
  • mousePosENInput – FPSignal – tracks mouse position. Needs  .acceptsMouseOver_(true) on the view.
  • mouseIsDownENInput – FPSignal – tracks if mouse is down.

Examples:

Keyboard

  • keyDownENInputES – EventSource – fires when keyboard keys are pressed
  • keysDownENInput – FPSignal -tracks the currently pressed keys.

Examples:

Tags |

14

Dec
2013

No Comments

In code

By admin

RCUK project showcase – game controllers and computer vision in the sonic lab

On 14, Dec 2013 | No Comments | In code | By admin

On the 5th of past June a bunch of kids came to the sonic lab of SARC in Belfast for a presentation showcasing some of what we do at SARC. For my presentation I prepared two patches using Unit Lib. One would loop a sample, with a game controller controlling the sample duration and position in the file and panning it in 3D space using VBAP and the 32 speakers of the sonic lab. The other patch used a webcam to track the movement of sphero glowing ball, it would then play a sound whenever the ball “collided” with a virtual object. Also a sound of footsteps would move together with the ball, positioning the sound in the same physical location as the ball. Both patches showcase nicely the interaction of Unit Lib, VBAPLib and FRP from FPLib. The computer vision part was done in processing via the scala language and is available in github. You can see the code below:

Tags |

12

Dec
2013

No Comments

In code

By admin

UnitLib controls with arrays

On 12, Dec 2013 | No Comments | In code | By admin

After fixing a bug earlier this week, it’s now really nice to manipulate controls with arrays in a Udef.  Just use .ukr and specify a spec for the second argument.

unitlib arg array

Tags |