PDA

View Full Version : Photo mapping



soundview
03-23-2006, 08:11 AM
This may be a newbie question but I need help.

I am doing a projection map of a photo on to a single polygon. I want to make the white borders of the photo transparent so another object can be seen behind it (just the large borders). Can I do this with transparency mapping or such?

flakester
03-23-2006, 12:28 PM
Howdy Soundview.

Yes you can do that with transparency mapping.
Everyone has their own ways, this is how I would take my sorry head around a solution.

Take the photo into photoshop, magic wand or subtractive selection on the border, make a new layer. Fill this selection with black on the new layer.

Turn off visibility of the original image layer. Save as a new image.

Sorted.

Well, kind of..... I keep forgetting which way round LightWave likes it's blacks and whites to use as trans maps, but you can always invert the image in LW if I've told you wrong!!

Saying that, by the time I've finished typing this, you've probably figured it out anyhoo! :P

Hope that helps.

flakester.

fgreen
03-23-2006, 01:23 PM
If I'm understanding your question, the easiest way would probably be to create to a clip map which would clip out the 'border' part of the poly.

A second method, also requiring an image editor, would be to create an alpha chanel for the white borders in photoshop (or another image editor), then select 'alpha' as the blend mode. The border part of the projection would then drop out showing the polys color. Use the same alpha for a transparency map.

If you don't have an image editor the only way I can think of is to cut the poly so you end up with a smaller rectangle poly within the original. Then adjust the scale of the projection image a little larger until the white border is no longer visible. Set the 'border' polys to 100% transparency.

soundview
03-23-2006, 02:29 PM
I think a clip map is what may be required. I'm not sure how to do this.

Basically, I have a potrait in photoshop that was saved with white border in one file and no background in another file. I have to map it onto a poly that cannot be changed. The original portrait has an aspect ration of 3x5 the poly is more like 5x3. I cannot rotate the poly. Automatic sizing distorts the original photo. I can't get the white background to drop out.

I think it may be an easy solution but I am not versed in lightwave and the deadline approaches quickly. Many thanks for your suggestions!

fgreen
03-24-2006, 07:02 AM
In photoshop save a copy of the protrait image. Save this as your clip map


Paint everything you want to be visible black. (0,0,0 rgb)

Paint the white border white (make sure it is totally white, 255,255,255 rgb). You may want to use the selection/fill technique mentioned above by Flakester to do this easily.

In LW surface editor/color/texture/texture-editor-panel manually size your portait image using the scale values. When it looks right, copy the texture (button at upper left of texture editor)

Exit out of the surface editor

In object properties under the render tab you will see the Clip Map "T". This takes you into another texture editor panel like the surface editor. Paste the texture copied from the surface color. (this will ensure that the size of the clip matches the border on the portrait.)

Under the Image dropdown, load your texture map (don't resize).

Click "Use Texture" to exit the Clip Texture Panel.

You should be good to go.

soundview
03-24-2006, 08:09 AM
I have tried the clip map method and it clips lighter parts of the photo as well.

DrTWT
03-24-2006, 09:26 AM
I use transparency maps.

Attached is a content folder that has a set-up using transparency maps. There are 3 polygons~ one with no trans map, one with 50%, one with 100%. If you play around in the surface editor and look at the maps this should be straightforward (I hope).

You could also get the different levels of transparency by changing the layer opacity of the trans maps.

hope this helps.