{"id":208025,"date":"2021-01-02T10:15:33","date_gmt":"2021-01-02T02:15:33","guid":{"rendered":"https:\/\/lrxjmw.cn\/?p=208025"},"modified":"2020-12-24T21:16:43","modified_gmt":"2020-12-24T13:16:43","slug":"linux-image","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/linux-image.html","title":{"rendered":"Linux\u7ec8\u7aef\u600e\u4e48\u67e5\u770b\u56fe\u50cf"},"content":{"rendered":"\n\n\n
\u5bfc\u8bfb<\/td>\nLinux \u6709\u5f88\u591a\u7528\u4e8e\u67e5\u770b\u56fe\u50cf\u7684 GUI \u5e94\u7528\u3002\u4f46\u6211\u4ece\u6765\u6ca1\u6709\u5c1d\u8bd5\u8fc7\u7528\u4efb\u4f55\u547d\u4ee4\u884c\u5e94\u7528\u6765\u67e5\u770b\u5b83\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n

\"\"
\n\u5e78\u8fd0\u7684\u662f\uff0c\u5728\u4f7f\u7528 ImageMagick \u5de5\u5177\u65f6\uff0c\u6211\u5f97\u5230\u4e86\u4e00\u4e2a\u4ece\u7ec8\u7aef\u67e5\u770b\u56fe\u50cf\u7684\u547d\u4ee4\u3002\u547d\u4ee4\u540d\u662f \u201cdisplay\uff0c\u5b83\u662f ImageMagick \u5de5\u5177\u7684\u4e00\u90e8\u5206\u3002\u8fd9\u662f\u4e00\u4e2a\u5f88\u597d\u7684\u5de5\u5177\uff0c\u5141\u8bb8\u7c7b UNIX \u7528\u6237\u4ece\u7ec8\u7aef\u67e5\u770b\u56fe\u50cf\u3002<\/p>\n

\u6b64\u5916\uff0c\u6211\u8fd8\u4e3a\u6b64\u7528\u9014\u5f97\u5230\u4e86\u53e6\u4e00\u4e2a\u5f88\u597d\u7684\u5de5\u5177\uff0c\u53eb\u505a FIM\u3002<\/p>\n

\u6211\u4eec\u5c06\u5411\u4f60\u5c55\u793a\u5982\u4f55\u5b89\u88c5\u5e76\u4f7f\u7528\u5b83\u4ece Linux \u7ec8\u7aef\u67e5\u770b\u56fe\u50cf\u3002\u8fd9\u4e9b\u547d\u4ee4\u4f7f\u7528\u7cfb\u7edf\u7684\u5e27\u7f13\u51b2framebuffer\u76f4\u63a5\u4ece\u547d\u4ee4\u884c\u663e\u793a\u56fe\u50cf\u3002<\/p>\n

\u5982\u4f55\u4f7f\u7528 display \u547d\u4ee4\u4ece\u7ec8\u7aef\u67e5\u770b\u56fe\u50cf<\/strong><\/div>\n

ImageMagick \u662f\u4e00\u4e2a\u81ea\u7531\u5f00\u6e90\u3001\u529f\u80fd\u4e30\u5bcc\u3001\u57fa\u4e8e\u547d\u4ee4\u884c\u7684\u56fe\u50cf\u5904\u7406\u5de5\u5177\u3002\u5b83\u7528\u4e8e\u521b\u5efa\u3001\u7f16\u8f91\u3001\u5408\u6210\u6216\u8f6c\u6362\u4f4d\u56fe\u56fe\u50cf\u3002\u5b83\u53ef\u4ee5\u8bfb\u53d6\u548c\u5199\u5165\u5404\u79cd\u683c\u5f0f\uff08\u8d85\u8fc7 200 \u79cd\uff09\u7684\u56fe\u50cf\uff0c\u5305\u62ec PNG\u3001JPEG\u3001GIF\u3001PDF\u3001SVG \u7b49\u3002\u5b83\u53ef\u4ee5\u8c03\u6574\u56fe\u50cf\u7684\u5927\u5c0f\u3001\u955c\u50cf\u3001\u65cb\u8f6c\u3001\u8f6c\u6362\u56fe\u50cf\u3001\u8c03\u6574\u56fe\u50cf\u989c\u8272\u3001\u5e94\u7528\u5404\u79cd\u7279\u6b8a\u6548\u679c\u7b49\u3002\u5b83\u652f\u6301\u6279\u5904\u7406\uff0c\u5141\u8bb8\u4f60\u4e00\u6b21\u5904\u7406\u6240\u6709\u56fe\u50cf\u3002<\/p>\n

\u5982\u4f55\u5b89\u88c5 ImageMagick\uff1f<\/strong><\/div>\n

ImageMagick \u8f6f\u4ef6\u5305\u5305\u542b\u5728\u5927\u591a\u6570 Linux \u53d1\u884c\u7248\u7684\u5b98\u65b9\u4ed3\u5e93\u4e2d\u3002\u4f7f\u7528\u53d1\u884c\u7248\u8f6f\u4ef6\u5305\u7ba1\u7406\u5668\u6765\u5b89\u88c5\u5b83\u3002<\/p>\n

**\u9700\u8981\u6ce8\u610f\u7684\u662f\uff1a**\u786e\u4fdd\u4f60\u7684 Linux \u7cfb\u7edf\u4e0a\u5df2\u7ecf\u5b89\u88c5\u4e86 \u201cDevelopment Tools\u201d \u5305\uff0c\u8fd9\u662f\u5b89\u88c5\u7684\u524d\u63d0\u6761\u4ef6\u3002<\/p>\n

\u5bf9\u4e8e RHEL\/CentOS 6\/7 \u7cfb\u7edf\uff0c\u8bf7\u4f7f\u7528 yum \u547d\u4ee4 \u5b89\u88c5 ImageMagick\uff1a<\/p>\n

 \r\n$ sudo yum install -y ImageMagick ImageMagick-devel\r\n<\/pre>\n

\u5728 RHEL\/CentOS 8 \u548c Fedora \u7cfb\u7edf\uff0c\u4f7f\u7528 dnf \u547d\u4ee4 \u5b89\u88c5 ImageMagick\uff1a<\/p>\n

\r\n$ sudo dnf install -y ImageMagick ImageMagick-devel\r\n<\/pre>\n

\u5bf9\u4e8e Debian\/Ubuntu \u7cfb\u7edf\uff0c\u4f7f\u7528 apt \u547d\u4ee4 \u6216 apt-get \u547d\u4ee4 \u5b89\u88c5 ImageMagick\uff1a<\/p>\n

\r\n$ sudo apt-get update\r\n$ sudo apt-get install imagemagick\r\n<\/pre>\n

\u5bf9\u4e8e openSUSE \u7cfb\u7edf\uff0c\u4f7f\u7528 zypper \u547d\u4ee4 \u5b89\u88c5 ImageMagick\uff1a<\/p>\n

\r\n$ sudo zypper install -y ImageMagick\r\n<\/pre>\n

\u8981\u67e5\u770b\u4efb\u4f55\u56fe\u50cf\u6587\u4ef6\uff0c\u8bf7\u8fd0\u884c display \u547d\u4ee4\uff0c\u5982\u4e0b\u6240\u793a\u3002\u4f60\u53ef\u4ee5\u6309\u4e0b Esc\/q \u6309\u94ae\u5173\u95ed\u56fe\u50cf\uff1a<\/p>\n

\r\n$ display bird.jpg\r\n<\/pre>\n

\"\"
\n\u5982\u679c\u4f60\u60f3\u7528\u6307\u5b9a\u7684\u7a97\u53e3\u5927\u5c0f\u6253\u5f00\u56fe\u50cf\uff0c\u8bf7\u4f7f\u7528 -geometry \u6807\u5fd7\uff1a<\/p>\n

\r\n$ display -geometry 1000x600 ~\/Downloads\/bird.jpg\r\n<\/pre>\n

\u4f60\u4e5f\u53ef\u4ee5\u901a\u8fc7 display \u547d\u4ee4\u8f93\u5165\u56fe\u50cf\u7684\u4f4d\u7f6e\u4fe1\u606f\u3002\u4e0b\u9762\u7684\u547d\u4ee4\u53ef\u4ee5\u4ece\u684c\u9762\u7684\u8ddd\u9876\u90e8 800 \u50cf\u7d20\u548c\u636e\u5de6\u4e0a\u89d2 800 \u50cf\u7d20\u5904\u6253\u5f00\u56fe\u50cf\uff1a<\/p>\n

\r\n$ display -geometry 1000x600+800+800 ~\/Downloads\/bird.jpg\r\n<\/pre>\n

\u5982\u679c\u4f60\u60f3\u7528 display \u547d\u4ee4\u8c03\u6574\u56fe\u50cf\u7684\u5927\u5c0f\uff0c\u8bf7\u4f7f\u7528\u4ee5\u4e0b\u683c\u5f0f\uff1a<\/p>\n

\r\n$ display -resize 600x400 ~\/Downloads\/bird.jp\r\n<\/pre>\n

\u53e6\u5916\uff0c\u4f60\u4e5f\u53ef\u4ee5\u4f7f\u7528\u767e\u5206\u6bd4\u6765\u8c03\u6574\u56fe\u7247\u7684\u5927\u5c0f\uff1a<\/p>\n

\r\n$ display -resize 50% ~\/Downloads\/bird.jpg\r\n<\/pre>\n
\u5982\u4f55\u4f7f\u7528 fim \u547d\u4ee4\u4ece\u7ec8\u7aef\u67e5\u770b\u56fe\u50cf<\/strong><\/div>\n

FIM \u662f\u4e00\u4e2a\u4e13\u95e8\u4e3a Linux \u8bbe\u8ba1\u7684\u8f7b\u91cf\u7ea7\u5168\u5c40\u56fe\u50cf\u67e5\u770b\u5668\u3002\u4f46\u5b83\u5e76\u4e0d\u5c40\u9650\u4e8e Linux\uff0c\u5b83\u4e5f\u53ef\u914d\u7f6e\u5728\u5176\u4ed6\u64cd\u4f5c\u7cfb\u7edf\u4e0a\u8fd0\u884c\uff0c\u5982 MS-Windows\u3002<\/p>\n

\u5bf9\u4e8e\u719f\u6089 VIM \u6587\u672c\u7f16\u8f91\u5668\u7b49\u8f6f\u4ef6\u7684\u7528\u6237\u6765\u8bf4\uff0c\u5b83\u662f\u9ad8\u5ea6\u53ef\u5b9a\u5236\u548c\u53ef\u811a\u672c\u5316\u7684\u56fe\u50cf\u67e5\u770b\u5668\u3002\u5b83\u53ef\u4ee5\u5168\u5c4f\u663e\u793a\u56fe\u50cf\uff0c\u5e76\u4e14\u53ef\u4ee5\u4f7f\u7528\u952e\u76d8\u5feb\u6377\u952e\u8f7b\u677e\u63a7\u5236\u3002\u5b83\u662f\u4e00\u6b3e\u975e\u5e38\u8f7b\u91cf\u7ea7\u7684\u5de5\u5177\uff0c\u56e0\u4e3a\u5b83\u53ea\u4f9d\u8d56\u4e8e\u67d0\u4e9b\u5e93\u3002<\/p>\n

\u5b83\u53ef\u4ee5\u6253\u5f00\u8bb8\u591a\u6587\u4ef6\u683c\u5f0f\uff0c\u5b83\u53ef\u4ee5\u5728\u4ee5\u4e0b\u89c6\u9891\u6a21\u5f0f\u4e0b\u663e\u793a\u56fe\u50cf\uff1a<\/p>\n

  • \u4f7f\u7528 Linux \u5e27\u7f13\u51b2\u8bbe\u5907\u56fe\u5f62\u5316\u3002<\/li>\n
  • \u5728 X\/Xorg \u4e0b\uff0c\u4f7f\u7528 SDL \u5e93\u56fe\u5f62\u5316<\/li>\n
  • \u5728 X\/Xorg \u4e0b\uff0c\u4f7f\u7528 Imlib2 \u5e93\u56fe\u5f62\u5316\u3002<\/li>\n
  • \u4f7f\u7528 AAlib \u5e93\uff0c\u5728\u4efb\u610f\u6587\u672c\u63a7\u5236\u53f0\u4e2d\u4ee5 ASCII \u827a\u672f\u5f62\u5f0f\u5448\u73b0\u3002<\/li>\n

    \u8fd0\u884c\u65f6\u81ea\u52a8\u68c0\u6d4b\u6216\u9009\u62e9\u6b63\u786e\u7684\u89c6\u9891\u6a21\u5f0f\uff0c\u5982\u679c\u9700\u8981\uff0c\u53ef\u4ee5\u5728\u6784\u5efa\u524d\u914d\u7f6e\u65f6\u9009\u62e9\u52a0\u5165\u6216\u53bb\u9664\u3002<\/p>\n

    FIM \u662f \u201cFbi IMproved\u201d \u7684\u7f29\u5199\uff0c\u662f Fbi Image Viewer \u7684\u590d\u523b\u7248\u672c\u3002<\/p>\n

    FIM \u53ef\u4ee5\u5f88\u5bb9\u6613\u5730\u5b89\u88c5\u5728\u57fa\u4e8e Debian\/Ubuntu \u7684\u7cfb\u7edf\u4e0a\uff0c\u56e0\u4e3a\u8be5\u8f6f\u4ef6\u5305\u5728\u53d1\u884c\u7248\u7684\u5b98\u65b9\u4ed3\u5e93\u4e2d\u662f\u53ef\u7528\u7684\u3002\u5bf9\u4e8e\u5176\u4ed6\u53d1\u884c\u7248\uff0c\u4f60\u53ef\u80fd\u9700\u8981\u4ece\u6e90\u7801\u7f16\u8bd1\u5b83\uff1a<\/p>\n

    \r\n$ sudo apt install fim\r\n<\/pre>\n

    \u5b89\u88c5\u5b8c\u6bd5\u540e\uff0c\u4f60\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u663e\u793a\u56fe\u50cf\uff1a<\/p>\n

    \r\n$ fim bird.jpg\r\n<\/pre>\n

    \u4f60\u53ef\u4ee5\u4f7f\u7528 -a \u9009\u9879\u81ea\u52a8\u7f29\u653e\u56fe\u50cf\uff1a<\/p>\n

    \r\n$ fim -a bird.jpg\r\n<\/pre>\n

    \"\"
    \n\u5982\u679c\u4f60\u8981\u6253\u5f00\u5f53\u524d\u76ee\u5f55\u4e2d\u7684\u591a\u4e2a\u56fe\u50cf\u6587\u4ef6\uff0c\u8bf7\u4f7f\u7528\u901a\u914d\u7b26\u5c06\u5b83\u4eec\u5168\u90e8\u6253\u5f00\u3002\u4f7f\u7528 PageUp\/PageDown \u952e\u76d8\u5feb\u6377\u952e\u79fb\u52a8\u5230\u4e0b\u4e00\u5f20\u6216\u4e0a\u4e00\u5f20\u56fe\u50cf\uff1a<\/p>\n

    \r\n$ fim -a *.jpg\r\n<\/pre>\n

    \u8981\u4ee5 ASCII \u683c\u5f0f\u67e5\u770b\u56fe\u50cf\uff0c\u53ef\u4ee5\u4f7f\u7528 -t \u6807\u5fd7\uff1a<\/p>\n

    \r\n$ fim -t bird.jpg\r\n<\/pre>\n

    \u4e0b\u9762\u7684\u952e\u76d8\u5feb\u6377\u952e\u53ef\u4ee5\u8ba9\u4f60\u63a7\u5236\u56fe\u50cf\uff1a<\/p>\n

  • PageUp\/PageDown\uff1a\u4e0a\u4e00\u5f20\/\u4e0b\u4e00\u5f20\u56fe\u7247\u3002<\/li>\n
  • +\/-\uff1a\u653e\u5927\/\u7f29\u5c0f<\/li>\n
  • a\uff1a\u81ea\u52a8\u7f29\u653e<\/li>\n
  • w\uff1a\u9002\u5e94\u5bbd\u5ea6<\/li>\n
  • ESC\/q\uff1a\u9000\u51fa<\/li>\n","protected":false},"excerpt":{"rendered":"

    \u5e78\u8fd0\u7684\u662f\uff0c\u5728\u4f7f\u7528 ImageMagick \u5de5\u5177\u65f6\uff0c\u6211\u5f97\u5230\u4e86\u4e00\u4e2a\u4ece\u7ec8\u7aef\u67e5\u770b\u56fe\u50cf\u7684\u547d\u4ee4\u3002\u547d\u4ee4\u540d\u662f \u201cdisplay […]<\/p>\n","protected":false},"author":362,"featured_media":129725,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[55],"tags":[],"class_list":["post-208025","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-thread"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/208025","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/362"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=208025"}],"version-history":[{"count":8,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/208025\/revisions"}],"predecessor-version":[{"id":208078,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/208025\/revisions\/208078"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/129725"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=208025"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=208025"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=208025"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}