unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* Imagemagick and Guile
@ 2015-01-11  9:09 A0
  2015-01-11 11:07 ` Nala Ginrut
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: A0 @ 2015-01-11  9:09 UTC (permalink / raw)
  To: guile-user

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello,

I need to generate an image from raw byte data in my code and
ImageMagick seems like an obvious choice to do this. But, looking
at
http://www.imagemagick.org/script/api.php ,
I see no Guile API listed.

Before I get my hands dirty, I'd like to check if someone already
built a functional API for Guile, or, at least, the chunk of it
containing the PixelIterator functionality.

I am also interested in hearing about other Guile-enabled libs
that can do the same thing, namely, creating an image in some
of the popular formats.

Best,

A0
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJUsj2wAAoJELoKbu7/AzdHvF0H/0JcGemTmJRGmaE9zpzuth5L
gvk3DHn7ns7apwaGJ3NTZlZv8J5H7AnwuNXo7XNOCPUsLYoCha95Y72YVY+wg8WR
wq8FdSNmAtFlAQFdz4t4tOpNHs5fVDL2V9b/AJc2kBATwKLpP5LI5xNgvKPR9l2E
tMGXZ3y2/VIRHBxmjFXLdPd5qSL+EQPaU77SWHZbf9TqNZ6RS00FxGQb4lnNi4w7
iCDa/zXgStgBfw8YdDoqD0pT853ne2SGi1WtoQ5dkwRRZlLTY9mO21ZtggQS6Whp
2hM5yOIeU+mUk+uvC6GPkv9lmW1Acc5IVsWlCIbvorCIGsP5tiZ9pi3Ue9VH1oI=
=Hc+u
-----END PGP SIGNATURE-----



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

* Re: Imagemagick and Guile
  2015-01-11  9:09 Imagemagick and Guile A0
@ 2015-01-11 11:07 ` Nala Ginrut
  2015-01-11 12:02 ` John Darrington
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 8+ messages in thread
From: Nala Ginrut @ 2015-01-11 11:07 UTC (permalink / raw)
  To: A0; +Cc: Guile User

[-- Attachment #1: Type: text/plain, Size: 137 bytes --]

Hi! IIRC there is no Imagemagick binding for guile. It is good to have one.
But you may use guile-charting to generate images from data.

[-- Attachment #2: Type: text/html, Size: 159 bytes --]

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

* Re: Imagemagick and Guile
  2015-01-11  9:09 Imagemagick and Guile A0
  2015-01-11 11:07 ` Nala Ginrut
@ 2015-01-11 12:02 ` John Darrington
  2015-01-11 12:56   ` A0
  2015-01-11 12:11 ` Neil Jerram
  2015-01-11 12:46 ` Ludovic Courtès
  3 siblings, 1 reply; 8+ messages in thread
From: John Darrington @ 2015-01-11 12:02 UTC (permalink / raw)
  To: A0; +Cc: guile-user

[-- Attachment #1: Type: text/plain, Size: 1292 bytes --]

I have done similar things using Gimp.

Gimp, as you may know, has a Scheme interface which is very similar to 
Guile, (in fact I believe Guile was forked from the Gimp interpretor).


For example to generate png files from a svg input see

http://git.savannah.gnu.org/cgit/pspp.git/tree/build-aux/svg2png

The disadvantage is that it is much slower than imagemagick

J'

On Sun, Jan 11, 2015 at 09:09:04AM +0000, A0 wrote:
     
     Hello,
     
     I need to generate an image from raw byte data in my code and
     ImageMagick seems like an obvious choice to do this. But, looking
     at
     http://www.imagemagick.org/script/api.php ,
     I see no Guile API listed.
     
     Before I get my hands dirty, I'd like to check if someone already
     built a functional API for Guile, or, at least, the chunk of it
     containing the PixelIterator functionality.
     
     I am also interested in hearing about other Guile-enabled libs
     that can do the same thing, namely, creating an image in some
     of the popular formats.
     
     Best,
     
     A0
     

-- 
PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

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

* Re: Imagemagick and Guile
  2015-01-11  9:09 Imagemagick and Guile A0
  2015-01-11 11:07 ` Nala Ginrut
  2015-01-11 12:02 ` John Darrington
@ 2015-01-11 12:11 ` Neil Jerram
  2015-01-11 12:53   ` A0
  2015-01-11 16:12   ` David Pirotte
  2015-01-11 12:46 ` Ludovic Courtès
  3 siblings, 2 replies; 8+ messages in thread
From: Neil Jerram @ 2015-01-11 12:11 UTC (permalink / raw)
  To: guile-user

On 2015-01-11 09:09, A0 wrote:

> I need to generate an image from raw byte data in my code and
> ImageMagick seems like an obvious choice to do this. But, looking
> at
> http://www.imagemagick.org/script/api.php ,
> I see no Guile API listed.
> 
> Before I get my hands dirty, I'd like to check if someone already
> built a functional API for Guile, or, at least, the chunk of it
> containing the PixelIterator functionality.
> 
> I am also interested in hearing about other Guile-enabled libs
> that can do the same thing, namely, creating an image in some
> of the popular formats.

In addition to the other suggestions that people have made, note that 
you could also use the Guile FFI to access ImageMagick's C API from 
Guile.

Personally, I find using the FFI much more fun than writing a 'proper' 
Guile binding.

Regards,
       Neil




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

* Re: Imagemagick and Guile
  2015-01-11  9:09 Imagemagick and Guile A0
                   ` (2 preceding siblings ...)
  2015-01-11 12:11 ` Neil Jerram
@ 2015-01-11 12:46 ` Ludovic Courtès
  3 siblings, 0 replies; 8+ messages in thread
From: Ludovic Courtès @ 2015-01-11 12:46 UTC (permalink / raw)
  To: guile-user

A0 <cape.wrath@openmailbox.org> skribis:

> I need to generate an image from raw byte data in my code and
> ImageMagick seems like an obvious choice to do this.

Alternately, I think Andy’s guile-jpeg would be readily usable to
generate JPEGs from bitmaps:

  https://gitorious.org/guile-jpeg/guile-jpeg/

Ludo’.




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

* Re: Imagemagick and Guile
  2015-01-11 12:11 ` Neil Jerram
@ 2015-01-11 12:53   ` A0
  2015-01-11 16:12   ` David Pirotte
  1 sibling, 0 replies; 8+ messages in thread
From: A0 @ 2015-01-11 12:53 UTC (permalink / raw)
  To: Neil Jerram; +Cc: guile-user

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 11/01/15 12:11, Neil Jerram wrote:
> On 2015-01-11 09:09, A0 wrote:
> 
>> I need to generate an image from raw byte data in my code and 
>> ImageMagick seems like an obvious choice to do this. But,
>> looking at http://www.imagemagick.org/script/api.php , I see no
>> Guile API listed.
>> 
>> Before I get my hands dirty, I'd like to check if someone
>> already built a functional API for Guile, or, at least, the chunk
>> of it containing the PixelIterator functionality.
>> 
>> I am also interested in hearing about other Guile-enabled libs 
>> that can do the same thing, namely, creating an image in some of
>> the popular formats.
> 
> In addition to the other suggestions that people have made, note
> that you could also use the Guile FFI to access ImageMagick's C API
> from Guile.
> 
> Personally, I find using the FFI much more fun than writing a
> 'proper' Guile binding.
> 
> Regards, Neil
> 
> 

Sure, I'll use the FFI to wrap the procedures i need, provided no one
has bothered to
do that before. I just think, unless for educational purposes, or if
you can do it much better (but, hey, it's just an API),
it does not make much sense to repeat something someone has already
done before.

Best,

A0
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJUsnJdAAoJELoKbu7/AzdHRTsH/R5HoKN8gebPIqw9TpH3Yd5B
ttNo8YYwWsHDtwoGJTM4lw0UN8eAQl1p2MViBYNd7lqTrC8d9EF2PGuJ5PhjTnqN
97ngZMx/+n8nTBUuUR3l16URRJoRCssDg+oBAF968/+AA2u6qDY58jTJxEu7tj4c
a2/Nc0g8uji+DfgrcYyZcoTfhIVahMzYte44extDPIIe5LHWU5rtyYDiTU+g20JK
euvVxnay8u5rg1JAqouuG3uVR9Mg5mlNY3u5coRszZ2JuLLWOdi9wLOUAMNx0nRt
a+q2j3A4adEonBRgH69yAEeXw+sV2AN1XsL4Od24JAnUlkCDFUxdfncD+KWioak=
=0fkW
-----END PGP SIGNATURE-----



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

* Re: Imagemagick and Guile
  2015-01-11 12:02 ` John Darrington
@ 2015-01-11 12:56   ` A0
  0 siblings, 0 replies; 8+ messages in thread
From: A0 @ 2015-01-11 12:56 UTC (permalink / raw)
  To: John Darrington; +Cc: guile-user

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



On 11/01/15 12:02, John Darrington wrote:
> I have done similar things using Gimp.
> 
> Gimp, as you may know, has a Scheme interface which is very similar
> to Guile, (in fact I believe Guile was forked from the Gimp
> interpretor).
> 
> 
> For example to generate png files from a svg input see
> 
> http://git.savannah.gnu.org/cgit/pspp.git/tree/build-aux/svg2png
> 
> The disadvantage is that it is much slower than imagemagick
> 
> J'
> 
> On Sun, Jan 11, 2015 at 09:09:04AM +0000, A0 wrote:
> 
> Hello,
> 
> I need to generate an image from raw byte data in my code and 
> ImageMagick seems like an obvious choice to do this. But, looking 
> at http://www.imagemagick.org/script/api.php , I see no Guile API
> listed.
> 
> Before I get my hands dirty, I'd like to check if someone already 
> built a functional API for Guile, or, at least, the chunk of it 
> containing the PixelIterator functionality.
> 
> I am also interested in hearing about other Guile-enabled libs that
> can do the same thing, namely, creating an image in some of the
> popular formats.
> 
> Best,
> 
> A0
> 
> 

Thanks for the info, but for the application I have i mind
the conversion needs to be as fast as reasonably possible.

Best,

A0
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJUsnL4AAoJELoKbu7/AzdH8WUH/Ah0ki4twLfhnMPFJUCuNaK8
KataBP1DYcgg7Lx06G65qHthkSJEQ5lFVFvJ5Z2mn/Ef8oMArCIXcurmlmrBISZ8
RJXqh90qh0CKoppkVfu8NyZH0huG2871fepoX2rQkYcUd1Zf6oZKN1KbORBV3IdQ
HS1lUy+ul845z6qvBXJAZzPdiYUoaIAFNVGt3wtDvj644Z0Q6/1Mqie7Mk7UFvTt
RZxMgk1HRavgqcrrBIweqeRHvO7e+wrce21+vgJE5c1Ph+r/Y2WLvo+Y5BswkjOC
m+0ILcfZM+QFSpY2lu3Pp1QABVT0Ja3CeFWrl0JJ1BYzcewklC8pG1b9WNKIEF4=
=VGTI
-----END PGP SIGNATURE-----



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

* Re: Imagemagick and Guile
  2015-01-11 12:11 ` Neil Jerram
  2015-01-11 12:53   ` A0
@ 2015-01-11 16:12   ` David Pirotte
  1 sibling, 0 replies; 8+ messages in thread
From: David Pirotte @ 2015-01-11 16:12 UTC (permalink / raw)
  To: Neil Jerram; +Cc: guile-user

[-- Attachment #1: Type: text/plain, Size: 1096 bytes --]

Hello,

> ...
> Personally, I find using the FFI much more fun than writing a 'proper' 
> Guile binding
> ...

I would consider GraphicsMagick instead http://www.graphicsmagick.org/index.html
There has been a fork in 2002, due to license problems,

	 ... ImageMagick from ImageMagick Studio LLC abandoned the MIT X11 style
	 license it had been using since 1992, and switched between several different
	 licenses until it ended up with one based on the Apache license, which is
	 intended to penalize projects which borrow some of its source code, or fork
	 from it. Since that time, GraphicsMagick has not incorporated any
	 ImageMagick source code

	... On November 27, 2003 ImageMagick Studio LLC applied to register
	"ImageMagick" as its trademark, and it was awarded this registered trademark
	(serial number 78333969) on August 30, 2005. Those who re-distribute
	modified versions of "ImageMagick" (e.g. patched or improved) under license
	as "ImageMagick" now face the risk of arbitrary trademark infringement
	claims by ImageMagick Studio LLC ...

Cheers,
David

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

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

end of thread, other threads:[~2015-01-11 16:12 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-11  9:09 Imagemagick and Guile A0
2015-01-11 11:07 ` Nala Ginrut
2015-01-11 12:02 ` John Darrington
2015-01-11 12:56   ` A0
2015-01-11 12:11 ` Neil Jerram
2015-01-11 12:53   ` A0
2015-01-11 16:12   ` David Pirotte
2015-01-11 12:46 ` Ludovic Courtès

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).