Your problem can be broken into 2 parts..

1. Handling TIF images. Do you have the capability of
decoding TIF images? And encoding an image array into
TIF format? If YES, Go straight to point-2. If NO, try
to get an open source TIF reader/writer source code.
www.sourceforge.net might be of help.

2. Once point-1 above is sorted out, forming a
'composite image' from color separations is pretty
easy. Assuming that you are working in RGB color
space, following snippet should be indicative enough:
------------------------------------
int composite_image[width*height*3]; // so as to
handle RGB triples.
int counter = 0; // to be used later.
int Red[width][height]; // you already have this.
int Green[width][height]; // you already have this.
int Blue[width][height]; // you already have this.
// Assuming that you have Red, Green, Blue 
// arrays with you..
for (int i=0; i<width; i++)
{
    for (int j=0; j<height; j++)
    {
        composite_image[counter++] = Red[i][j];
        composite_image[counter++] = Green[i][j];
        composite_image[counter++] = Blue[i][j];
    }
}
// After this loop 'composite_image' array is 
// ready to be fed to the TIF encoder so as to 
// form a color image.
---------------------------------------------

This of course is an answer and not the solution :)
Feel free to revert back.

warm regards,
- Divya Rathore
www.ryze.com/go/divyarathore


> ----- Original Message ----- 
> From: "Vorpal Swordsman" <[EMAIL PROTECTED]>
> To: <[email protected]>
> Sent: Thursday, February 24, 2005 9:43 PM
> Subject: [msvc] TIF and other image type
> manipulation
> 
> 
> >
> > Hi all,
> > I'm beginning to research the feasibility of
> creating a program to do some
> > rather specific image manipulation of .tif files. 
> Specifically, I want to
> > merge colour separations into a composite image.
> >
> > Can someone please suggest a resource where I
> might find algorithms, 
> > classes
> > or templates that would get me started?
> >
> > TIA
> > Vorpal
> >
> >
> > _______________________________________________
> > msvc mailing list
> > [email protected]
> > See
>
http://beginthread.com/mailman/listinfo/msvc_beginthread.com
> for 
> > subscription changes, and list archive.
> > 
> 
> 
> 
> _______________________________________________
> msvc mailing list
> [email protected]
> See
>
http://beginthread.com/mailman/listinfo/msvc_beginthread.com
> for subscription changes, and list archive.
> 



                
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses. 
http://promotions.yahoo.com/new_mail

_______________________________________________
msvc mailing list
[email protected]
See http://beginthread.com/mailman/listinfo/msvc_beginthread.com for 
subscription changes, and list archive.

Reply via email to