Search found 45 matches

by gubach
2016-02-22T04:55:18-07:00
Forum: Developers
Topic: Arc 360 radius as function of input image w x h
Replies: 5
Views: 6519

Arc 360 radius as function of input image w x h

The general case "-distort Arc 360" generates from an image with $w_i x $h_i a circle structure with radius $r by bending the right and left edge together; the resulting square image has the width 2*$r. In the specific case "-distort Arc '360, 0, $r, 0'" the radius can be predefi...
by gubach
2015-04-02T13:26:48-07:00
Forum: PerlMagick
Topic: no halting if object is pushed multiple times
Replies: 1
Views: 9186

no halting if object is pushed multiple times

I want to push an image object with one image multiple times in an other image object, but for $A > 2 this seems not to halt for ($p = 1; $p <= $A; $p++) { push(@$img_list, $img); }; Have also tried push(@$img_list, @$img); Only if $img is written and multiple times read it works. The same problem i...
by gubach
2015-03-24T15:37:58-07:00
Forum: Users
Topic: Edge() with unacceptable artefacts
Replies: 8
Views: 9059

Re: Edge() with unacceptable artefacts

PerlMagick for

Code: Select all

convert img.png -morphology edgein diamond:1 result.png
is

Code: Select all

$img->Morphology(method=>'edgein', kernel=>'diamond', channel=>'all', iterations=>'1'); 
by gubach
2015-03-24T15:10:41-07:00
Forum: PerlMagick
Topic: enclose a shape with a rectangle
Replies: 4
Views: 11976

Re: enclose a shape with a rectangle

PerlMagick for

Code: Select all

 convert in.png -format %@ info: 
is

Code: Select all

 $geometry = $in_png->Get('bounding-box'); 
by gubach
2015-03-19T06:54:10-07:00
Forum: PerlMagick
Topic: enclose a shape with a rectangle
Replies: 4
Views: 11976

Re: enclose a shape with a rectangle

snibgo wrote:I don't know Perl. From the command line, you can get the rectangle's width and height, and top-left corner, from:

Code: Select all

convert in.png -format %@ info:
thank you!! This helps for now!
by gubach
2015-03-17T11:15:26-07:00
Forum: PerlMagick
Topic: enclose a shape with a rectangle
Replies: 4
Views: 11976

enclose a shape with a rectangle

I have a white shape over a black background and I want the coordinates of the two points that define the smallest rectangle that encloses the given shape. To get those values I have to compute the distance from the left boarder to the shape and from the top boarder to the shape. Has someone PerlMag...
by gubach
2014-12-21T08:23:02-07:00
Forum: PerlMagick
Topic: extracting a shape from a transparent background efficiently
Replies: 3
Views: 12241

Re: extracting a shape from a transparent background efficiently

Thaks for the answers. I only want to remove all extra transparent background after rotation. Version is: ImageMagick 6.7.8-7 2013-07-10 Q8 I looked in the description of the (parameterless) method: Trim remove edges that are the background color from the image and this means a usage like $image=>Tr...
by gubach
2014-12-20T04:21:18-07:00
Forum: PerlMagick
Topic: extracting a shape from a transparent background efficiently
Replies: 3
Views: 12241

extracting a shape from a transparent background efficiently

Suppose an image is given consisting of a monochrome shape (polygon) and a transparent background; there is no transparent border around the shape; points or edges touching the image border. If such images are rotated the ratio of the image may increase and the shape is not any more touching the ima...
by gubach
2014-07-06T09:11:08-07:00
Forum: PerlMagick
Topic: deleting duplicates in an image list
Replies: 1
Views: 8890

deleting duplicates in an image list

I have a list with downscaled black-and-white images ($mask_segment_list_dual) generated by an image processing pipeline and I want to delete duplicates in the list. In the command line tools I found compare -metric AE (or MAE) image1.png image2.png null: 2>&1 that delivers 0 if the two images a...
by gubach
2014-02-25T07:52:46-07:00
Forum: Users
Topic: Edge() with unacceptable artefacts
Replies: 8
Views: 9059

Re: Edge() with unacceptable artefacts

fmw42 wrote: $image->Morphology(kernel=>'edgein diamond:1', channel=>"all");
no, I got a "Failed to parse kernel number #0" error and image is unchanged.
by gubach
2014-02-24T11:08:29-07:00
Forum: Users
Topic: Edge() with unacceptable artefacts
Replies: 8
Views: 9059

Re: Edge() with unacceptable artefacts

I tried a workaround where I write the image, construct a $systemstring with "-morphology edgein diamond:", call the system from Perl with $systemstring and Read the result image to work with it in my processing pipeline. After some initial tries this ugly workaround is now working, but I ...
by gubach
2014-02-24T08:45:02-07:00
Forum: PerlMagick
Topic: how to map "-morphology edgein diamond:1" in PerlMagick
Replies: 0
Views: 7892

how to map "-morphology edgein diamond:1" in PerlMagick

Hello, I want to map this command line convert imput.png -morphology edgein diamond:1 result.png in PerlMagick but with the description of the Morphology method Morphology kernel=>string, channel=>{All, Default, Alpha, Black, Blue, CMYK, Cyan, Gray, Green, Index, Magenta, Opacity, Red, RGB, Yellow},...
by gubach
2014-02-23T05:17:13-07:00
Forum: Users
Topic: Edge() with unacceptable artefacts
Replies: 8
Views: 9059

Re: Edge() with unacceptable artefacts

convert 12701896523_c48135e0f9_k.jpg -morphology edgein diamond:1 result.png yes this works much!! better. Thank you very much! Now I need to integrate it in PerlMagick, but the description of the method Morphology on http://www.imagemagick.org/script/perl-magick.php Morphology kernel=>string, chan...
by gubach
2014-02-22T12:12:02-07:00
Forum: Users
Topic: Edge() with unacceptable artefacts
Replies: 8
Views: 9059

Edge() with unacceptable artefacts

Hello, I want to make edge images from geometric gray scale images (with a Perlmagick subprogram) but I get unacceptable artefacts. I used the edge-function in non geometric contexts a lot and I did not care about the artefacts there but in the geometric context it becomes unacceptable. Is the edge-...
by gubach
2013-12-13T11:56:39-07:00
Forum: PerlMagick
Topic: p6m tile perlmagick subprogram problem
Replies: 0
Views: 7538

p6m tile perlmagick subprogram problem

Hello, some years ago I wrote perl subprograms for the 17 eucledian symmetry groups. They worked sufficient for my art context but the groups based on non 90° and 45° angles have some minor artefacts. For one typ of those artefacts (black pixels at the edges were two triangles were composed) I have ...