Skip to content

Instantly share code, notes, and snippets.

@lastlegion
Last active December 31, 2015 14:29
Show Gist options
  • Save lastlegion/8000498 to your computer and use it in GitHub Desktop.
Save lastlegion/8000498 to your computer and use it in GitHub Desktop.
For getting camera input
camInput: =>
c = new Camera()
c.init =>
display = new Display(box)
size = display.resolution()
setInterval(=>
me = c.getImage()
me = me.resize size[0], size[1]
me = me.saturate()
dl = me.addDrawingLayer()
dl.noFill()
faces = me.getFaces()
for face in faces
dl.rect(face.x, face.y ,face.width, face.height)
console.log(face)
me.show(display)
,1000/60)
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment