Skip to content
Chinmay Pandhare edited this page May 30, 2017 · 3 revisions

Image Sequencer

  1. One Sequencer instance must be capable of handling multiple images
  2. Images should have a Unique ID
  3. GPU Acceleration where applicable
  4. Modules need to be implemented

Functionality

  1. addStep, removeStep, insertStep should support JSON type I/O.

./src/ImageSequencer.js

This module is responsible for defining all the core functions of the library : addStep/addSteps, removeStep/removeSteps, insertStep/insertSteps, run. It Contains the Function ImageSequencer which is responsible for initiating a sequencer when it is run, like: sequencer = ImageSequencer();. sequencer is initialized as:

sequencer = {
  options: [Object],
  loadImage: [Function],
  images: [Object],
  modules: [Object],
  ui: [Object],
  addStep: [Function],
  removeStep: [Function],
  insertStep: [Function],
  run: [Function]
}
  1. options: Contains preferences/settings for the functioning of the Image Sequencer. Also contains the image URLs inputted by the user.
options = {
  inBrowser: [Bool], //stores if the user is a browser

}
  1. addStep/addSteps: adds step/s.
    1. accepted parameters : either an image module-name pair or a JSON of multiple images with one or more modules each. The image name may be omitted if there is only one image. the 'addStep' and 'addSteps' would be a single function. the extra 's' is just for aesthetics.
      • addStep('module-1')
      • addSteps(['module-1', 'module-2', ...])
      • addStep('image1','module-1')
      • addSteps('image1',['module-1', 'module-2', ...])
      • addSteps({image1: 'module-1', image2: 'module-2', ... })
      • addSteps({image1: ['module-1','module-2'], image2: ['module-3','module-4'], ...})
    2. return value : none.
    3. actions : adds another step to the image sequencer under the specified/default image/s.
Clone this wiki locally