Search found 1015 matches

by el_supremo
2007-07-07T10:24:54-07:00
Forum: MagickWand
Topic: reading pixels from a ImageMagik image?
Replies: 8
Views: 25714

Re: reading pixels from a ImageMagik image?

Two programmer errors methinks. This:

Code: Select all

imagepixels[i*(number_wands-1) + j] = PixelGetAlpha(pixels[i]);
should be this:

Code: Select all

imagepixels[i*number_wands + j] = PixelGetAlpha(pixels[j]);

Pete
by el_supremo
2007-07-06T19:31:48-07:00
Forum: MagickWand
Topic: reading pixels from a ImageMagik image?
Replies: 8
Views: 25714

Re: reading pixels from a ImageMagik image?

So I assume PixelGetBlack() would be the correct function for that What you need is PixelGetRed() (or Green() or Blue() since each pixel should have equal R, G and B values). [EDIT]: I thought you meant your image was already grayscale but perhaps it is colour and you want the grayscale value. If y...
by el_supremo
2007-06-29T16:22:31-07:00
Forum: Users
Topic: ImageMagick with php - system()
Replies: 2
Views: 8442

Re: ImageMagick with php - system()

First, you are missing a backslash in the pathname for convert - you need C:\Program Files\.... If that doesn't help then perhaps the space in "Program Files" is causing the system call to see only "C:\Program" as the first argument. In which case try copying convert.exe up to C:...
by el_supremo
2007-06-28T09:48:38-07:00
Forum: MagickWand for PHP
Topic: Can't Get Text To Display When Annotating or Drawing
Replies: 0
Views: 7894

Re: Can't Get Text To Display When Annotating or Drawing

I'm not familiar with PHP but I think what might be happening is that the Gravity isn't being set and it therefore defaults to Northwest. This would then draw your text just above the top of the image so that it won't show. Try moving the text with: MagickAnnotateImage($mwand,$dwand,100,50,0,"F...
by el_supremo
2007-06-25T17:14:45-07:00
Forum: Developers
Topic: MagickCore memory problem
Replies: 4
Views: 14938

Re: MagickCore memory problem

I think the problem is that in the second version you have images=ConstituteImage(...) but you don't destroy "images" later.

Pete
by el_supremo
2007-06-24T08:11:47-07:00
Forum: Users
Topic: CLI composite confusion: works in 6.1.7, broke in 6.3.3
Replies: 3
Views: 8922

Re: CLI composite confusion: works in 6.1.7, broke in 6.3.3

I think your original command is wrong but 6.1.7 must have ignored it. The -composite argument requires that you have already read in two images but you only read in rose: when you have the first -composite. Try this instead: convert rose: netscape: -compose Multiply -gravity center -composite -qual...
by el_supremo
2007-06-20T14:38:24-07:00
Forum: MagickWand for PHP
Topic: Equivalent command in Magickwand for convert -resize
Replies: 2
Views: 16860

Re: Equivalent command in Magickwand for convert -resize

I require a different convert command variation. I thought that would be easy but can't get it to work the way I thought it would. I tried this: magick_wand = NewMagickWand() p_wand = NewPixelWand() PixelSetColor(p_wand,"white") MagickNewImage(magick_wand,1,400,p_wand) MagickReadImage(mag...
by el_supremo
2007-06-18T11:02:33-07:00
Forum: Users
Topic: Transparent PNG overlay onto colored background.
Replies: 7
Views: 18450

Re: Transparent PNG overlay onto colored background.

IIRC composite didn't work well in V6.0.x. I'm using 6.3.2 and your command produces a red shirt on a white background.
Upgrade your IM and then try the command again.

Pete
by el_supremo
2007-06-16T10:38:30-07:00
Forum: Bugs
Topic: Bug? ImageMagick 6.3.4.9 vs a large BMP
Replies: 0
Views: 6376

Re: Bug? ImageMagick 6.3.4.9 vs a large BMP

The bmp.c coder is reading the image's width and height as long integers but then casting them as (short) which will truncate 70000 to 4464. In bmp.c at line 639, this code: /* Microsoft Windows BMP image file. */ if (bmp_info.size < 40) ThrowReaderException(CorruptImageError,"NonOS2HeaderSizeE...
by el_supremo
2007-06-16T08:28:07-07:00
Forum: Users
Topic: Compose an RBG image from 3 grayscale images
Replies: 4
Views: 12423

Re: Compose an RBG image from 3 grayscale images

This combines the gray scale images into one rgb image:

Code: Select all

convert image_r.jpg image_g.jpg image_b.jpg -combine image_combo.jpg
Pete
by el_supremo
2007-06-11T08:39:56-07:00
Forum: Users
Topic: flipping every other line of pixel in an image
Replies: 8
Views: 17914

Re: flipping every other line of pixel in an image

In windows you need to use the double quote instead of the single quote:

Code: Select all

convert rose: -fx "xx=j&1?(w-1)-i:i; p{xx,j}" rose_lflip.png
Pete
by el_supremo
2007-05-28T09:54:05-07:00
Forum: Bugs
Topic: Bug or not?
Replies: 1
Views: 9474

Re: Bug or not?

convert requires the filename arguments in the reverse order. Try:

Code: Select all

convert C:\s_text.png C:\text.png -compose Overlay -composite C:\sh_text.png
Pete
by el_supremo
2007-03-23T14:59:28-07:00
Forum: Users
Topic: Compose image yields odd results
Replies: 10
Views: 23506

Re: Compose image yields odd results

After some trial and error, I found that with black and white images this convert command appears to do what you want:

Code: Select all

convert shirt.jpg image.jpg -compose multiply -composite result.jpg
[EDIT]: If you want the image to look like your example use SrcOver instead of multiply.

Pete
by el_supremo
2007-03-11T09:22:14-07:00
Forum: Users
Topic: montage ... -transparent #COLOR failes to make color transpa
Replies: 6
Views: 17723

Re: montage ... -transparent #COLOR failes to make color transpa

Try putting both <file> before -resize.
IM V6 changed the way commands are specified and that looks like it would have worked with V5 syntax.
Pete
by el_supremo
2007-03-07T09:45:41-07:00
Forum: Users
Topic: anaglyph picture
Replies: 1
Views: 7741

Re: anaglyph picture

I've done this. On the command line you use composite (not convert):

Code: Select all

composite left.jpg right.jpg -stereo anaglyph.jpg
In MagickWand (in C) you would use

Code: Select all

stereo_wand = MagickStereoImage(left_wand,right_wand);
Pete