Search found 6 matches

by ddayan
2011-04-30T03:48:08-07:00
Forum: Users
Topic: Unpredicted behaviour when using extent (SOLVED)
Replies: 2
Views: 4936

Re: Unpredicted behaviour when using extent

Thanks! It made be to realise that the problem is in my code. I found a case that the image stretches to the tile size before the extent function is being used. That is weird. there is no code in Extent to actually resize images as shown! It is really a 'create canvas', and compose image (with ...
by ddayan
2011-04-30T01:35:25-07:00
Forum: Users
Topic: Unpredicted behaviour when using extent (SOLVED)
Replies: 2
Views: 4936

Unpredicted behaviour when using extent (SOLVED)

I'm using the rmagick extend function cropped_image.background_color= "#ffffff" cropped_image = cropped_image.extent(256, 256) But in some cases it doesn't extend the image with white background http://i.imgur.com/aVUde.jpg This is what I'm expecting: http://i.imgur.com/j2LUH.jpg what could be the ...
by ddayan
2011-02-23T12:59:28-07:00
Forum: Users
Topic: Adding blank data after croping
Replies: 6
Views: 10705

Re: Adding blank data after croping

Using extent will fail with large images, just as border will. At one point you end up with three large images in memory! The original, the new canvas, and the resulting composition. Better to try and crop the image first, then extent or fill out the individule pieces. as then you only generate ...
by ddayan
2011-02-20T18:55:56-07:00
Forum: Users
Topic: Adding blank data after croping
Replies: 6
Views: 10705

Adding blank data after croping

I'm splitting an image into 256x256 tiles, the boundary tiles are smaller than 256*256, I wonder what would be the fastest (least resources use) do add blank(white) data to a cropped image (in order to make it 256x256)? I tried to add a border, but adding it to the original image takes too long and ...
by ddayan
2011-02-18T20:26:53-07:00
Forum: Users
Topic: How to read a portion of an image using RMagick/ImageMagick?
Replies: 1
Views: 3083

Re: How to read a portion of an image using RMagick/ImageMag

I've found the stream option http://www.imagemagick.org/Usage/basics/#stream

How can I use it within my RMagick code ? it seems like the RMagick API doesn't cover it
by ddayan
2011-02-18T20:02:51-07:00
Forum: Users
Topic: How to read a portion of an image using RMagick/ImageMagick?
Replies: 1
Views: 3083

How to read a portion of an image using RMagick/ImageMagick?

I'm trying to load a large image and crop it into tiles really fast and with low memory consumption. An example is the way gdal2tiles script http://www.maptiler.org/ does it, but gdal2tiles doesn't output the tiles the way I want them to be. Therefore I decided to develop my own version using ruby ...