| >> HOME >> FC5 MENU >> Web上で画像を編集 (ImageMagick) |
 |
|
|
|
|
|
|
|
|
|
|
| |
|
|
| |
[root@linux ~]# yum -y install ImageMagick
Loading "installonlyn" plugin
Setting up Install Process
Setting up repositories
core [1/3]
updates [2/3]
extras [3/3]
Reading repository metadata in from local files
Parsing package install arguments
Resolving Dependencies
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for ImageMagick to pack into transaction set.
ImageMagick-6.2.5.4-4.2.1 100% |=========================| 72 kB 00:00
---> Package ImageMagick.i386 0:6.2.5.4-4.2.1.fc5.3 set to be updated
--> Running transaction check
--> Processing Dependency: libgs.so.8 for package: ImageMagick
--> Processing Dependency: libwmflite-0.2.so.7 for package: ImageMagick
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for ghostscript to pack into transaction set.
ghostscript-8.15.2-1.1.i3 100% |=========================| 140 kB 00:00
---> Package ghostscript.i386 0:8.15.2-1.1 set to be updated
---> Downloading header for libwmf to pack into transaction set.
libwmf-0.2.8.4-4.2.i386.r 100% |=========================| 10 kB 00:00
---> Package libwmf.i386 0:0.2.8.4-4.2 set to be updated
--> Running transaction check
--> Processing Dependency: urw-fonts >= 1.1 for package: ghostscript
--> Processing Dependency: ghostscript-fonts for package: ghostscript
--> Processing Dependency: libcups.so.2 for package: ghostscript
--> Processing Dependency: libcupsimage.so.2 for package: ghostscript
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for urw-fonts to pack into transaction set.
urw-fonts-2.3-6.1.noarch. 100% |=========================| 18 kB 00:00
---> Package urw-fonts.noarch 0:2.3-6.1 set to be updated
---> Downloading header for ghostscript-fonts to pack into transaction set.
ghostscript-fonts-5.50-13 100% |=========================| 10 kB 00:00
---> Package ghostscript-fonts.noarch 0:5.50-13.1 set to be updated
---> Downloading header for cups-libs to pack into transaction set.
cups-libs-1.2.1-1.7.i386. 100% |=========================| 31 kB 00:00
---> Package cups-libs.i386 1:1.2.1-1.7 set to be updated
--> Running transaction check
--> Processing Dependency: libgnutls.so.12 for package: cups-libs
--> Processing Dependency: libgnutls.so.12(GNUTLS_1_2) for package: cups-libs
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for gnutls to pack into transaction set.
gnutls-1.2.10-1.i386.rpm 100% |=========================| 5.6 kB 00:00
---> Package gnutls.i386 0:1.2.10-1 set to be updated
--> Running transaction check
Dependencies Resolved
=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
ImageMagick i386 6.2.5.4-4.2.1.fc5.3 updates 3.1 M
Installing for dependencies:
cups-libs i386 1:1.2.1-1.7 updates 172 k
ghostscript i386 8.15.2-1.1 updates 8.6 M
ghostscript-fonts noarch 5.50-13.1 core 800 k
gnutls i386 1.2.10-1 core 332 k
libwmf i386 0.2.8.4-4.2 core 822 k
urw-fonts noarch 2.3-6.1 core 4.5 M
Transaction Summary
=============================================================================
Install 7 Package(s)
Update 0 Package(s)
Remove 0 Package(s)
Total download size: 18 M
Downloading Packages:
(1/7): gnutls-1.2.10-1.i3 100% |=========================| 332 kB 00:01
(2/7): ghostscript-8.15.2 100% |=========================| 8.6 MB 00:30
(3/7): urw-fonts-2.3-6.1. 100% |=========================| 4.5 MB 00:17
(4/7): libwmf-0.2.8.4-4.2 100% |=========================| 822 kB 00:02
(5/7): ghostscript-fonts- 100% |=========================| 800 kB 00:02
(6/7): cups-libs-1.2.1-1. 100% |=========================| 172 kB 00:00
(7/7): ImageMagick-6.2.5. 100% |=========================| 3.1 MB 00:11
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: ghostscript-fonts ######################### [1/7]
Installing: libwmf ######################### [2/7]
Installing: urw-fonts ######################### [3/7]
Installing: gnutls ######################### [4/7]
Installing: cups-libs ######################### [5/7]
Installing: ghostscript ######################### [6/7]
Installing: ImageMagick ######################### [7/7]
Installed: ImageMagick.i386 0:6.2.5.4-4.2.1.fc5.3
Dependency Installed: cups-libs.i386 1:1.2.1-1.7 ghostscript.i386 0:8.15.2-1.1 ghostscript-fonts.noarch
0:5.50-13.1 gnutls.i386 0:1.2.10-1 libwmf.i386 0:0.2.8.4-4.2 urw-fonts.noarch 0:2.3-6.1
Complete!
|
|
|
| |
|
|
| |
|
|
| |
[root@linux ~]# yum -y install ImageMagick-perl 
|
|
|
|
|
|
| |
|
|
| |
|
|
| |
|
|
| |
|
|
| |
[root@linux ~]# convert abc.jpg abc.png 
|
|
|
| |
|
|
| |
|
|
| |
[root@linux ~]# convert -geometry 320x240 abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -geometry 50%x50% abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -geometry 50% abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
|
|
| |
[root@linux ~]# convert -rotate 90 abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -flip abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -flop abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
|
|
| |
[root@linux ~]# convert -border 10x10 -bordercolor blue abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -median 10 abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -blur 10 abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -edge 10 abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -emboss 10 abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# convert -sample 10% abc.org.jpg abc.jpg 
|
|
|
| |
|
|
| |
[root@linux ~]# identify -verbose abc.png 
|
|
|
|
|
|
| |
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$i = Image::Magick->new;
$i->Read('abc.jpg');
print "Content-type: image/png\n\n";
binmode(STDOUT);
$i->Write("png:-");
exit;
|
|
|
| |
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$newwidth = 320;
$newheight = 240;
$i = Image::Magick->new;
$i->Read('abc.jpg');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$newwidth = 120;
$i = Image::Magick->new;
$i->Read('abc.jpg');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$i = Image::Magick->new;
$i->Read('abc.jpg');
$i->Set(bordercolor=>'#FFFFFF');
$i->Trim();
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$newwidth = 120;
$i = Image::Magick->new;
$i->Read('abc.gif');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$i = Image::Magick->new;
$i->Read('abc.gif');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$i = Image::Magick->new;
$i->Read('abc.gif');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$i = Image::Magick->new;
$i->Read('Sample');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$newwidth = 120;
$i = Image::Magick->new;
$i->Read('Sample.gif');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$newwidth = 120;
$i = Image::Magick->new;
$i->Read('Sample.gif');
print "Content-type: image/gif\n\n";
binmode(STDOUT);
$i->Write("jpeg:-");
exit;
|
|
|
| |
|
|
| |
#!/usr/local/bin/perl
use Image::Magick;
$i = Image::Magick->new;
$i->Read('Sample.gif');
print "Content-type: text/html\n\n";
print "横幅 = $pic_width\n";
print "縦幅 = $pic_height\n";
exit;
|
|
|
 |
|
 |
 |