2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

[iOS] iOSアプリのアプリアイコンのリサイズを一度に行う

Last updated at Posted at 2018-03-03

#[iOS] iOSアプリのアプリアイコンのリサイズを一度に行う
Mac OSX で、ImageMagickというツールを利用し、
コマンドで一度に画像のリサイズを行う方法です。

ImageMagickのダウンロードは以下から
https://www.imagemagick.org/script/download.php#macosx

以下でインストール

cd $HOME
tar xvzf ImageMagick-x86_64-apple-darwin17.2.0.tar.gz

必要なコマンドを書いたシェルスクリプト

iosappiconcreate.sh
export MAGICK_HOME="$HOME/ImageMagick-7.0.7"
export PATH="$MAGICK_HOME/bin:$PATH"
export DYLD_LIBRARY_PATH="$MAGICK_HOME/lib"

mkdir iosappicon

magick $1 -resize 40x40 iosappicon/iPhone20pt2x_40px.png
magick $1 -resize 60x60 iosappicon/iPhone20pt3x_60px.png
magick $1 -resize 58x58 iosappicon/iPhone29pt2x_58px.png
magick $1 -resize 87x87 iosappicon/iPhone29pt3x_87px.png
magick $1 -resize 80x80 iosappicon/iPhone40pt2x_80px.png
magick $1 -resize 120x120 iosappicon/iPhone40pt3x_120px.png
magick $1 -resize 120x120 iosappicon/iPhone60pt2x_120px.png
magick $1 -resize 180x180 iosappicon/iPhone60pt3x_180px.png
magick $1 -resize 20x20 iosappicon/iPad20pt1x_20px.png
magick $1 -resize 40x40 iosappicon/iPad20pt2x_40px.png
magick $1 -resize 29x29 iosappicon/iPad29pt1x_87px.png
magick $1 -resize 58x58 iosappicon/iPad29pt2x_58px.png
magick $1 -resize 40x40 iosappicon/iPad40pt1x_40px.png
magick $1 -resize 80x80 iosappicon/iPad40pt2x_80px.png
magick $1 -resize 76x76 iosappicon/iPad76pt1x_76px.png
magick $1 -resize 152x152 iosappicon/iPad76pt2x_152px.png
magick $1 -resize 167x167 iosappicon/iPadPro83_5pt2x_167px.png
magick $1 -resize 1024x1024 iosappicon/AppStore1024pt_1024px.png

以下で実行

iosappiconcreate.sh xxx.png(元になる画像)
2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?