I am trying to "paste" one image on top of another without the colour of the "pasted" image being changed at all.
It seems to work fine if i use a plain white image like so:
convert -quality 100% -size 715x156 xc:white "testnew.jpg"
convert -quality 100% -background none -virtual-pixel transparent -pointsize 40 -font "Open_Sans.ttf" -fill "#e66956" label:"Testing" "label.png"
composite -quality 100% -geometry +50+50 "label.png" "testnew.jpg" "testnew.jpg"
But if i use a different image that has some other colour in it, the colours in the "pasted" imaged get modified (there are some dark edges added):
convert -quality 100% "526org_1370178839.jpg" "testnew.jpg"
convert -quality 100% -background none -virtual-pixel transparent -pointsize 40 -font "Open_Sans.ttf" -fill "#e66956" label:"Testing" "label.png"
composite -quality 100% -geometry +50+50 "label.png" "testnew.jpg" "testnew.jpg"
I want the text to be copied exactly as it is, over the top without it changing colour.
Thanks for any help.
"paste" image on top of another
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: "paste" image on top of another
Don't use JPG files. The compression is lossy, which means the colours will change every time you save and re-read.
snibgo's IM pages: im.snibgo.com
Re: "paste" image on top of another
Thank you!
I have changed my program to use PNG files now, and only convert to JPG once at the end when needed.
I was adding multiple label images to the original which was causing the text to look horrible. Now it looks much better.
I have changed my program to use PNG files now, and only convert to JPG once at the end when needed.
I was adding multiple label images to the original which was causing the text to look horrible. Now it looks much better.