unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Image-conversion shims
@ 2019-09-28 20:06 Lars Ingebrigtsen
  2019-09-28 20:37 ` Clément Pit-Claudel
  2019-09-28 21:05 ` Stefan Monnier
  0 siblings, 2 replies; 30+ messages in thread
From: Lars Ingebrigtsen @ 2019-09-28 20:06 UTC (permalink / raw)
  To: emacs-devel

I suggested this in an unrelated bug report, but nobody probably saw it
there, so I'm bringing it up here again:

Emacs has approximate feature parity for the major image formats (JPEG,
PNG, etc) now with ImageMagick-enabled Emacs versions.  I think our
long-term plan is to obsolete the ImageMagick support completely,
because ImageMagick has some security issues.

However, the only way to support more obscure image formats (like BMP or
WebP) is currently to build with ImageMagick support, so it seems likely
to me that distributions are going to continue doing that.

So I wonder whether a way to speed up the transition to an
ImageMagick-less future would be to have a small package that would
convert "transparently" from formats we don't understand to formats we
do understand.

The only likely external conversion program is, unfortunately, "convert"
from ImageMagick, so there are still security implications, and a shim
like that isn't something we could have switched on by default.
However, we would be able to say to users who need to handle some BMP
images "set `use-external-image-formats' to t" instead of "build with
ImageMagick", and that would be a win, I think.  (Because Emacs would at
least segfault less.)

If that variable is t, and we don't have support for whatever image
format the user is trying to display, then `create-image' would use the
conversion package to basically run "convert" on the file first.  And
"convert -list format/magic" tell us what formats it supports, so it
could all be made to work automagically.

Thoughts?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2019-10-14 19:41 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-28 20:06 Image-conversion shims Lars Ingebrigtsen
2019-09-28 20:37 ` Clément Pit-Claudel
2019-09-28 21:20   ` Lars Ingebrigtsen
2019-09-29  6:24   ` Eli Zaretskii
2019-09-28 21:05 ` Stefan Monnier
2019-09-28 21:21   ` Lars Ingebrigtsen
2019-09-28 23:29   ` Lars Ingebrigtsen
2019-09-29  0:01     ` Lars Ingebrigtsen
2019-09-29  7:11     ` Eli Zaretskii
2019-09-29 11:44       ` Lars Ingebrigtsen
2019-09-29 11:56         ` Eli Zaretskii
2019-09-30  4:12           ` Lars Ingebrigtsen
2019-09-30  7:06             ` Eli Zaretskii
2019-09-30 13:42               ` Lars Ingebrigtsen
2019-09-30 14:01                 ` Eli Zaretskii
2019-10-01 12:06                   ` Lars Ingebrigtsen
2019-10-01 12:36                     ` Eli Zaretskii
2019-09-30 17:27             ` Stefan Monnier
2019-10-01 12:08               ` Lars Ingebrigtsen
2019-10-01 13:09                 ` Stefan Monnier
2019-10-06 20:58             ` Juri Linkov
2019-10-07  1:41               ` Lars Ingebrigtsen
2019-10-07 18:48                 ` Juri Linkov
2019-10-08 16:06                   ` Lars Ingebrigtsen
2019-10-08 17:47                     ` Stefan Monnier
2019-10-09 19:26                       ` Lars Ingebrigtsen
2019-10-09 19:53                         ` Stefan Monnier
2019-10-14  4:53                           ` Lars Ingebrigtsen
2019-10-14 19:27                             ` Juri Linkov
2019-10-14 19:41                               ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).