ImageMagicK에서 이미지 용량 줄이는 방법이 있을까요?

longdarihany의 이미지

jpg이미지 파일을 ImageMagicK에서 용량 줄이는 방법이 있을까요?
이미지의 가로, 세로 사이즈는 그대로여야 하고, 이미지 색상이 원본과 많이 차이가 있어도 상관이 없습니다. 무조건 이미지의 용량을 자동으로 줄여야 합니다.
ImageMagicK가 아니여도 상관은 없고, 줄일수 있는 리눅스용 유틸 또는 PHP 함수가 있을까요? 답변 꼭 부탁드립니다...
저도 고수가 되어 어서 도움을 드려야 할텐데, 매번 도움만 청하게 되네요..^^;;

Bini의 이미지

longdarihany wrote:
jpg이미지 파일을 ImageMagicK에서 용량 줄이는 방법이 있을까요?
이미지의 가로, 세로 사이즈는 그대로여야 하고, 이미지 색상이 원본과 많이 차이가 있어도 상관이 없습니다. 무조건 이미지의 용량을 자동으로 줄여야 합니다.
ImageMagicK가 아니여도 상관은 없고, 줄일수 있는 리눅스용 유틸 또는 PHP 함수가 있을까요? 답변 꼭 부탁드립니다...
저도 고수가 되어 어서 도움을 드려야 할텐데, 매번 도움만 청하게 되네요..^^;;

답변이 없어서 참고삼아 뉴스그룹에서 찾아보니 이러글이 있군요...
제가 ImageMagick의 동작에 대해서 전혀모르기 때문에 이게 맞는건지는 모르겠네요...
아니면 comp.graphics에서 찾아보시면 도움이 될것 같읍니다...

..... wrote:

Peter Didenko <kip@zenon.net> wrote in message news:<abtk04$1ga6$1@news.aha.ru>...
> Hello,
>
> I'm trying to create previews for my images using ImageMagick:
>
> > ls -la DSCN4554*
> -rw-r--r-- 1 40894 112 282896 22 Apr 11:47 DSCN4554.JPG
> -rw-rw-r-- 1 40894 112 41416 22 Apr 11:59 DSCN4554_prev.JPG
>
> But 41416 bytes is too big size for image with 150x100 resolution.
> In case if I'm trying to use GIF format for previews, image will be approx.
> 20Kb, but it's too big too. So, can you please explain me how to optimize my
> previews? Thank you!

Your file probably has an Exif profile and maybe a thumbnail embedded in
it. ImageMagick will preserve these unless you remove them explicitly
with the "+profile '*'" option.

You can also use a lower "quality" than the default value of 75 to get
higher compression at the expense of image appearance.

e.g.

convert -quality 50 +profile '*' DSCN4544.JPG DCSN4554_prev.JPG

Glenn

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.