Giter Site home page Giter Site logo

drumhead's Introduction

DrumHead

Spark AR project to play drums by swinging your head

DrumHead demo gif

Try it live!

Getting started

  1. Open DrumHead.arproj in Spark AR Studio
  2. Press Play
  3. You can send the project to your logged in IG/FB account to test

Files

All of the actual logic is inside scripts/drumhead.js

The drum sounds are in sounds. All of the drum sounds are royalty free sounds from musicradar. These sounds were all converted from the original files with online-convert. As a note, Spark AR requires that all sounds are

  • M4A
  • 44100 Hz
  • Mono
  • AAC

The images are in textures. These are all square images created from Procreate. The project expects all images to be square and fudges away the whitespace in code.

Debugging

  • In code, there's DEBUG. Set this to true to enable some debugging logs.
  • The DebugSphere has been set to invisible, but can be set to visible again from the Spark AR Studio UI. This is functionally useless, but displays where the code thinks that the current tip of the drum stick is. The DEBUG flag must be true in order for the location of the sphere to update. Selecting the sphere in the UI can help you see the coordinates of the sphere if it's hidden inside the drum stick.
  • You can't hear the drum sounds when recording since the microphone is enabled. This can be disabled, but then no microphone sounds will be heard in the recording. Otherwise, headphones need to be plugged in while recording to hear the effect sound.

Actual functionality

The original idea was to be able to play along with music, but that doesn't actually work.

  • With the microphone on, you can't hear the sound when you play
  • With the microphone off, you can't add music. If you add music through the music sticker, the sound from the effect disappears

So the only way to play along with music is to play music loudly through another device while recording with the microphone enabled and without hearing the sound from the effect. Then, you can review it after the recording is finished.

drumhead's People

Contributors

acromace avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.