mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-14 12:19:58 +01:00
Modified Modules Folder Structure
This commit is contained in:
32
src/modules/DoNothingPix/Module.js
Normal file
32
src/modules/DoNothingPix/Module.js
Normal file
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* This module extracts pixels and saves them as it is.
|
||||
*/
|
||||
module.exports = function DoNothingPix(options) {
|
||||
|
||||
options = options || {};
|
||||
options.title = "Do Nothing with pixels";
|
||||
var output;
|
||||
|
||||
function draw(input,callback) {
|
||||
this_ = this;
|
||||
function changePixel(r, g, b, a) {
|
||||
return [r, g, b, a];
|
||||
}
|
||||
function output(image,datauri,mimetype){
|
||||
this_.output = {src:datauri,format:mimetype}
|
||||
}
|
||||
return require('../_nomodule/PixelManipulation.js')(input, {
|
||||
output: output,
|
||||
changePixel: changePixel,
|
||||
format: input.format,
|
||||
image: options.image,
|
||||
callback: callback
|
||||
});
|
||||
}
|
||||
|
||||
return {
|
||||
options: options,
|
||||
draw: draw,
|
||||
output: output
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user