emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Introducing emacs-webkit and more thoughts on Emacs rendering (was R


From: Arthur Miller
Subject: Re: Introducing emacs-webkit and more thoughts on Emacs rendering (was Rethinking the design of xwidgets)
Date: Tue, 01 Dec 2020 16:36:44 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Tomas Hlavaty <tom@logand.com> writes:

> On Sun 29 Nov 2020 at 20:54, Akira Kyle <akira@akirakyle.com> wrote:
>> However I think designing such a feature should keep eventual
>> integration with modules in mind. Especially since in general graphics
>> is very performance sensitive and so doing some drawing in elisp just
>> might not cut it and many interesting applications of such a feature
>> would require interfacing with an external c library.
>
> Not necessarily.
>
> There could also be a specialized program which could handle drawing.
> In fact there already is such a program: w3mimgdisplay and is part of
> the w3m web browser and pager.  It is also used in the file manager
> ranger.  It works both with or without X.  I am using it in
> emacs-framebuffer too to display images and documents in Emacs.
>
> The issues I am facing have nothing to do with modules or libraries.
>
> For example:
>
> It would be more convenient, if there was a way to specify elisp
> function to draw an image.  By default, it could just call the existing
> C code but this would also allow me to specify a different elisp
> function which would then for example call w3mimgdisplay.
>
> It would be more convenient, if an image was represented as elisp data
> instead of C data.
:-) I don't think you have thought well about it;

but really nothing forbids you to try to reprsent images as lisp.

You can take any de-compressed image and read in raw pixels in as a byte
buffer and just shuffle around numbers and see how it
works for you.Image is nothing but a bunch of numbers + some tiny
metadata on top of it. Take some of netpbm formats and you have "textual
image" you can manipulate on per-pixel level with lisp.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]