Texturing in 3DS Max.
-
Mapping the texture in place:
Double check all your steps first. Have you done everything correct up to the last paragraph? Are you sure? Are you REALLY- sure? Excellent. Lets carry on.
Mapping textures comes AFTER you finish applying all the textures to your mesh as you want to. In order to map textures on a mesh, you need to first open the unwrap UVW modifier from the modifier list on the right hand menu. Scroll down in the dropdown list till you see the option, then select it as shown below:
REMEMBER TO EXIT POLYGON MODE OR ANY OTHER MODE BY RE-SELECTING THE APROPRIATE ICON BEFORE YOU OPEN THE MODIFIER OR TEXTURING WILL NOT WORK AS REQUIRED.
http://i84.photobucket.com/albums/k13/gurjiv/admin/18.png
Notice when you open the unwrap UVW modifier, you can see the textures applied to the mesh, but they seem to be stretched/distorted etc? This is because the textures are only APPLIED, not MAPPED. We need to do the mapping for each face, and this is what the UVW modifier allows us to do.
Once youre in face mode, begin to select the first face(s) you wish to work on/map textures for. I decide that i want to map the green textures surrounding the windows _http://i84.photobucket.com/albums/k13/gurjiv/admin/19.png
Hitting the quick planar map button after selecting your faces and selecting the averaged normals option will automatically map the texture for you without any distortions/stretched faces etc, HOWEVER, it does not necessarily mean it mapped it in the correct rotation as you want it, or the size you want it to ideally be. It only maps the faces to the size it should be, nothing more, nothing else, but is an extremely useful tool nonetheless. Youll use it often. Sometimes the texture may not map properly with the averaged normals option, just experiment with the x, y or z axes then till it works.
To ensure that the texture rotation is to the standard you want, and is the size you want, you need to hit the edit button, which opens a new window displaying the texture, and the faces selected on it.
http://i84.photobucket.com/albums/k13/gurjiv/admin/20.png
The triangle button next to the dropdown, when selected, will only display the selected faces from the viewport in the window. Very useful if the window gets rather cluttered/messy (which it may at a later stage). The 4 buttons at the top left corner of the window are for moving, rotating, scaling, and freeform mode. Youll mostly be working in freeform mode, but you may from time to time need to use the other modes as well. For example, in this situation, i need to rotate the selected faces map co ords, so i select the rotate icon, and rotate the faces by clicking, holding and dragging around in a circle till i have the faces lying in a desirable direction. In freeform mode, i select one of the corners, hold down control, and drag the corner outward to increase the size. Holding down control means the size increase will remain in the same shape as before, no distortions.
http://i84.photobucket.com/albums/k13/gurjiv/admin/21.png
As you can see, the selected faces now have correctly mapped textures, which means youre ready to move onto the rest of the models. From here on its basically a repetition of this step again and again until youve mapped the textures on every face of the mesh.
http://i84.photobucket.com/albums/k13/gurjiv/admin/22.png
–-----------------------------------------------------------------------------------------------------------
Finishing up…
Once youre finished texturing, you need to complete the final few steps before you can export the model to create the CMP/inclusion into the mod.
To complete the mesh, you need to use of the symmetry modifier. Making sure your unwrap UVW modifier is now deselected (the yellow highlight should be grey), go to the modifiers list, find the symmetry modifier, and open it. Select the axis which will correctly complete the mesh, and mirror the mapped texture co-ordinates as well.
Having done that, right click on either modifier, and click the option collapse all to make the changes permanent, save copy as to ensure youre work is saved.http://i84.photobucket.com/albums/k13/gurjiv/admin/23.png
A word of warning. i should have mentioned this before, but i forgot to, so please forgive me. ill be keep on adding onto this tutorial as i remember what else i miss/anything of interest/to make stuff easy for you.
Mapping textures also means moving them around in the new window which opens after you hit the edit button, so that they LOOK good as well. clear example:
http://i84.photobucket.com/albums/k13/gurjiv/clampz.png
as you can see there, the textures are all mapped correctly, but not placed in a way that they are aesthetically appealing to the eye. this is why it is crucial to have a second opinion, since someone else can help pick up what you miss. furthermore, as you can see, many of the textures have abrupt edges- one texture ends randomly just as soon as another one starts on another face. this is a problem as well.
http://i84.photobucket.com/albums/k13/gurjiv/test.jpg
now, here is another example.
number 1= distorted, unmapped/wrongly mapped faces.
number 2= correctly mapped, correctly placed (so the textures are “understandable/fitting” so to speak)
number 3= correctly mapped, not placed (just hit “quick planar mapping and left it at that”
number 4= applied the textures, did nothing to them (since you had done some mapping, it had save the co ords)the top square (inner part) on number 3 shows what happens if you hit planar mapping, but do it along the wrong axis. this is something you have to judge on your own- which axis does the planar mapping thingy produce best looking results ( i didnt do the border around the top part, just the big middle one for 2). As you can see on 2, you notice how i placed the panels so they have an equal amount of border on all 4 sides and when i do the trimmings, it doesnt seem random anymore, but fits in? thats the stuff you need to do not just map it and leave it be.
Symmetry modifier:
This tool can be utilized both during texturing as well as modelling. a clear example is the gallic trade lane. i built 1/4th of the model, then using the symmetry modifier, i mirrored the mesh in all 3 axes, giving the final result which i posted in the thread for the trade lane. clear example:
before i used the modifier
http://i84.photobucket.com/albums/k13/gurjiv/before.jpgafter i used the modifier
http://i84.photobucket.com/albums/k13/gurjiv/after.jpgThis is a trick many modellers (even DA) used, so i dont see why you lot cant use it as well.
-----------------------------------------------------------------------------------------------------------_
-
The next step, you can either do however you are used to doing it, or you can use my tutorial + tools to do it, it doesnt matter. in the case of stations/bases, as long as the model can be sur spliced for hitboxing etc, its not a problem.
================================================
Preparing the CMP for exporting/ Sur splicing.
Right. I thought if im going to write the tutorial explaining how to texture, i might as well go all the way and explain how to prepare the CMPs for Sur splicing. Problem is, its kind of hard to explain with words, but i will try my best to explain it as simply as i possibly can.
Preparing the groups:
Right. This part requires a bit of your own judgement and decision making. You need to look at your model, and rightly guess how many different CONVEX primitives (ie boxes/cylinders etc) will it take to make a fully fitting, as accurate as possible hitbox for your model. Bear in mind, if you are creating a station etc, you have not got any other choice but to use the Sur splicing method to create the hitbox anyway, so youll have to go through all of this process anyway.
Looking at this model, i approximate that it would take me about 14 primitives to hitbox, assuming i wish to make the hole in the hitbox like the mesh has if you can spare mesh groups , then go for it, but remember, the hitbox must cover 100% of the ship before you worry about details for the hitbox. The next step involves breaking the model up into 14 groups accordingly.
http://i84.photobucket.com/albums/k13/gurjiv/admin/24.png
REMEMBER: due to the way the cmp exporter is currently setup, we are limited to 18 mesh groups per cmp. There ARE ways to pass that limitation, however, that requires alot of work, and ill let you master the basics before i begin the next step for obvious reasons.
To split a mesh in 3ds max into different groups, you need to make sure your model is already an editable poly. Once you make sure, you need to go into polygon mode, and start selecting ALL the faces you wish to detach from the main group to make a new group
http://i84.photobucket.com/albums/k13/gurjiv/admin/25.png
As you can see in the image above, after you select all the faces, you need to hit the button on the right hand side option set called detach. It will open a new window prompt, asking you to give the detached mesh a new name. MAKE SURE YOU GIVE IT A SENSIBLE, UNIQUE NAME. Do NOT call it box 1, instead try something like… central body. Furthermore, AVOID USING NUMBERS WHEN NAMING THE GROUPS. I will explain why further on.
http://i84.photobucket.com/albums/k13/gurjiv/admin/26.png
As you can see, i ended up with 15 groups. Remember, the initial approximations do not necessarily have the be exactly how it turns out- that depends on how you wish to split the mesh up, as long as the hitbox which you make covers the mesh as best and as accurately as possible.
The next step is for you to download this script, and put it in the Scripts folder for your 3ds max 9. While youre at it, download this obj exporter for 3ds max (this is slightly different than the wavefront obj exporter, but works 100%). To install the exporter, just drag the icon into one of your viewports and drop, it should automatically install it.
http://www.mediafire.com/?g2wzjmzuzdz
The next step is important, pay attention. You need to re-arrange the groups there according to how they are connected. Remember, the each mesh you group must be connected in some way to another group, and as such you need to set them up in the window. Now, Click on the button on the top tray that when highlighted says Schematic view. This button is on the left hand side of the material editor button. Once open, youll see a new window with loads of blue/purple coloured buttons. As you can see in the image below, ive re-arranged the groups properly so each group is touching the next group in the cmp
http://i84.photobucket.com/albums/k13/gurjiv/admin/27.png
Before you do anything, you need to press the button called connect (third button on the tray), followed by the hierarchy mode button (sixth button on the tray. Once youve done that, you need to click on the blue button on the right hand corner (in this case, exhaust three), drag your mouse whilst clicked onto the next blue button (exhaust two) and drop once your mouse is above the exhaust two box as shown below:
http://i84.photobucket.com/albums/k13/gurjiv/admin/28.png
You will need to do this from right to left for each box, so you click, drag and drop onto next box, then from the box you dropped on, you click, drag, and drop onto the next box until you have something like this:
http://i84.photobucket.com/albums/k13/gurjiv/admin/29.png
Next step involves using the plugin you just downloaded from me. Close the schematics window, click on the option called MAXscript, click on the option called Run script, it will open a new window. Select the script that is called detachbyID, and click open. This will open a new window. MAKE SURE YOU HAVE THE SAME SETTINGS AS I DO AS SHOWN IN THE SCREENSHOT BELOW:
http://i84.photobucket.com/albums/k13/gurjiv/admin/30.png
If everything is as it should be, youre ready. Click on DETACH button. This script will detach the meshs groups and prepare the cmp to be just like how the cmp would be in milkshape (3ds normally doesnt do this due to being far superior than milkshape etc, but using this script will help you when you export your model to milkshape to prepare the cmp)
What you end up with after detaching is a multicoloured mesh. Click on the schematic view option again, and youll notice instead of the initial 15 groups you had, youll have alot- more now. What this script has done is it has split the mesh up into subgroups per mesh. In milkshape, you get groups based on what texture is applied per face. This script has done exactly that, split up the sub groups inside each mesh according to the textures applied to the faces, but it has kept your overall 15 groups total. (this bit may be a bit hard to understand, and i cant exactly word it properly, if you still need further assistance understanding this part hit me up on skype [Gurjiv.singh is mine, afaik] and ill try and explaining it as best as i can).
What you need to do is re-arrange the groups again if need be ( i will have to) so that each subgroup is grouped together before you move onto arranging the next mesh. Hopefully the screenshot will be able to explain better:
http://i84.photobucket.com/albums/k13/gurjiv/admin/31a.png
http://i84.photobucket.com/albums/k13/gurjiv/admin/31b.pngAfter you re-arrange the groups, you do the same step as before. You select the connect button, then hierarchy mode button, and from right to left, start connected all the groups again. Close the schematics mode window once youre done connecting.
http://i84.photobucket.com/albums/k13/gurjiv/admin/32.png
Congrats. Part one of the tedious journey is complete. Next, you need to export the mesh for the second step to creating the cmp via milkshape. Click on file -> export, and in the options, select the new obj format (youll see it right below the wavefront obj option in the dropdown), give it a name, and click export. When you do so, youll see a new window opens up. Make sure the settings are EXACTLY THE SAME as shown in the screenshot below:
http://i84.photobucket.com/albums/k13/gurjiv/admin/33.png
http://i84.photobucket.com/albums/k13/gurjiv/admin/34.png–---------------------------------------------------------------------------------------------------
Exporting to Milkshape, then exporting as a CMP
With the mesh now exported as an obj, you can save your work (remember, save copy as) and close down 3ds max 9. The rest of the work involved will be done in milkshape.
Open milkshape. Click file -> import, and click the option wavefront OBJ. Select the file you have just exported from 3ds max. Hopefully the model will open with all of its groups, texture mappings etc intact as it should be. Remember to re-orientate your model accordingly (for example, i had to rotate the model after i selected everything [control + A] along the x axis, 3 times by 90 degrees [or once, -90 degrees], whichever strikes your fancy).
Once you rotate the model, you should make sure it is centered correctly. With the model selected, click the move button. In the dropdown, change the option from relative to absolute, and hit move. This should ideally ensure your model is centered correctly.
Open the textures you have applied to the mesh. Click on the materials tab, and you should see the names of the textures you used. Check the next screenshot explaining what to do next:
http://i84.photobucket.com/albums/k13/gurjiv/admin/35.png
Make sure your model is scaled/sized as you wish it to be before you prepare it to export the cmp. Once you do that, and are happy with everything and just want to get on with exporting the mesh as a cmp, you need to do the following.
Due to the cmp exporter being kinda broken, the scale down option
doesnt work. The way ive learned to negate this is by scaling the model uniformly along the origin by 92 along all 3 axes. In order for you to do this, press control + a, selecting your entire mesh. Click the scale option, and for all 3 axes, change the value from 0.0 to 92, and change the checkbox option from center of mass to origin, and hit scale.http://i84.photobucket.com/albums/k13/gurjiv/admin/36.png
Remember you did all that group splitting up in 3ds max? Well, nows when it becomes important. Grab a paper and pen, and get ready to do some counting and jotting down numbers.
Click the option called groups, and in there you should see a list of all the groups you have. Remember, in the end before you exported the mesh in 3ds max, i had a grand total of 15 different mesh groups. So you KNOW that youll have 15 meshes in total, but the number of sub groups per mesh will vary. Go through the list from top to bottom, jotting down how many groups are per mesh.
Going by my example, this is how i count them:Nose_tip02 = 1
Nose_top02= 1
Center_main02 = 1
Nose_bottom02 = 1
Nose_fin02 = 1
Center_behind02, center_behind03, center_behind04 = 3
Top_towers02-1
Center_bottom02 =1
Central_body02=1
Bridge_top02= 1
Bridge_bottom02= 1
Engine02=1
Exhaust_one02=1
Exhaust_two02=1
Exhaust_three02=1As you can see, there are 15 total groups, but the number of SUBGROUPS varies per mesh. (the reason there is mostly 1 for all of the meshes is because i never really textured the model completely. Had i done so, id have a different value than 1 for all the mesh groups, something like the mesh called center_behind, which has 3 subgroups. Now that you know how many sub groups there are, you can prepare to export the cmp.
Click on file, export, export as cmp. This will open a new window. Click the new button, to make a new cmp, give it a unique name, and click okay. Click on the back to front orientation. Where it says number of groups, change that to the number your model has (in my case, 15, so i change it accordingly). In each of the group quantities, you change the values to however many sub groups are per mesh. I will show this in the screenshot below.
http://i84.photobucket.com/albums/k13/gurjiv/admin/37.png
http://i84.photobucket.com/albums/k13/gurjiv/admin/38.pngAfter you export it, when you open the cmp via hard cmp, if you did everything correctly, youll have a proper cmp ready for sur splicing to hitbox.
–----------------------------------------------------------------------------------------------------
Thats the end of it. questions/comments/criticism/flames (hopefully none ) welcome
-
Pictures in the first post are not working…
-
Excellent work, frozen
Any chance of you to upload this as a .pdf so we can download it?
-
I’ve been busy with a wedding for the past week now, hence me not paying attention. I’ll get you the .PDF version done tomorrow and posted here asap (not home atm), and ill fix the links as well.
glad people find it useful.
-
It’s an awesome tutorial, FB. Well done man and thanks for taking the time to write one.
-
StarTrader wrote:
Excellent work, frozenAny chance of you to upload this as a .pdf so we can download it?
heres your .PDF. apologies for delays, been caught up with stuff.
-
Very many thanks!
-
@frozen:
I downloaded the importer pack for obj but it doesnt work.
The scripts are ok, but the dle files dont want to cooperate. I tried to drop them into a viewport, also tried to copy them into stdplugs, and plugins dirs, but when i start 3dsmax it says: “failed to initialize” (gw_objio.dle), i tried all of 3 versions of this .dle, i got same result. -
sorry for the late reply mate, been busy with uni etc.
what version of 3ds you using, 9 i presume?