Dear All, Thank you all for your responses. I am able to implement my necessity with the help of ImageChops module. I was trying to combine the pixel values of two different images.
Thank you very much once again, With Warm Regards, Bishwarup On Tue, Oct 20, 2009 at 11:00 AM, Scott Sinclair <scott.sinclair.za@ gmail.com> wrote: > > >2009/10/20 Bishwarup Banerjee <[email protected]>: > > I have modified the code as follows: > > > > r1, g1, b1 = img.split() > > r2, g2, b2 = img1.split() > > outR = ImageMath.eval("(a + b)", a=r1, b=r2) > > outG = ImageMath.eval("(a + b)", a=g1, b=g2) > > outB = ImageMath.eval("(a + b)", a=b1, b=b2) > > > > out = Image.merge("RGB", (outR, outG, outB)) > > > > But, I am getting the same error "Value Error: Needs more than one value > to > > unpack" > > It sounds like the call to img.split() isn't returning a 3-tuple as > your code expects. You'll need to show how you define the variable > img. If you can make a small sample image file available for download > and a stand alone example that reads the sample image and fails at > img.split(), it would be easier for someone to help... > > Cheers, > Scott >
