unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: Paul Eggert <eggert@cs.ucla.edu>
Cc: Katsumi Yamaoka <yamaoka@jpl.org>,
	Stefan Monnier <monnier@IRO.UMontreal.CA>,
	emacs-devel@gnu.org
Subject: Re: [Emacs-diffs] /srv/bzr/emacs/trunk r107264: shr.el (shr-rescale-image): Allow viewing large images.
Date: Tue, 14 Feb 2012 15:49:53 +0100	[thread overview]
Message-ID: <87haytfp0u.fsf@gnus.org> (raw)
In-Reply-To: <4F3A194F.8000508@cs.ucla.edu> (Paul Eggert's message of "Tue, 14 Feb 2012 00:20:31 -0800")

Paul Eggert <eggert@cs.ucla.edu> writes:

> By '9gag' do you mean 9gag.com?

Yup.

> Currently, its third image
> <http://d24w6bsrhbeh9d.cloudfront.net/photo/2611347_460s.jpg> is
> 472x4464, which I suppose could run into a problem with max-image-size
> being 6.0 if your screen is small.

Yeah, it's a laptop with a 1280x800 screen.  I'd guesstimate that about
one fifth of the images from 9gag don't display with the 6.0 default.

> I suggest the following heuristic instead.  Take the total amount
> of physical memory, divide by 64, and reject images
> that would consume more than that amount of RAM.
> For example, my desktop has 2 GiB of physical RAM, so any image
> requiring more than 32 MiB of RAM would be rejected;
> this would easily allow the 9gag image mentioned above,
> which consumes about 9 MiB assuming 32 bits per pixel.
> The divisor "64" is a heuristic that could be user-adjusted;
> but the point is that dividing RAM by 64 is a more-useful default
> than multiplying the frame size by 6.

I think that's probably a better solution than the frame size thing.
Would it affect animated gifs, though?  I mean, currently Emacs doesn't
balk at displaying a 1TB huge animated GIF (or something :-)...

> If all this is too much trouble, I suggest going back to the 6.0
> limit for now, and revisiting this issue after Emacs 24.1 comes out.

I think the limit should be set to something that gives as little
problems to real-world usage as realistic.  6.0 is too small, nil is
unresponsible, and 60.0 is probably too large.  10.0?

-- 
(domestic pets only, the antidote for overdose, milk.)
  http://lars.ingebrigtsen.no  *  Sent from my Rome



  reply	other threads:[~2012-02-14 14:49 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <E1RwnLm-0007NV-Lm@vcs.savannah.gnu.org>
2012-02-13 13:15 ` [Emacs-diffs] /srv/bzr/emacs/trunk r107264: shr.el (shr-rescale-image): Allow viewing large images Stefan Monnier
2012-02-13 19:57   ` Andy Moreton
2012-02-13 20:03     ` Lars Ingebrigtsen
2012-02-13 20:01   ` [Emacs-diffs] " Lars Ingebrigtsen
2012-02-13 20:29     ` Paul Eggert
2012-02-13 20:33       ` Lars Ingebrigtsen
2012-02-13 20:41         ` Ted Zlatanov
2012-02-15  6:26           ` Chong Yidong
2012-02-15 13:40             ` Ted Zlatanov
2012-02-14  8:20         ` Paul Eggert
2012-02-14 14:49           ` Lars Ingebrigtsen [this message]
2012-02-14 15:56             ` Paul Eggert
2012-02-14 18:26               ` Lars Ingebrigtsen
2012-02-15  6:42                 ` Chong Yidong
2012-02-15  6:27               ` Chong Yidong
2012-02-14 17:43         ` Stefan Monnier
2012-02-13 21:24     ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87haytfp0u.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=eggert@cs.ucla.edu \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@IRO.UMontreal.CA \
    --cc=yamaoka@jpl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).