Modding:Creating Outfit Textures
This guide will cover how to make textures for your custom outfits.
Software
This tutorial requires GIMP and Blender, although you can use any program that can combine channels or save as DDS, such as Photoshop.
What looks good on a flat surface might not look good on a model. You ideally need some software that enables you to paint directly onto the model. Programs such as Blender’s texture paint mode, Armorpaint or Quixel Mixer or of course Substance Painter are worth looking into.
It is recommended to export a copy of the UV map so you can use it as a reference. With your item open in Blender, move to the UV Editing tab. Click UV, select Export UV layout. Tick All UV. You will now have a semi- transparent image to use as a template for your texture.
Overview
There are four textures in a generic armour item. Sometimes there are 3, as an item has no MSK and all the colour is on the BM, but it is easy enough to create your own.
Basecolour
This controls colour strength. It is flat and white or grey, as colours are overlaid on it via the MSK. The shader for the game is quite powerful so many BM are not very detailed. It will be called a BM if it has no transparency, and BMA if it does. The A stands for alpha, as transparency requires an alpha channel.
Normal Map
The blue transparent map. This makes the shading engine of the game bounce light off the item in a way that makes the object look like it has more depth than it does. The most important texture.
There are 2 types of normal map generally used. One, OpenGL, will look right side out. The other, DirectX, will look inside out (with things such as buttons going in).
BG3 uses a modified version of DirectX, where the red channel (X axis) is put into the alpha channel, as this saves space file formatting.
Channels:
Red - Not used, filled with all black
Green - Y (Green Channel)
Blue - Z (Blue Channel)
Alpha - X (Red Channel)
Physical Map
The physical map is 3 maps in one, combined into one image. Easy to spot, it will be pink, green and blue, or some combination of those colours.
Red channel: Metalness. Decides if an object uses the metallic shader or not.
White sections of this are metal. Black sections are not. You may wish to play around with this- most metal MSKs in the game are not solid white but instead have texture to to make the item more interesting to look at. Some non-metal items, such as gemstones, velvet and silk, also use the metal shader to add shine.
Green channel: Roughness. Decides what parts of the object are shiny and which aren’t.
The whiter this is, the more matte it is. Darkness adds shine. Add noise for visual interest.
If you make it too white you can get a bug where it becomes shiny.
Blue channel: Ambient Occlusion, a type of shading.
There are programs that will bake ambient occlusion for you, or it may be baked by your texture creating software.
If unsure, leave this pure white.
MSK
This decides what colour tints are overlaid via dyes and material presets, giving the outfit different colour choices. Look here for a list of the Mask Colours.
This is where the UV map template we exported is useful, as we can simply trace around the uv chunks to add colour and paste in with our bucket tool.
If you intend to make the entire outfit a solid colour, just make the MSK 4x4 to save space.
Make MSK files with Blender
You can make a MSK file with Blender by assigning each mesh the correct colour via Materials and exporting this as a texture.
How to open a texture and extract its files
First, extract textures from files with multitool.
Open these files in GIMP. Uncheck load mipmaps as you don’t need them clogging up the work area, and you are going to create new ones when you re-save it.
Reminder about exported textures
Textures do not export from virtual textures with mipmaps attached, which causes a static effect. Even if you are not editing some maps, you need to import them into GIMP and resave with mipmaps to generate new ones.
Physical Map
Open the physicalmap first. Go to Colours>Components>Decompose>
This should leave you with 3 seperate channels.
Save each as a PNG. (ensure it is uncompressed for best quality)
BM and MSK
You can just open and save the BM and MSK.
If the BM has transparency, you may wish to decompose the file and save the alpha channel seperately.
Normal Map
Colours>Components>Decompose> Colour model RGBA (this is very important- half the normal map is in the A channel)
Select the green channel, and. This should cause it to flip
Colours>Components>Compose>Select ‘RGB’ and put the layers in the slots.
It should become purple, and right side out.
This will export it as an OPENGL normal map. Save as PNG.
You can overlay PBR materials on it now.
File sizes
The textures need to be perfect squares, or perfect rectangles. This is because computers work to the power of 2 and prefer things that way. Not remembering this can make people’s games crash.
These rules don't apply to icon items, which go by their own rules.
The game's default textures for most items are 2048x2048 for clothing.
You can also have 2048 by 1024 and so on.
Example sizes:
4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096
8k textures aren’t presently supported by the game.
Lower than 4x4 pixels will cause the game difficulty, it will not accept a 1 pixel map.
Tools
Volno texture paint blender toolset
Bounding box software- materialise – For making Normal Maps from scratch
BG3 Normal Map Conversion Photoshop Actions- Automates normal map conversions in Photoshop