Mercurial > libervia-backend
diff sat/bridge/bridge_constructor/bridge_template.ini @ 3259:f300d78f08f3
core: image convertion + SVG support:
/!\ new optional dependency: CairoSVG (with installed `[SVG]` extra)
- new `convert` method in `tools.image` to save an image in an other format, with support
for SVG (when CairoSVG is available)
- new `imageConvert` method is available for frontends
author | Goffi <goffi@goffi.org> |
---|---|
date | Sun, 19 Apr 2020 16:53:44 +0200 |
parents | 6cf4bd6972c2 |
children | 524856bd7b19 |
line wrap: on
line diff
--- a/sat/bridge/bridge_constructor/bridge_template.ini Sun Apr 19 16:40:34 2020 +0200 +++ b/sat/bridge/bridge_constructor/bridge_template.ini Sun Apr 19 16:53:44 2020 +0200 @@ -1009,3 +1009,18 @@ doc_param_0=image_path: path of the original image doc_param_1=%(doc_profile_key)s doc_return=path to the preview in cache + +[imageConvert] +async= +type=method +category=core +sig_in=ssss +sig_out=s +doc=Convert an image to an other format +doc_param_0=source: path of the image to convert +doc_param_1=dest: path to the location where the new image must be stored. + Empty string to generate a file in cache, unique to the source +doc_param_3=extra: serialised extra +doc_param_4=profile_key: either profile_key or empty string to use common cache + this parameter is used only when dest is empty +doc_return=path to the new converted image