Skip to content

A very basic React/WebAudioAPI based interactive oscillator component

Notifications You must be signed in to change notification settings

jordyjwilliams/inter-reactive-oscillator

Folders and files

NameName
Last commit message
Last commit date
Oct 29, 2022
Sep 5, 2022
Nov 4, 2022
Oct 31, 2022
Sep 3, 2022
Oct 30, 2022
Oct 31, 2022
Nov 4, 2022
Nov 4, 2022
Oct 31, 2022
Mar 16, 2023
Oct 30, 2022
Oct 30, 2022
Oct 30, 2022

Repository files navigation

Inter-React-ive Oscillator

package version Conventional Commits pre commit commitizen friendly styled with prettier

First attempt at a react component using webAudioAPI to create an interactive Oscillator react component.

Installation/Development

This project uses pnpm for package management.

  • To install and run this package you will simply need pnpm

    • npm i -g pnpm
  • For contribution and project setup see Development Dependencies below.

Development Dependencies

In addition to the devDependencies in the package.json this project uses the following packages:

Install Script

These are both available on pip and conda... To manage the cross-platform dependencies an install script has been created:

  • Make the script executable: chmod u+x ./install.sh
  • Run the install script from the project root directory: ./install.sh
  • This script will:
    • Install/check all necessary dependencies and prerequisites from pip/npm.
    • Install the pre-commit hooks with pre-commit
    • Install the from the project.json file with pnpm
  • If you would like to use conda or other package managers then a manual install is required.

The use of the pip/Python packages is simply as they are intended to be more 'cross-platform' than their npm counterparts.

NOTE: The install script has only been tested on Linux. However should work on macOS/possibly windows.

Screenshots

Singular InteractiveOscillator

Single Oscillator

Default App.js

Triple Oscillator

Example Spectrogram

recording

Sandbox (Easiest way to get an idea of the project)

  • Try out the inter-reactive-oscillator is to try it in this Sandbox

Available pnpm Scripts

For development and building:

  • pnpm start: runs default app in development mode. Server will be started at http://localhost:3000.
    • By default 3 nested interactive oscillator objects will be generated in columns.
  • pnpm test: launches the test runner TODO
  • pnpm run build: Builds the app for production to a build directory.
    • Bundles React in production mode
    • Optimizes for the best performance.
    • Build minified, filenames include hashes.

Notes

  • This is still very much in a demo state
  • Quick proof of concept/tutorial/teaching aid for myself.

TODO

UI

  • Add CSS / make this look nice
  • Osc/scope to view created waveform
    • More possibilities in webAudioAPI
  • Fix clamping issues of freq and gain values
    • Remove all text boxes, use increment and decrement buttons

Testing/CICD

  • Add/fix tests
  • Add CICD --> automated testing and branch rules

Docs

  • Improve documentation --> jsdoc, better-docs

About

A very basic React/WebAudioAPI based interactive oscillator component

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published