public SymmetricSpectrum(IEffectApi api, int width, int height) : base(width, height) { _api = api; _color = new SKColor(0, 255, 128); _render = _api.CreateRender(); _featureCache = _api.CreateAudioFeatureCache(); }
public ValueBar(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _color = new SKColor(0, 128, 128); _render = _api.CreateRender(); _barValue = 0; }
public Stroboscope(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _color = new SKColor(0, 0, 0); _render = _api.CreateRender(); _flashDuration = MaxFlashDuration; }
public ColorWheel(IEffectApi api, int width, int height) : base(width, height) { _api = api; _render = _api.CreateRender(); _speed = 25; _offset = 0; _scale = 1; }
public Bar(IEffectApi api, int width, int height) : base(width, height) { _api = api; _color = new SKColor(0, 255, 128); _render = _api.CreateRender(); _xCenterPos = Width / 2f; _xSize = Width / 2f; }
public SymmetricBeatBars(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _color = new SKColor(0, 128, 128); _render = _api.CreateRender(); _featureCache = _api.CreateAudioFeatureCache(); _remainingBeatTime = 0; }
public static void RegisterEffectSystems <TSystem, TRenderer, TComponent1>(this IEffectApi @this, Affects affects) where TSystem : IEffectSystem, new() where TRenderer : IEffectRenderer, new() { var system = new TSystem(); var renderer = new TRenderer(); @this.RegisterEffect <TComponent1>(system, renderer, affects); }
public Blob(IEffectApi api, int width, int height) : base(width, height) { _api = api; _color = new SKColor(0, 255, 128); _render = _api.CreateRender(); _x0Pos = Width / 2f; _y0Pos = Height / 2f; _size = Width / 2f; }
public Beams(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _render = _api.CreateRender(); _particleSystem = _api.CreateParticleSystem(); _color = new SKColor(0, 128, 128); _particleSpeed = 5; _particleSize = 4; }
public ChromaBars(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _color = new SKColor(0, 128, 128); _render = _api.CreateRender(); _featureCache = _api.CreateAudioFeatureCache(); _threshold = 0.0f; _barSize = (int)(width / NumBars); }
public ColorWheel(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _color = new SKColor(0, 128, 128); _render = _api.CreateRender(); _speed = 25; _offset = 0; _scale = 1; }
public ZoomingBlobs(IEffectApi api, int width, int height) : base(width, height) { _api = api; _render = _api.CreateRender(); _maxBlobLife = 0.5f; _maxBlobSize = width / 8f; _rand = new Random(); _blobs = new List <BlobItem>(); }
public FixedChladni(IEffectApi api, int width, int height) : base(width, height) { _api = api; _color = new SKColor(0, 255, 128); _render = _api.CreateRender(); _n = 1; _m = 1; _a = 1; _b = 1; }
public BouncingBlob(IEffectApi api, int width, int height) : base(width, height) { _api = api; _color = new SKColor(0, 255, 128); _render = _api.CreateRender(); _xCenterPos = width / 2f; _size = width / 4f; _speed = width / 8f; _direction = 1; }
/* This constructor will be called when a layer of your effect is being created. */ public Color(IEffectApi api, int width, int height) : base(width, height) { /* Save the effect helper in your class, you will need it. */ _api = api; /* Set the default color. */ _color = new SKColor(0, 255, 128); /* Create a render for your effect using the effect helper. */ _render = _api.CreateRender(); }
public WalkingBlobs(IEffectApi api, int width, int height) : base(width, height) { _api = api; _render = _api.CreateRender(); _blobs = new List <WalkingBlob>(); _blobSize = width / 16f; _blobSpeed = width / 2; _blobWalkTime = 0.375f; _blobColor = new SKColor(0, 255, 128); }
public CirclingEllipticalPlasma(IEffectApi api, int width, int height) : base(width, height) { _api = api; _render = _api.CreateRender(); _cr = 0.0f; _cg = 0.5f; _cb = 1.0f; _xScale = 1.0f; _yScale = 1.0f; }
/* This constructor will be called when a layer of your effect is being created. */ public BeatColor(IEffectApi effectApi, int width, int height) : base(width, height) { /* Save the effect api in your class, you will need it. */ _api = effectApi; _featureCache = _api.CreateAudioFeatureCache(); /* Set the default color. */ _color = new SKColor(0, 128, 128); /* Create a render for your effect using the effect api. */ _render = _api.CreateRender(); }
public DirectionalPlasma(IEffectApi api, int width, int height) : base(width, height) { _api = api; _render = _api.CreateRender(); _cr = 0.0f; _cg = 0.5f; _cb = 1.0f; _scale = 1.0f; _angle = 0.0f; UpdateDirection(); }
/* This constructor will be called when a layer of your effect is being created. */ public Wave1D(IEffectApi api, int width, int height) : base(width, height) { /* Save the effect helper in your class, you will need it. */ _api = api; /* Create a render for your effect using the effect helper. */ _render = _api.CreateRender(); /* Create a wave simulation using the effect helper. */ _waveSimulation = _api.CreateWaveSimulation1D(); /* Lets double the wave speeds */ _waveSimulation.Speed = 2.0; }
public Sparkles(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; // Create a render for this effect instance once. _render = _api.CreateRender(); // Create a particle system _particleSystem = _api.CreateParticleSystem(); _color = new SKColor(0, 128, 128); _numParticles = 3 * Width / 4; _particleSize = 1; }
/* This constructor will be called when a layer of your effect is being created. */ public BeatWave1D(IEffectApi effectApi, int width, int height) : base(width, height) { /* Save the effect api in your class, you will need it. */ _api = effectApi; _featureCache = _api.CreateAudioFeatureCache(); /* Create a render for your effect using the effect api. */ _render = _api.CreateRender(); /* Create a wave simulation using the effect api. */ _waveSimulation = _api.CreateWaveSimulation1D(); /* Lets double the wave speeds */ _waveSimulation.Speed = 2.0; }
public SparkleExplosion(IEffectApi api, int width, int height) : base(width, height) { _api = api; // Create a render for this effect instance once. _render = _api.CreateRender(); // Create a particle system _particleSystem = _api.CreateParticleSystem(); _random = new Random(); _color = new SKColor(0, 255, 128); _numParticles = Width * Height * 0.25f; _particleSize = 2; }
public FadingBars(IEffectApi api, int width, int height) : base(width, height) { _api = api; _color = new SKColor(0, 255, 128); _render = _api.CreateRender(); _maxNumBars = Math.Min((int)(width / 2), 12); _numBars = 4; _maxBarLife = 1.0f; _barSize = (int)(width / _numBars); _lastBar = -1; _rand = new Random(); InitBars(); }
/* This constructor will be called when a layer of your effect is being created. */ public Wave1D(IEffectApi effectApi, int width, int height) : base(width, height) { /* Save the effect api in your class, you will need it. */ _api = effectApi; /* Set the default color. */ _color = new SKColor(0, 128, 128); /* Create a render for your effect using the effect api. */ _render = _api.CreateRender(); /* Create a wave simulation using the effect api. */ _waveSimulation = _api.CreateWaveSimulation1D(); /* Lets double the wave speeds */ _waveSimulation.Speed = 2.0; }
public Blob(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _color = new SKColor(0, 128, 128); _render = _api.CreateRender(); _x0Pos = Width / 2; _y0Pos = Height / 2; if (Width >= Height && Height > 1) { _ySize = Height / 2; _xSize = _ySize; } else { _xSize = Width / 2; _ySize = _xSize; } }
public Fire(IEffectApi effectApi, int width, int height) : base(width, height) { _api = effectApi; _render = _api.CreateRender(); _particleSystem = _api.CreateParticleSystem(); _beginColor = new SKColor(128, 64, 16); var endColor = new SKColor(64, 64, 64); _particleEmitters = new List <IParticleEmitter>(); int numEmbers = Math.Max((int)(Width / EmberDistance), 1); for (int i = 0; i < numEmbers; i++) { var xPos = Width / (numEmbers - 1f) * i; var yPos = Height; var emitterConfig = new ParticleEmitterConfig { Position = new Vector2(xPos, yPos), AxisPosition = new Vector2(xPos, yPos), EmissionRate = 8, Angle = new Range <float>(45, 135), Life = 4, Speed = 4, RadialAcceleration = 0, TangentialAcceleration = 0, BeginColor = _beginColor, EndColor = endColor, BeginSize = 4, EndSize = 4, EnableSizeTransition = true, EnableColorTransition = true, }; var emitter = _particleSystem.AddEmitter(emitterConfig); _particleEmitters.Add(emitter); } }
public FluidApi(IEffectApi effectApi) { this.effectApi = effectApi; }
public static void RegisterEffect <TComponent1, TComponent2, TComponent3>(this IEffectApi @this, Affects affects) { @this.RegisterEffect <TComponent1>(affects); @this.RegisterEffect <TComponent2>(affects); @this.RegisterEffect <TComponent3>(affects); }
public static void RegisterEffect <TComponent1, TComponent2>(this IEffectApi @this, IEffectSystem system, IEffectRenderer renderer, Affects affects) { @this.RegisterEffect <TComponent1>(system, renderer, affects); @this.RegisterEffect <TComponent2>(affects); }