comparison convert.xml @ 0:3d3e4a1bd21e draft

planemo upload for repository https://github.com/bgruening/galaxytools/new/gm/tools/image_processing/image_processing/ commit dd88ad4ff9d10d72ed60263da31b406074173853
author bgruening
date Wed, 10 Oct 2018 16:17:02 -0400
parents
children e88f1111d9e7
comparison
equal deleted inserted replaced
-1:000000000000 0:3d3e4a1bd21e
1 <tool id="graphicsmagick_image_convert" name="Image Converter" version="@VERSION@">
2 <description></description>
3 <macros>
4 <import>macros.xml</import>
5 </macros>
6 <expand macro="requirements" />
7 <command detect_errors="aggressive">
8 <![CDATA[
9 ln -s '${input}' input.${input.ext}
10 &&
11 #set $trans_options = str($transformations).replace(',', ' ')
12
13 convert $trans_options input.${input.ext} temp.${output_format}
14 &&
15 mv temp.${output_format} '${output}'
16 ]]>
17 </command>
18 <inputs>
19 <param format="jpg,png,bmp,gif,svg,eps,tiff,xcf" name="input" type="data" label="Image to convert" />
20 <param name="transformations" multiple="true" type="select" display="checkboxes" label="Transformations">
21 <option value="-flip">flip vertically</option>
22 <option value="-flop">flip horizontally</option>
23 <option value="-rotate 90">rotate 90 degree to the right</option>
24 <option value="-rotate 270">rotate 90 degree to the left</option>
25 <option value="-rotate 180">rotate 180 degree</option>
26 </param>
27 <param name="output_format" type="select" label="Output Format">
28 <option value="jpeg">jpg</option>
29 <option value="png">png</option>
30 <option value="bmp">bmp</option>
31 <option value="gif">gif</option>
32 <option value="svg">svg</option>
33 <option value="eps">eps</option>
34 <option value="tiff">tiff</option>
35 </param>
36 </inputs>
37 <outputs>
38 <data format="png" name="output">
39 <change_format>
40 <when input="output_format" value="jpeg" format="jpg" />
41 <when input="output_format" value="png" format="png" />
42 <when input="output_format" value="bmp" format="bmp" />
43 <when input="output_format" value="gif" format="gif" />
44 <when input="output_format" value="svg" format="svg" />
45 <when input="output_format" value="eps" format="eps" />
46 <when input="output_format" value="tiff" format="tiff" />
47 </change_format>
48 </data>
49 </outputs>
50 <tests>
51 <test>
52 <param name="input" value="donald.jpg" />
53 <param name="output_format" value="png" />
54 <param name="transformations" value="-flip" />
55 <output name="output" file="result_image_convert_1.png" compare="sim_size" delta="20000" />
56 </test>
57 </tests>
58 <help>
59 <![CDATA[
60
61 **What it does**
62
63 This tool converts an image into another format. You can also do some transformations like flipping or rotating.
64 Here you can see, how -flip behaves:
65
66 Input:
67
68 .. image:: $PATH_TO_IMAGES/donald.jpg
69
70 Output:
71
72 .. image:: $PATH_TO_IMAGES/donald.png
73
74 ]]>
75 </help>
76 <expand macro="citations" />
77 </tool>