File: make_server_icons.sh

package info (click to toggle)
gerbera 1.1.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster
  • size: 4,684 kB
  • sloc: cpp: 29,611; xml: 967; ansic: 463; perl: 328; sh: 316; sql: 135; python: 75; makefile: 11; fortran: 9
file content (20 lines) | stat: -rwxr-xr-x 958 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/bash

# run as
# make_icons-mediatomb.sh mylogo.jpg
# Will generate all the required mediatomb icons

src="${1}"


convert "${src}" -filter Lanczos -resize x32 -background black -flatten bmp:"mt-icon32.bmp"
convert "${src}" -filter Lanczos -resize x32 -background black -flatten png:"mt-icon32.png"
convert "${src}" -filter Lanczos -resize x32 -background black -flatten jpg:"mt-icon32.jpg"

convert "${src}" -filter Lanczos -resize x48 -background black -flatten bmp:"mt-icon48.bmp"
convert "${src}" -filter Lanczos -resize x48 -background black -flatten png:"mt-icon48.png"
convert "${src}" -filter Lanczos -resize x48 -background black -flatten jpg:"mt-icon48.jpg"

convert "${src}" -filter Lanczos -resize x120 -background black -flatten bmp:"mt-icon120.bmp"
convert "${src}" -filter Lanczos -resize x120 -background black -flatten png:"mt-icon120.png"
convert "${src}" -filter Lanczos -resize x120 -background black -flatten jpg:"mt-icon120.jpg"