mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-15 04:40:02 +01:00
Fix import image (#282)
* fix default image path Signed-off-by: tech4GT <varun.gupta1798@gmail.com> * fix importImage to take proper input Signed-off-by: tech4GT <varun.gupta1798@gmail.com>
This commit is contained in:
committed by
Jeffrey Warren
parent
37122d4c28
commit
2b07ecdb36
23509
dist/image-sequencer.js
vendored
23509
dist/image-sequencer.js
vendored
File diff suppressed because one or more lines are too long
2
dist/image-sequencer.min.js
vendored
2
dist/image-sequencer.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -9,7 +9,7 @@
|
|||||||
module.exports = function ImportImageModule(options, UI) {
|
module.exports = function ImportImageModule(options, UI) {
|
||||||
|
|
||||||
options = options || {};
|
options = options || {};
|
||||||
options.imageUrl = options.imageUrl || "/examples/images/monarch.png";
|
options.imageUrl = options.url || "/examples/images/monarch.png";
|
||||||
|
|
||||||
var output,
|
var output,
|
||||||
imgObj = new Image();
|
imgObj = new Image();
|
||||||
|
|||||||
@@ -30,7 +30,9 @@ module.exports = function ImportImageModuleUi(step, ui) {
|
|||||||
onLoad: function onLoadFromInput(progress) {
|
onLoad: function onLoadFromInput(progress) {
|
||||||
var reader = progress.target;
|
var reader = progress.target;
|
||||||
step.options.imageUrl = reader.result;
|
step.options.imageUrl = reader.result;
|
||||||
|
step.options.url = reader.result;
|
||||||
sequencer.run();
|
sequencer.run();
|
||||||
|
setUrlHashParameter("steps", sequencer.toString());
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
"url": {
|
"url": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"desc": "URL of image to import",
|
"desc": "URL of image to import",
|
||||||
"default": "/examples/images/monarch.png"
|
"default": "./images/monarch.png"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user