| 1 | /** |
| 2 | * +-+-+-+-+-+ +-+-+-+-+-+ |
| 3 | * / /| |\ \ |
| 4 | * / / + + \ \ |
| 5 | * +-+-+-+-+-+ | +-+-+-+-+ | +-+-+-+-+-+ |
| 6 | * | | + / \ + | | |
| 7 | * + THE + / / \ \ + CUBES + |
| 8 | * | |/ +-+-+-+-+-+-+-+ \| | |
| 9 | * +-+-+-+-+-+ | | +-+-+-+-+-+ |
| 10 | * + + |
| 11 | * | SUGAR | |
| 12 | * + + |
| 13 | * | | |
| 14 | * +-+-+-+-+-+-+-+ |
| 15 | * |
| 16 | * Welcome to the Sugar Cubes! This Processing sketch is a fun place to build |
| 17 | * animations, effects, and interactions for the platform. Most of the icky |
| 18 | * code guts are embedded in the GLucose library extension. If you're an |
| 19 | * artist, you shouldn't need to worry about any of that. |
| 20 | * |
| 21 | * Below, you will find definitions of the Patterns, Effects, and Interactions. |
| 22 | * If you're an artist, create a new tab in the Processing environment with |
| 23 | * your name. Implement your classes there, and add them to the list below. |
| 24 | */ |
| 25 | |
| 26 | LXPattern[] patterns(GLucose glucose) { |
| 27 | return new LXPattern[] { |
| 28 | |
| 29 | |
| 30 | // Slee |
| 31 | new MidiMusic(glucose), |
| 32 | new Pulley(glucose), |
| 33 | new Swarm(glucose), |
| 34 | new ViolinWave(glucose), |
| 35 | new BouncyBalls(glucose), |
| 36 | new SpaceTime(glucose), |
| 37 | new ShiftingPlane(glucose), |
| 38 | new AskewPlanes(glucose), |
| 39 | new Blinders(glucose), |
| 40 | new CrossSections(glucose), |
| 41 | new Psychedelia(glucose), |
| 42 | |
| 43 | new Traktor(glucose).setEligible(false), |
| 44 | new BassPod(glucose).setEligible(false), |
| 45 | new CubeEQ(glucose).setEligible(false), |
| 46 | new PianoKeyPattern(glucose).setEligible(false), |
| 47 | |
| 48 | // DanH |
| 49 | new Noise(glucose), |
| 50 | new Play (glucose), |
| 51 | new Pong (glucose), |
| 52 | new Worms(glucose), |
| 53 | |
| 54 | // Alex G |
| 55 | new SineSphere(glucose), |
| 56 | // new CubeCurl(glucose), |
| 57 | |
| 58 | // Shaheen |
| 59 | new HelixPattern(glucose).setEligible(false), |
| 60 | |
| 61 | // Toby |
| 62 | new GlitchPlasma(glucose), |
| 63 | new FireEffect(glucose).setEligible(false), |
| 64 | new StripBounce(glucose), |
| 65 | new SoundRain(glucose).setEligible(false), |
| 66 | new SoundSpikes(glucose).setEligible(false), |
| 67 | new FaceSync(glucose), |
| 68 | |
| 69 | // Jack |
| 70 | new Swim(glucose), |
| 71 | new Balance(glucose), |
| 72 | |
| 73 | // Tim |
| 74 | new TimPlanes(glucose), |
| 75 | new TimPinwheels(glucose), |
| 76 | new TimRaindrops(glucose), |
| 77 | new TimCubes(glucose), |
| 78 | // new TimTrace(glucose), |
| 79 | new TimSpheres(glucose), |
| 80 | |
| 81 | // Ben |
| 82 | // new Sandbox(glucose), |
| 83 | new TowerParams(glucose), |
| 84 | new DriveableCrossSections(glucose), |
| 85 | new GranimTestPattern2(glucose), |
| 86 | |
| 87 | //JR |
| 88 | new Gimbal(glucose), |
| 89 | |
| 90 | // Sam |
| 91 | new JazzRainbow(glucose), |
| 92 | |
| 93 | // Arjun |
| 94 | new TelevisionStatic(glucose), |
| 95 | new AbstractPainting(glucose), |
| 96 | new Spirality(glucose), |
| 97 | |
| 98 | // Basic test patterns for reference, not art |
| 99 | new TestCubePattern(glucose), |
| 100 | new TestTowerPattern(glucose), |
| 101 | new TestProjectionPattern(glucose), |
| 102 | new TestStripPattern(glucose), |
| 103 | new TestBassMapping(glucose), |
| 104 | new TestFloorMapping(glucose), |
| 105 | new TestSpeakerMapping(glucose), |
| 106 | new TestPerformancePattern(glucose), |
| 107 | // new TestHuePattern(glucose), |
| 108 | // new TestXPattern(glucose), |
| 109 | // new TestYPattern(glucose), |
| 110 | // new TestZPattern(glucose), |
| 111 | |
| 112 | }; |
| 113 | } |
| 114 | |
| 115 | LXTransition[] transitions(GLucose glucose) { |
| 116 | return new LXTransition[] { |
| 117 | new DissolveTransition(lx), |
| 118 | new AddTransition(glucose), |
| 119 | new MultiplyTransition(glucose), |
| 120 | new OverlayTransition(glucose), |
| 121 | new DodgeTransition(glucose), |
| 122 | new SwipeTransition(glucose), |
| 123 | new FadeTransition(lx), |
| 124 | // new SubtractTransition(glucose), // similar to multiply - dh |
| 125 | // new BurnTransition(glucose), // similar to multiply - dh |
| 126 | // new ScreenTransition(glucose), // same as add -dh |
| 127 | // new SoftLightTransition(glucose), // same as overlay -dh |
| 128 | }; |
| 129 | } |
| 130 | |
| 131 | // Handles to globally triggerable effects |
| 132 | class Effects { |
| 133 | FlashEffect flash = new FlashEffect(lx); |
| 134 | BoomEffect boom = new BoomEffect(glucose); |
| 135 | BlurEffect blur = new BlurEffect(glucose); |
| 136 | QuantizeEffect quantize = new QuantizeEffect(glucose); |
| 137 | ColorFuckerEffect colorFucker = new ColorFuckerEffect(glucose); |
| 138 | |
| 139 | Effects() { |
| 140 | blur.enable(); |
| 141 | quantize.enable(); |
| 142 | colorFucker.enable(); |
| 143 | } |
| 144 | } |
| 145 | |