Re: gradients going wrong
Posted: 2008-10-07T08:54:10-07:00
Im viewing the image in firefox, safari and internet explorer. All show black bars running through it (internet explorer shows slightly lighter black bars).
Use https://github.com/ImageMagick/ImageMagick/discussions instead.
https://imagemagick.com/discourse-server/
https://imagemagick.com/discourse-server/viewtopic.php?t=11974
I am using Safari 3.1.2 Mac OSX 10.4.11 Tiger and I don't see any black bars. But in Firefox, I do see them. Let me analyze further, but try the other test I suggested.davidb2002 wrote:Im viewing the image in firefox, safari and internet explorer. All show black bars running through it (internet explorer shows slightly lighter black bars).
no, it gives me a blue colour:First tell me if this works:
convert -size 100x100 xc:white xc:gray40 xc:black -combine test_color4.png
davidb2002 wrote:no, it gives me a blue colour:First tell me if this works:
convert -size 100x100 xc:white xc:gray40 xc:black -combine test_color4.png
With regard to this issue, I simply tried to copy your imageAlso the verbose info of your orange with black stripes image also shows:
Colormap: 1
0: (255,102, 0) #FF6600 rgb(255,102,0)
Thanks for the help all the way through this. I basically went through the entire topic again and picked out what worked and used my php skills to use bits and pieces.$cmd = IMAGEMAGIKDIR.' -size 1x1 xc:"#FF6600" -depth 8 txt:';
$rgb = exec($cmd);
# SPLIT THE STRING TO GET THE RGB VALUES RETURNED
$start = strpos($rgb,'(');
$end = strpos($rgb,')');
$length = $end-$start+1;
$rgb = substr($rgb,$start,$length);
$rgb = str_replace(' ','',$rgb);
$cmd = IMAGEMAGIKDIR.' -size 10x100 xc:"rgb'.$rgb.'" -depth 8 -type TrueColor myfile.png;
exec($cmd);
Glad to hear the good news. And happy to have been able to help.davidb2002 wrote:I have managed to get it to work using some PHP trickery to manipulate the string IM returns:
Thanks for the help all the way through this. I basically went through the entire topic again and picked out what worked and used my php skills to use bits and pieces.$cmd = IMAGEMAGIKDIR.' -size 1x1 xc:"#FF6600" -depth 8 txt:';
$rgb = exec($cmd);
# SPLIT THE STRING TO GET THE RGB VALUES RETURNED
$start = strpos($rgb,'(');
$end = strpos($rgb,')');
$length = $end-$start+1;
$rgb = substr($rgb,$start,$length);
$rgb = str_replace(' ','',$rgb);
$cmd = IMAGEMAGIKDIR.' -size 10x100 xc:"rgb'.$rgb.'" -depth 8 -type TrueColor myfile.png;
exec($cmd);