Apply scripted modifications on an online image
i : image's URL
script : an object in json format. It contains the action as key and the parameters as value.
- [{"grey":""}] : filter grayscale
- [{"pixel":(size,blur])}] : filter pixelate
- [{"emboss":""}] : filter emboss
- [{"edges":""}] : filter edgedetect
- [{"negative":""}] : filter negate
- [{"sketch":""}] : filter mean removal
- [{"gaussian":""}] : filter gaussian blur
- [{"brightness":amount}] : filter brightness
- [{"contrast":amount}] : filter contrast
- [{"colorize":[FF0000,1-127]}] : filter colorize [color,alpha]
- [{"crop":[x,y,w,h]}] : crop image (dimensions in pixels or in %)
- [{"resize":[w,h]}] : resize image. if you put -1 instead of one dimension,it resizes with aspect ratio. {"resize":[256,-1]} calculates the new height
- [{"rotate":angle}] : rotate image
You can chain various actions in one script: [{"resize":[w,h]},{"colorize":["FF0000",1]},{"rotate":90}]
script can also be a json file in scripts/ folder
- create a file with your script (ex: {"resize":[w,h],"colorize":["FF0000",1],"rotate":90})
- name your file: myscript.json
- apply it to a picture with ?i=http://www.server.com/picture.jpg&script=myscript (without the json extension)
dontsave: avoid saving rendered picture
force: force the rendering even if the picture already exists (previous rendering)
help: displays this text
version: displays this api's version
picslist: returns the rendered images list in json format
- &random[=xx]: limit the list getting only xx rendered pictures
download: downloads the php api file