diff options
author | rcoh <rcoh@mit.edu> | 2011-01-27 17:21:23 -0500 |
---|---|---|
committer | rcoh <rcoh@mit.edu> | 2011-01-27 17:21:23 -0500 |
commit | 890e167b2cd2a438f81a759833fc4f1c876c4142 (patch) | |
tree | 71b12f331fc7877d021f04c7abc231bbd853da98 /config | |
parent | 5fb3ea060025241105dc8e9a174513c112f9a133 (diff) | |
parent | 51d58d511d474cb01339d504624b9418c75869e3 (diff) |
Merge branch 'osc'
Conflicts:
behaviors/Square.py
pixelcore/PixelStrip.py
Diffstat (limited to 'config')
-rw-r--r-- | config/6thFloorOSC.xml | 286 | ||||
-rw-r--r-- | config/osc.xml | 10 |
2 files changed, 296 insertions, 0 deletions
diff --git a/config/6thFloorOSC.xml b/config/6thFloorOSC.xml new file mode 100644 index 0000000..792fd0c --- /dev/null +++ b/config/6thFloorOSC.xml @@ -0,0 +1,286 @@ +<!---All configuration items contain a "Class" tag specifying the python class they represent, and an "Args" tag specifying the args to be passed in.--> +<LightInstallation> + <InstallationConfiguration> + <Defaults> + <PixelMapper>simplemap</PixelMapper> + </Defaults> + </InstallationConfiguration> + <PixelConfiguration> + <InheritsFrom>layouts/60StripLayout.xml</InheritsFrom> + <!--<InheritsFrom>layouts/BasicSixStrip.xml</InheritsFrom--> + </PixelConfiguration> + <PixelMapperConfiguration> + <PixelMapper> + <Class>pixelmappers.SimpleMapper</Class> + <Args> + <Id>simplemap</Id> + <CutoffDist>20</CutoffDist> + </Args> + </PixelMapper> + <PixelMapper> + <Class>pixelmappers.GaussianMapper</Class> + <Args> + <Id>gaussmap</Id> + <CutoffDist>30</CutoffDist> + <MinWeight>0.1</MinWeight> + <Width>10</Width> + <Height>1</Height> + </Args> + </PixelMapper> + </PixelMapperConfiguration> + <RendererConfiguration> + <Renderer> + <InheritsFrom>renderers/60StripSeq.xml</InheritsFrom> + </Renderer> + <Renderer> + <InheritsFrom>renderers/Pygame.xml</InheritsFrom> + </Renderer> + </RendererConfiguration> + <InputConfiguration> + <InputElement> + <Class>inputs.OSCInput</Class> + <Args> + <Id>osc</Id> + <Port>12345</Port> + <RefreshInterval>10</RefreshInterval> + </Args> + </InputElement> + <InputElement> + <Class>inputs.PygameInput</Class> + <Args><!--Passed as a dictionary--> + <Id>pygame</Id> + <RefreshInterval>10</RefreshInterval> + </Args> + </InputElement> + <!--<InputElement> + <Class>inputs.TCPInput</Class> + <Args> + <Id>tcp</Id> + <Port>20120</Port> + <RefreshInterval>10</RefreshInterval> + </Args> + </InputElement>--> + <InputElement Id="followmouse"> + <InheritsFrom>inputs/MouseFollower.xml</InheritsFrom> + </InputElement> + <InputElement> + <Class>inputs.RandomLocs</Class> + <Args> + <Id>randomLoc</Id> + </Args> + </InputElement> + </InputConfiguration> + <BehaviorConfiguration> + <Behavior> + <Class>behaviors.EchoBehavior</Class> + <Args> + <Id>echo</Id> + <z-index>0</z-index> + <RenderToScreen>False</RenderToScreen> + </Args> + </Behavior> + <Behavior> + <Args> + <Id>touchosc</Id> + </Args> + <Class>behaviors.TouchOSC</Class> + </Behavior> + <Behavior Id="redshift"> + <InheritsFrom>behaviors/RedShift.xml</InheritsFrom> + </Behavior> + <Behavior Id="colorchange"> + <InheritsFrom>behaviors/RandomColor.xml</InheritsFrom> + </Behavior> + <Behavior Id="decay"> + <InheritsFrom>behaviors/PixelDecay.xml</InheritsFrom> + </Behavior> + <Behavior Id="singleframe"> + <InheritsFrom>behaviors/SingleFrame.xml</InheritsFrom> + </Behavior> + <Behavior Id="slowdecay"> + <InheritsFrom>behaviors/PixelDecay.xml</InheritsFrom> + <Args> + <Coefficient>.01</Coefficient> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.XYMove</Class> + <Args> + <Id>xymove</Id> + <XStep>5</XStep> + <YStep>2</YStep> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.RestrictLocation</Class> + <Args> + <Id>xbounce</Id> + <Action>{val}*-1</Action> + <ParamName>XStep</ParamName> + <LocationRestriction>{x}<0 or {x}>800</LocationRestriction> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.RestrictLocation</Class> + <Args> + <Id>ybounce</Id> + <Action>{val}*-1</Action> + <ParamName>YStep</ParamName> + <LocationRestriction>{y}<0 or {y}>200</LocationRestriction> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>movebounce</Id> + <ChainedBehaviors> + <Id>xymove</Id> + <Id>ybounce</Id> + <Id>xbounce</Id> + </ChainedBehaviors> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>xymover</Id> + <Inputs> + <Id>pygame</Id> + </Inputs> + <ChainedBehaviors> + <Id>colorchange</Id> + <Id>mover</Id> + <Id>decay</Id> + </ChainedBehaviors> + <RecursiveHooks>{'mover':'movebounce'}</RecursiveHooks> + <RenderToScreen>True</RenderToScreen> + <Mapper>gaussmap</Mapper> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.DebugBehavior</Class> + <Args> + <Id>debug</Id> + <z-index>0</z-index> + <Inputs> + <Id>pygame</Id> + </Inputs> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.AllPixelsLeft</Class> + <Args> + <Id>pixelsleft</Id> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.Square</Class> + <Args> + <Id>square</Id> + <Width>20</Width> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.AllPixels</Class> + <Args> + <Id>allpixels</Id> + </Args> + </Behavior> + <Behavior Id="recursivedecay"> + <InheritsFrom>behaviors/LoopAndDie.xml</InheritsFrom> + <Args> + <InitialResponseCount>50</InitialResponseCount> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>runcolordecay</Id> + <Inputs> + <Id>pygame</Id> + </Inputs> + <ChainedBehaviors> + <Id>colorchange</Id> + <Id>running</Id> + <Id>decay</Id> + </ChainedBehaviors> + <RecursiveHooks>{'running':'acceleratedie'}</RecursiveHooks> + <RenderToScreen>False</RenderToScreen> + <Mapper>gaussmap</Mapper> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>randomwalk</Id> + <Inputs> + <Id>pygame</Id> + </Inputs> + <ChainedBehaviors> + <Id>colorchange</Id> + <Id>mover</Id> + <Id>decay</Id> + </ChainedBehaviors> + <RecursiveHooks>{'mover':'redwalk'}</RecursiveHooks> + <RenderToScreen>False</RenderToScreen> + <Mapper>gaussmap</Mapper> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.ResponseMover</Class> + <Args> + <Id>mover</Id> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>redwalk</Id> + <ChainedBehaviors> + <Id>randmovement</Id> + <Id>redshift</Id> + </ChainedBehaviors> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.RandomWalk</Class> + <Args> + <Id>randmovement</Id> + <StepSize>2</StepSize> + </Args> + </Behavior> + <Behavior Id="accelerate"> + <InheritsFrom>behaviors/Accelerate.xml</InheritsFrom> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>acceleratedie</Id> + <ChainedBehaviors> + <Id>accelerate</Id> + <Id>recursivedecay</Id> + </ChainedBehaviors> + </Args> + </Behavior> + <Behavior> + <Class>behaviors.BehaviorChain</Class> + <Args> + <Id>mousechaser</Id> + <Inputs> + <!--Id>followmouse</Id--> + <Id>tcp</Id> + <Id>osc</Id> + </Inputs> + <ChainedBehaviors> + <Id>touchosc</Id> + <Id>square</Id> + <Id>singleframe</Id> + </ChainedBehaviors> + <RenderToScreen>True</RenderToScreen> + </Args> + </Behavior> + <Behavior Id="running"> + <InheritsFrom>behaviors/RunningBehavior.xml</InheritsFrom> + </Behavior> + </BehaviorConfiguration> +</LightInstallation> diff --git a/config/osc.xml b/config/osc.xml new file mode 100644 index 0000000..6efea40 --- /dev/null +++ b/config/osc.xml @@ -0,0 +1,10 @@ + <InputElement> + <Class>inputs.OSCInput</Class> + <Args> + <Id>osc</Id> + <Port>1234</Port> + </Args> + </InputElement> + <Behavior Id="mrmrcolor"> + <Class>behaviors.MrmrSetColor</Class> + </Behavior> |