Hi...
Im pondering how to best create an image from a Ruby script.
1) a x*y size String comes to mind
easy manipulation
2) dump it out to a .pgm file
3) call pgm2jpg, pgm2png or something like that
4) serve link to file
For small images a "keep in memory" and call libjpg directly approach
comes to mind, for large images maybe via mmap?
Anyone ever did such things, pointer to example code?
thanks,
Martin
Martin Pirker wrote:
Hi...
Im pondering how to best create an image from a Ruby script.
1) a x*y size String comes to mind
easy manipulation
2) dump it out to a .pgm file
3) call pgm2jpg, pgm2png or something like that
4) serve link to file
For small images a "keep in memory" and call libjpg directly approach
comes to mind, for large images maybe via mmap?
Anyone ever did such things, pointer to example code?
When I did some image manipulation I used RMagick/ImageMagick.
http://rmagick.rubyforge.org/index.html
http://www.imagemagick.org/index.html?
I had some very plain text files, with y lines and x characters in each line. The chars where limited to single letters indicating red, blue, green, white, black etc. colours.
Stephan
Imagemagick has a ruby binding and allows to do all kind of stuff.
See: http://rmagick.rubyforge.org/
Regards,
Brian
···
On Wed, 17 Nov 2004 00:33:17 +0900 Martin Pirker <crf@sbox.tu-graz.ac.at> wrote:
Hi...
Im pondering how to best create an image from a Ruby script.
1) a x*y size String comes to mind
easy manipulation
2) dump it out to a .pgm file
3) call pgm2jpg, pgm2png or something like that
4) serve link to file
For small images a "keep in memory" and call libjpg directly approach
comes to mind, for large images maybe via mmap?
Anyone ever did such things, pointer to example code?
thanks,
Martin
--
Brian Schröder
http://www.brian-schroeder.de/
The RMagick doc is online at RMagick 1.15.0 User's Guide and Reference
···
On 16 Nov 2004 15:32:40 GMT, Martin Pirker <crf@sbox.tu-graz.ac.at> wrote:
Anyone ever did such things, pointer to example code?
Be careful, the latest version of RMagick does not work with the
latest version of ImageMagick. Try to get imagemagick 6.0.*
···
On Wed, 17 Nov 2004 04:23:18 +0900, Tim Hunter <sastph@sas.com> wrote:
On 16 Nov 2004 15:32:40 GMT, Martin Pirker <crf@sbox.tu-graz.ac.at> > wrote:
>
>Anyone ever did such things, pointer to example code?
>
The RMagick doc is online at RMagick 1.15.0 User's Guide and Reference
--
Tobi
http://blog.leetsoft.com
Correct. If you want to run with IM 6.1.3 or later, wait for RMagick
1.6.1, which will be available on RubyForge tonight or tomorrow.
···
On Wed, 17 Nov 2004 05:08:18 +0900, Tobias Luetke <tobias.luetke@gmail.com> wrote:
Be careful, the latest version of RMagick does not work with the
latest version of ImageMagick. Try to get imagemagick 6.0.*
Thanks a lot tim, rmagick rocks
···
On Wed, 17 Nov 2004 06:38:17 +0900, Tim Hunter <sastph@sas.com> wrote:
On Wed, 17 Nov 2004 05:08:18 +0900, Tobias Luetke > <tobias.luetke@gmail.com> wrote:
>Be careful, the latest version of RMagick does not work with the
>latest version of ImageMagick. Try to get imagemagick 6.0.*
>
Correct. If you want to run with IM 6.1.3 or later, wait for RMagick
1.6.1, which will be available on RubyForge tonight or tomorrow.
--
Tobi
http://blog.leetsoft.com
is there a ruby interface to ImageMagicks
or to the SDL or GDL libraries?
Klaus Schilling
As far as I know, there's rmagick (ImageMagick binding) and RuDL (I
think?) -- there are bindings to both ImageMagick and SDL, though.
Check the RAA.
-austin
···
On Fri, 19 Nov 2004 03:51:06 +0900, klaus schilling <510046470588-0001@t-online.de> wrote:
is there a ruby interface to ImageMagicks
or to the SDL or GDL libraries?
--
Austin Ziegler * halostatue@gmail.com
* Alternate: austin@halostatue.ca
klaus schilling wrote:
is there a ruby interface to ImageMagicks
or to the SDL or GDL libraries?
As I posted earlier in the thread, there is http://rmagick.rubyforge.org/index.html
Happy rubying
Stephan
klaus schilling ha scritto:
is there a ruby interface to ImageMagicks
or to the SDL or GDL libraries?
RUDL and ruby/sdl are bindings to SDL.
rmagick for ImageMagick
I think GDL means the GD library for graphs/images, there are bindings for that, too.
Looking on RAA (raa.ruby-lang.org ) should provide you links to get 'em