0.3.0 • Published 2 years ago
@donkeyclip/motorcortex-tv v0.3.0
MotorCortex-Tv
Table of Contents
- MotorCortex-Tv
- Intro / Features
- Getting Started
- Creating Incidents
- Adding Incidents in your clip
- Contributing
- License
- Sponsored by
Demo
Intro / Features
Using MotorCortex-Τv your clip will look like a TV without signal.
This Plugin exposes two incidents:
- TVNoise
- ImageGlitch
Getting Started
Installation
$ npm install --save @donkeyclip/motorcortex-tv
# OR
$ yarn add @donkeyclip/motorcortex-tv
Importing and Loading
import { loadPlugin } from "@donkeyclip/motorcortex";
import tvDefinition from "@donkeyclip/motorcortex-abstracts";
const Plugin = loadPlugin(tvDefinition);
Creating Incidents
TVNoise
const tvNoise = new TVPlugin.TVNoise(
{
width: 800,
height: 600,
sound: true,
},
{
duration: 6000,
selector: "#container",
}
);
TVNoise Attrs
Name | Are | Values |
---|---|---|
width | width of the canvas | num |
height | height of the canvas | num |
duration | the duration of the effect | num |
sound | iclude noise sound or not | bool |
imageGlitch
const imageGlitch = new TVPlugin.ImageGlitch(
{
imgUrl:
"https://images.hdqwalls.com/wallpapers/minimal-sunset-landscape-4k-w5.jpg",
},
{
selector: "#glitchContainer",
containerParams: {
width: "800px",
height: "600px",
},
}
);
ImageGlitch Attrs
Name | Are | Values |
---|---|---|
imgUrl | the image url to apply the effect on | url |
Adding Incidents in your clip
clipName.addIncident(incidentName,startTime);
Contributing
In general, we follow the "fork-and-pull" Git workflow, so if you want to submit patches and additions you should follow the next steps: 1. Fork the repo on GitHub 2. Clone the project to your own machine 3. Commit changes to your own branch 4. Push your work back up to your fork 5. Submit a Pull request so that we can review your changes