Copy color from source image
Re: Copy color from source image
I am now trying with different images.
-brightness-contrast -40,30 -- I think, this is the keyword and important to merge the images.
I will upload what i got for different images.
-brightness-contrast -40,30 -- I think, this is the keyword and important to merge the images.
I will upload what i got for different images.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Copy color from source image
agriz wrote:I am now trying with different images.
-brightness-contrast -40,30 -- I think, this is the keyword and important to merge the images.
I will upload what i got for different images.
-brightness-contrast does not affect merging images, all it does is change how bright or how much contrast you have in your background image.
See my other examples that followed without the -brightness-contrast. Tell me what it is that you want to do that is different from any or all of my examples above.
What is your current php command?
Re: Copy color from source image
second example is just merging.
I want the first example.
If i upload my photo, then, it should be merged with that poster and should look like little old poster
I want the first example.
If i upload my photo, then, it should be merged with that poster and should look like little old poster
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Copy color from source image
agriz wrote:second example is just merging.
I want the first example.
If i upload my photo, then, it should be merged with that poster and should look like little old poster
Are you getting what you want now? If not, what is your current command?
see
http://www.imagemagick.org/script/comma ... s-contrast
http://www.imagemagick.org/Usage/color_mods/
http://www.imagemagick.org/Usage/layers/#convert
Re: Copy color from source image
First example is working for few images.
For some other images, i am not exactly getting the result.
I will try this now "-sigmoidal-contrast 10,50%"
For some other images, i am not exactly getting the result.
I will try this now "-sigmoidal-contrast 10,50%"
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Copy color from source image
Starting at basics....
You mentioned you have a color photo you want to make look like it matches the old poster.
Hmmm I would look at the poster and try to work out the average darkest (text), and lightest (background) color and use that as as tinting gradent for a black and white version of the photo.
You mentioned you have a color photo you want to make look like it matches the old poster.
Hmmm I would look at the poster and try to work out the average darkest (text), and lightest (background) color and use that as as tinting gradent for a black and white version of the photo.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/
Re: Copy color from source image
This is my exact need.
I was trying lot. But This picture explains what i am exactly looking.
I want to replace the photo in the heart.
Another one is
I want to composite a photo in the middle of the heart, But the photo should mingle with the heart's color.
This is not correct. Because the photo is not mingled with the original image.
This one is good. it is mingled with the original photo.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Copy color from source image
You need to create a feathered alpha channel on the overlay image before compositing. Post a link to your two separate input images that you want to combine and we can show you how to do that.
Below I cropped the girl image from your composite, then did the following:
convert zmy23k.png hva0p0_crop.png \
\( -clone 1 -fill white -colorize 100% -virtual-pixel black -blur 0x20 -auto-level -level 50x100% \) \
\( -clone 1 -clone 2 -alpha off -compose copy_opacity -composite \) \
-delete 1,2 -gravity center -geometry +0-30 -compose over -composite zmy23k_hva0p0_comp.png
You can adjust the blur amount from 20 to some other value to get different vignetting effects.
Below I cropped the girl image from your composite, then did the following:
convert zmy23k.png hva0p0_crop.png \
\( -clone 1 -fill white -colorize 100% -virtual-pixel black -blur 0x20 -auto-level -level 50x100% \) \
\( -clone 1 -clone 2 -alpha off -compose copy_opacity -composite \) \
-delete 1,2 -gravity center -geometry +0-30 -compose over -composite zmy23k_hva0p0_comp.png
You can adjust the blur amount from 20 to some other value to get different vignetting effects.
Re: Copy color from source image
I tried your script.
But it didn't work
That is the right image.
That girl image can be anything.
I tried this code
I used an jpg image instead of that png
I am using imagemagick version 6.7.4-0 (This is windows)
@6.5.4-7 (This is linux)
I got this following error.
unrecognized option `-auto-level'
But it didn't work
That is the right image.
That girl image can be anything.
I tried this code
Code: Select all
/usr/bin/convert zmy23k.png hva0p0_crop.jpg \( -clone 1 -fill white -colorize 100% -virtual-pixel black -blur 0x20 -auto-level -level 50x100% \) \( -clone 1 -clone 2 -alpha off -compose copy_opacity -composite \) -delete 1,2 -gravity center -geometry +0-30 -compose over -composite zmy23k_hva0p0_comp.png
I am using imagemagick version 6.7.4-0 (This is windows)
@6.5.4-7 (This is linux)
I got this following error.
unrecognized option `-auto-level'
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Copy color from source image
Your linux version of IM is too old for -auto-level. Replace it with -contrast-stretch 0
Also windows syntax is different. You must remove the \ with the parens and change % to %%. Also the end of line \ needs to be changed to ^
see
http://www.imagemagick.org/Usage/windows/
Also windows syntax is different. You must remove the \ with the parens and change % to %%. Also the end of line \ needs to be changed to ^
see
http://www.imagemagick.org/Usage/windows/
Last edited by fmw42 on 2012-02-18T10:36:22-07:00, edited 1 time in total.
Re: Copy color from source image
I used yum install ImageMagick on my fedora.
How to get the latest version?
How to get the latest version?
Re: Copy color from source image
Try this:
- yum install ImageMagick-devel
cd /tmp
wget http://www.imagemagick.org/download/Ima ... 5-3.tar.gz
tar xvfz ImageMagick-6.7.5-3.tar.gz
cd ImageMagick-6.7.5-3
./configure
make
make install
Re: Copy color from source image
Will it install in the /usr/bin/ ?
Or do i need to configure the path during the install?
Or do i need to configure the path during the install?
Re: Copy color from source image
By default it installs in /usr/local.
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Copy color from source image
I recommend a package install of IM under fedora -- I do this all the time...
Packages make it cleaner to install and upgrade.
See my notes in..
http://www.imagemagick.org/Usage/api/#rpms
However if you want a non-system (personal) version, look at the section further down
http://www.imagemagick.org/Usage/api/#personal
A have 3 'personal' versions I pick an choose from as part of my development work.
Personal versions does not interfere with other programs that may use ImageMagick. (such as the "Calibre" E-book reader)
Packages make it cleaner to install and upgrade.
See my notes in..
http://www.imagemagick.org/Usage/api/#rpms
However if you want a non-system (personal) version, look at the section further down
http://www.imagemagick.org/Usage/api/#personal
A have 3 'personal' versions I pick an choose from as part of my development work.
Personal versions does not interfere with other programs that may use ImageMagick. (such as the "Calibre" E-book reader)
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/