mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-06 00:10:01 +01:00
Added documentation for Crop and SegmentedColormap Modules
This commit is contained in:
BIN
docs/CropManual.png
Normal file
BIN
docs/CropManual.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 24 KiB |
49
docs/MODULES.md
Normal file
49
docs/MODULES.md
Normal file
@@ -0,0 +1,49 @@
|
||||
Documentation of various Modules
|
||||
===
|
||||
|
||||
## Crop Module (crop)
|
||||
|
||||
This module is used to crop an image.
|
||||
|
||||
#### Usage
|
||||
|
||||
```js
|
||||
sequencer.loadImage('PATH')
|
||||
.addSteps('crop',options)
|
||||
.run();
|
||||
```
|
||||
Where `options` is an object having the properties `x`, `y`, `w`, `h`. This diagram defines these properties:
|
||||
|
||||

|
||||
|
||||
#### Defaults
|
||||
|
||||
* `options.x` : 0
|
||||
* `options.y` : 0
|
||||
* `options.w` : half of image width
|
||||
* `options.h` : half of image height
|
||||
|
||||
|
||||
## Segmented Colormap Module (segmented-colormap)
|
||||
|
||||
This module is used to map the pixels of the image to a segmented colormap.
|
||||
|
||||
#### Usage
|
||||
|
||||
```js
|
||||
sequencer.loadImage('PATH')
|
||||
.addSteps('segmented-colormap',options)
|
||||
.run()
|
||||
```
|
||||
|
||||
where `options` is an object with the property `colormap`. `options.colormap` can be:
|
||||
|
||||
* "default" : [[0, [0, 0, 255], [38, 195, 195]], [0.5, [0, 150, 0], [255, 255, 0]], [0.75, [255, 255, 0], [255, 50, 50]]]
|
||||
|
||||
* "greyscale" : [[0, [0, 0, 0], [255, 255, 255]], [1, [255, 255, 255], [255, 255, 255]]]
|
||||
|
||||
* "stretched" : [[0, [0, 0, 255], [0, 0, 255]], [0.1, [0, 0, 255], [38, 195, 195]], [0.5, [0, 150, 0], [255, 255, 0]], [0.7, [255, 255, 0], [255, 50, 50]], [0.9, [255, 50, 50], [255, 50, 50]]]
|
||||
|
||||
* "fastie" : [[0, [255, 255, 255], [0, 0, 0]], [0.167, [0, 0, 0], [255, 255, 255]], [0.33, [255, 255, 255], [0, 0, 0]], [0.5, [0, 0, 0], [140, 140, 255]], [0.55, [140, 140, 255], [0, 255, 0]], [0.63, [0, 255, 0], [255, 255, 0]], [0.75, [255, 255, 0], [255, 0, 0]], [0.95, [255, 0, 0], [255, 0, 255]]]
|
||||
|
||||
* A custom array.
|
||||
Reference in New Issue
Block a user