GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - nhandler/chroma-scripts: light animations for chroma

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

138 Commits
138 Commits

Folders and files

NameName
Last commit message
Last commit date
animations
animations
 
 
emulator
emulator
 
 
osc
osc
 
 
static
static
 
 
templates
templates
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
dependencies.txt
dependencies.txt
 
 
run.py
run.py
 
 
server.py
server.py
 
 

Repository files navigation

Chroma-Lights

Chroma lights is a frame work for running annimations for led lights over OSC.

Setup

1. Install virtualenv (skip if you have it already)

sudo easy_install virtualenv

2. Create your virtualenv for chroma-scripts

virtualenv env # or replace 'env' with whatever folder  you want your environment in

3. Activate the environment

source env/bin/activate

4. Install dependencies

pip install -r dependencies.txt

Windows Setup

0. Get and burn a Debian ISO from http://www.debian.org/CD/
1. Wipe your hard drive and install Debian
2. Follow the Setup instructions above

Running

You'll want to activate your virtualenv if it's not already. In your chrome-scripts folder (after having set everything up above before), source env/bin/activate. In order to run the animations locally, we provide a lights emulator written in Processing.

To run the light emulator: $ emulator/lights_emulator

To run an animation: $ ./run.py [animation name]

Contributing

To contribute add a new folder in the animation directory. This folder should be have a unique name for the animation. The folder must contain the following two files:

main.py:

import sys
sys.path.append("./osc")
from oscapi import ColorsOut
...

manifest.json:

{
	"name":"Random Colors",
	"description":"Random colors on 3 second intervals",
	"creator":"RJ and Reed"
}

Each light recieves an input that is a tuple (r,g,b) where each of r, g, b can be 0-1023.

Construct an array of tuples and send them to the OSC server with

pix = [(1023.0,0.0,0.0)]*24
out = ColorsOut()
out.write(pix)

To add simple effects, such as automatic fade-in and fade-out of pixels, use the animations library in place of ColorsOut

from animations import FadeAnimation
pix = [(1023.0,0.0,0.0)]*24
out = FadeAnimation()
out.FADEINRATE = 2.0 #optional
out.FADEOUTRATE = 8.0 #optional, makes things 'trail off'
out.start()
out.write(pix)

Tips and Tricks

Chroma is bright, and can easily be the predominant lighting in the room. Fast blinking of the lights can be intense, so be considerate.

  • Avoid instantaneous changes in both intensity and color
  • Use the provided animation framework to transition between colors

About

light animations for chroma

Resources

Readme
Activity

Stars

2 stars

Watchers

1 watching

Forks

1 fork
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.