View Full Version : Beyond Photoskinning: Transformation and Displacement Mapping in Photoshop
5th Mar 2006, 3:22 AM
I've been playing with creating clothing textures for a while now, and I've come across a couple of really amazing tricks you can use to create more realistic clothing recolours without copy-pasting directly from a picture, using various "ingredients" from source material. This often creates a much better, more sim-like result than pure photoskinning, especially when one lacks a good enough source image of the clothing to be created.
I'm using Photoshop CS2, which includes all of the tools used here. Displacement Mapping is included in earlier versions of Photoshop (at least PS7), though Warp is not; those using earlier versions can approximate the effect of Warp by using Distort in small selections in combination with the Healing Brush.
The two main techniques we'll be covering here are Displacement Mapping and some of the Transformation modes. Displacement Mapping is a way to take a flat texture and warp it so it looks like it's laid over a contoured surface. Using the various Transformation modes (especially Warp mode) will allow you to stretch and shape a layer, and is incredibly useful in getting textures to fit just right on your mesh.
This is in no way a beginner's tutorial! These techniques are for those already successfully and comfortably using Photoshop and Body Shop, but would like some new ideas on how to use those tools to create clothing textures. You must have working knowledge of the basic tools within Photoshop to follow these directions. If you need help with Photoshop, try Google for some basic Photoshop tutorials. If you're new to creating clothing recolours, start with Faylen's first clothing tutorial. Please do not PM me with general questions on how to use Photoshop or Body Shop.
I like to use specific examples so you can see the techniques in use, so I've decided to redo a dress I made before that really illustrate these techniques quite well.
I love this outfit that Amanda wears on the front page of the official Dresden Dolls website, but the image is fairly small and doesn't have enough detail for me to use the picture to create a clothing recolour. So... I need to recreate it out of different parts.
This lace texture is fairly detailed, has a nice repeat, and looks close enough to the original floral lace texture. It's also got a nice contrast between light and dark, so changing it to the colours of the original dress should be fairly easy.
A quick Google Image Search brought up this gathered skirt picture, which has a nice level of contrast from light and dark.
And because it looks like that sash is a lovely dupioni silk, a little more GISing found me this flower girl's dress that'll work nicely.
5th Mar 2006, 4:30 AM
I've chosen to use this lovely a-line dress mesh by Lanfaer, which, though it has high heels, is otherwise perfect for this outfit.
Now, for a test pattern:
Why's my poor sim suddenly wearing a Technicolor Dreamdress? Well, that texture above is a result of applying this image (as a full-size texture) to the mesh:
You can see in the texture, all those lines are nice and straight, but when it's applied to the mesh, the lines are much thicker at the bottom of the skirt than at the waistline. If we were to use a texture that's the same size at top and bottom, it'd end up stretched out much larger at the bottom. I've noticed that effect on a lot of clothing recolours on custom meshes.
I often find it helpful to apply a striped texture like that to a mesh just to test to begin with (vertical and horizontal) to help identify areas of distortion I'll need to be aware of.
So... how do we make the texture the same size at top and bottom?
I worked my lace texture up into a nice big piece of "fabric" so we can have plenty to work with, and went ahead and gave it a colour that matches fairly closely the colours of the original dress. The actual size of this texture in Photoshop is about 2500 pixels wide. Always work bigger than you think you'll need to. ;)
To shrink the bottom of the lace texture while keeping the top the same size, Edit - Transform - Perspective and drag one of the bottom corner controls inward as shown to roughly compensate for the mesh's distortion.
15th Mar 2006, 9:27 AM
Now that we've got our texture in the right perspective for the skirt, we need to give it some shape. That's where that little black skirt I found comes in.
I've given myself a little more space to work with by enlarging the canvas size, and selected the part of the skirt I want to use for my texture.
Edit - Transform - Distort to be able to select each of the adjustment handles individually and pull them outward so the sides of the skirt are vertical as shown.
In later versions of Photoshop, you can use Warp to make finer adjustments to this selection. You can see how I was able to use Warp here to remove the curve from the top and bottom edges of the selection:
If you don't have Warp included as a transformation type in your version of Photoshop, you may be able to approximate the same look with a little more work using smaller selections and Distort.
As for exactly how to use the warp mode tool... the best advice I can offer is to just play with it. It feels very much like playing with wet paint. Don't be afraid to just play around and see what happens - you don't have to apply your changes. If you're trying to do something specific, you might also want to look at some of the presets and see where their corner and fine adjustment controls are set to for a specific result.
A few tips to remember when using transformations:
1. You can transform within a selection, so if a small part of your texture is off and you just need to squish or stretch it in a certain way, you can correct in very small areas if you need to using transformations (especially warp).
2. If you find you're not able to get exactly the result that you want at first, try applying your changes and then transforming again.
3. Warp mode will stretch/squish the area around the edges the most, and in the middle the least. This may or may not be desirable depending on what you're doing. If you find this stretching/squishing is a problem, try using Distort or Perspective instead.
15th Mar 2006, 11:31 AM
Now comes the coolest part of these techniques. We're going to make that lace texture take on the pleats of the skirt we just warped.
I usually work on top of a UV map for my recolouring... basic nude body UV maps are available for all ages and genders, but I personally like to extract the UV map for the particular mesh I'm working on, as there are usually variations, and it makes it quite a bit easier. Instructions on how to do so are available here. :)
Copy-paste both the adjusted lace texture and the adjusted skirt textures on top of the UV map. You can adjust the opacity of the layers to about 50% and drag them into place to get them lined up just right. Note how the skirt isn't right up against the edge of the lace layer beneath it. This is important.
Shrink the skirt layer by about a third horizontally, duplicate it, flip the duplicate horizontally, and erase the area they overlap to create smaller folds, closer together. Combine these two layers and then up the brightness and contrast of the skirt. This is because want a nice gradient from dark to light to get an accurate, realistic-looking effect with displacement. That plus a bit of adjustment to the skirt's height gives us the following:
Then, duplicate the lace and skirt layers and flip the duplicated skirt layer horizontally. The new skirt and lace layers move into place as shown. Combine the skirt layers and the lace layers to get this:
Desaturate the skirt layer and use the eyedropper tool to grab a grey from it. Create a new layer between the lace and skirt and fill it with grey.
Select all, copy merged, and paste into a new document. Flatten the layers of this new document and save it as displacement.psd.
Now, go back to the document with the lace, grey, and skirt layers. Delete the grey layer, as we won't be needing it again. Hide the skirt layer, and select the lace layer. Filter - Distort - Displace brings up a filter dialogue.
I've chosen a displacement of 5 here, but if you're working with a larger or smaller image, or if you would like a more dramatic effect, you can adjust this number accordingly. I usually undo and redo a few times till I get it just right.
Clicking OK on the first filter dialogue will bring up an Open dialogue. Choose the displacement.psd you just created containing the grey background and front and back skirts.
The result should look something like this:
That may not look too impressive, but look what happens once you make the skirt layer visible again, change it to Multiply, and play with the levels a little:
If you don't get a, "Ooh, that's all displaced" result like I have here, go back and change the settings on the displacement dialog - if you're using Stretch to Fit, change it to Tile, or if you're using Tile, change it to Stretch to Fit. The results you get with the different settings vary depending on whether the layer you're displacing covers the whole image or not.
It may take some playing with to get the levels looking just right, and I suggest you preview it with each change in Body Shop. I use a combination of Image - Adjustment - Levels, Brightness/Contrast, and Curves and usually just fiddle around until I get a result I like. Let's see how this is coming along in Body Shop:
There's still some unavoidable blurring and distortion toward the bottom of the mesh, but these techniques have corrected for it quite a bit. The preview is okay, but the texture's stretched a little... too vertical, not enough horizontal. Going back to our document, we can trim out some of the excess lace now, and adjust the width of the front and back of the skirts a bit. And since the levels look just about right, we can go ahead and combine the layers, too.
That looks better, doesn't it?
15th Mar 2006, 11:59 AM
I've skipped ahead a bit and gone ahead and made the texture for the tights and shoes. I've also added texturing to the top part of the dress and a little bit of shading beneath the arms and breasts on a multiply layer on top to give it a smidge more dimension.
I also did an alpha for it. The only thing left is to add the sash.
For that, we need the last picture, the green dupioni silk flower girl's dress. This picture was carefully chosen because of the subtle ripples along this rather drunken rectangle selected here:
Then that wobbly rectangle is pasted on top of the almost-finished texture. And because it doesn't fit exactly the area it needs to, we'll use some of the transformation tools to adjust it till it's the right shape.
For finer adjustments and tweaks, smaller selections and the use of warp mode can be extremely useful.
Duplicate the sash, shrink it vertically and expand it horizontally. Change the color to match the sash in the original photo, and add a nice fuzzy drop shadow to make it look like it's laying on top of the lace fabric:
And in Body Shop, it looks rather nice, doesn't it? Again, we're still experiencing a little bit of blurring at the bottom due to the mesh, but once everything else is in place, it draws the eye away from that quite a bit. Certainly, this is an improvement over simply covering it in the flat, uncorrected lace texture.
Cool Trick! If the result you have still looks a little too photographic and crisp compared to the rest of the sim-ish style of Maxis objects and the like, Try Filter - Noise - Despeckle. It can sort of smooth things out and takes away the harsh edge of certain images.
In the game:
26th Mar 2006, 8:24 AM
Here's a couple more examples of some simple clothing items made with these techniques:
And here's my test patterns, in case you'd like to use them yourself (right click the link and save target as to get the full 1024 version). We control the horizontal and the vertical.
If you have any interesting items you've made using this technique or have discovered a nifty trick related to the techniques shown here, please share! If you have trouble with Photoshop, there are tons of websites with tutorials on every aspect of Photoshop... just Google what you're trying to do.
If you'd like to download the dress from this tutorial, you can get it here.
2nd May 2006, 12:33 PM
Wow, Thank you for this! I'm still a beginner but this will come in handy :D
29th May 2006, 2:53 PM
Thank you very much! It's very useful indeed! Awesome! :)
15th Aug 2006, 7:16 PM
Thank you! I have thought many times while creating my skins I needed a feature like this, but I didn't even know it existed. Displacement map is the exact thing! It will be very useful for me from now on, I'm sure.:) I didn't know much of the warp possibilities, either. This tutorial was really of great use. ...And thanks for the downloadable test patterns, it would possibly take some time before I figured out how to make my own;P ...Hrm, btw - I hope it's not off topic - how do you make them? Is there any quick filter/option or you do it manually by nudging a rectangular selection and filling with different colors?
15th Aug 2006, 9:16 PM
I'm sure it wouldn't be difficult to create one's own text patterns with rectangular selections and nudge. Mine were actually made from a picture I found of some brightly-coloured fabric that I just adjusted to tile several times over the 1024 image and scaled to my liking. :)
I also use the template attached at the bottom here (in the zip file) with semi-transparent colour overlays a lot... http://www.modthesims2.com/showthread.php?t=135136
27th Aug 2006, 1:53 PM
This tutorial has really changed the way I approach skins. Transformation and perspective help me get the look I want. I started doing displacement the way you do here, but either the Gimp does weird stuff with them or I do weird stuff to them, so I adapted it to something that works for me.
I cut up and transform a picture as you describe, for each part of a garment. Sometimes I uses desaturated maxis bits and sometimes I hand paint them. I desaturate the items I'm using and play with lightness, brightness and contrast until they match, use a low opacity eraser to get the edges right then I merge them into a master layer and use different blend modes with fabric or color to get the base garment I want. Then I add details, etc.
The dresses here (http://forums.modthesims2.com/showthread.php?t=184392) andhere (http://forums.modthesims2.com/showthread.php?t=186240) are examples of clothes i made using this method.
Anyway, this has been a long winded way to say Thank You for this. It's been incredibly useful to me.
12th Dec 2006, 7:12 PM
hey thanks! I really needed this information. :0)
22nd Mar 2007, 6:19 PM
Does anyone work with paint.net? Right now, all I am able to do is recolors, but I'd love to recreate my marching band uniform for my university sims. I don't remember seeing some of those editing features on paint.net. As you can judge from my avatar, I am still pretty new to photoshopping (although I am proud of those sunglasses that I created from scratch).
I also want to create more clothes for my poor guys who are almost constantly bumping into npc's wearing the same outfits...okay, not always, since I use some custom outfits, but still...
3rd Jun 2007, 2:37 AM
this is a wonderful tut. i need to play with the levels more though because it came out looking very dark and too flat :(
28th Jul 2007, 6:54 AM
I have a question..
Is this in effect the same thing as making a bump map, just doing it differently or is this different?
I have read the tut on making bump maps, and it is very technical, I find it hard to understand...So I was just wondering if this is another way to create that 'textured' look for sims clothes.
28th Jul 2007, 7:17 AM
didadragonfly, this isn't the same thing as bump maps. Bump maps create the illusion of actual 3d parts, adding highlight and shadow to make it seem like a button is actually raised off the surface, that the edge of a hem is raised where it overlaps the top of a skirt, etc. However, many graphics cards can't view bump maps so they're really only a bit of added detail. This technique can work well in combination with bump maps... you can use a modified version of your displacement.psd document as a bump map (you'd want to reduce the contrast and lighten it some from my example and add detail for the top and sash and stuff too). There's a tutorial on making bump maps 'round here somewhere too.
10th Aug 2007, 6:14 AM
Pretty interesting. I totally screwed the dress but your displacement method worked very well for me. It's quite cool! I love discovering new Photoshop techniques. I'll keep your technicolor jpegs as testing tools.
Thank you for this!
7th Sep 2007, 4:34 AM
Thank you so much for this! It really helped me out, I've always wondered how to do that. Turned out to be the most beautiful dress I've ever made :D
19th Dec 2007, 9:37 PM
I've been sadly/hopefully reading these tutorials for ages (Paint.net), but now I have photoshop "Giggles" and all is magically possible. I had a go at this and did it! Yippeeee. I hope I get some sleep... Thanks so much to you and all the others for these great tutorials I can now devour. :)
23rd Jan 2008, 6:57 AM
you're a photoshop god! I'll try this when I've slept! xD
Thank you so much!
27th Jan 2008, 7:00 AM
Thanks for the tutorial! I'm sure it will be very helpful. I'm curious as to what you typed in the search box for google. I've been looking for quite some time now & haven't been able to black skirt or the sash.
27th Jan 2008, 8:40 AM
ang - It's been forever so I don't remember precisely but stuff like "pleated skirt" or "pleated" or "box pleat" are good for skirt type stuff, and for the fabric, I think "dupioni silk" or something like that. You won't get the same results now as it's been so long but I generally find really specific keywords (and then just trying a bunch of variations) is the best way to shake stuff out of GIS. :)
27th Jan 2008, 11:44 PM
Ok, thanks. I tried using "gathered skirt" and found some that were similar, but too small in size. Finding the right size image can be a pain sometimes.
Starfish of Terror
22nd Mar 2008, 5:38 PM
HP, I have something to confess. I love you. =o This is such an amazingly helpful tutorial! I've been skinning for a bit and have been becoming increasingly frustrated. Trying to skin an entire outfit from a photo looks terribly fake, and just using textures looks way too bland and flat. This way, I can use the textures that I've been wanting to use and morph it into gaining the folds, etc. that I've been wanting. Thank you so much, I can't wait to try this out! :]
10th Jan 2009, 2:38 PM
Thanks I'll remember this for future.
21st Apr 2009, 10:09 PM
Anywhere we can get UV maps w/out SimPE?
23rd May 2010, 4:27 AM
It really sucks to look at a tutorial that keeps referencing photo's as part of the tutorial and they aren't there. What happens to them? I have looked at so many tutorials on MTS and I'd say a good 75% have missing photo references. Does vBulletin eat them for lunch after a specific interval of time?
24th May 2010, 6:28 PM
Yeah. I also wonder, just like Javier! A loads of "older" tutorials images isn't there. And it's so irritating. When you finally find something you found looking interesting, and nope. It's nearly impossible to learn without images that should be there, but aren't.
27th Dec 2010, 4:33 AM
This tutorial didnt help like i expected especially since the pictures didnt work. ive looked for videos but none are what ive been looking for. i guess ill stick with making make up even if i cant figure out how to upload them. thanx anyways :faceslap:
17th Oct 2011, 11:25 PM
Hi! I'm reading this in 2011.I used to play sims 2 a lot,and loved it,loved all the downloads from this page...
Now I want to reinstall it (someday...) and start to learn how to create things for the game, and I must say...
It's such a shame the photos of this thread can't be seen.
It scares me a lot to think that all these great tutorials disappear when I start to get interested in them. :(
I don't think you can fix all the images again...but if you read this,and can do something,
I ask you to do it,please.
(PD: Sorry for my bad English,it's not my language :S)
(PD2: you can see I've just registered,that's because I forgot my old username XD but i've always been a fan of mts).
18th Jan 2012, 8:09 AM
Yea, and nobody seems to answer about the missing pictures *Ugghhh.*
20th Mar 2012, 8:12 PM
Yea, and nobody seems to answer about the missing pictures *Ugghhh.*
it's the same thing with me, I'm new to creation, and there's a lot of things I don't know and can't learn because the tutorials are missing or they're no pictures.... is there anyway the pictures can be reuploaded? the tutorial is impossible to follow without them.... :cry:
11th Jul 2012, 9:42 PM
Yes, I also think there is something wrong with the pictures T_T If you can, please fix it. Pretty please?
vBulletin v3.0.14, Copyright ©2000-2019, Jelsoft Enterprises Ltd.