So as far as I understand it, the workflow for creating icons is a little strange. Strange because it seems the best way to map your icons to your atlas is by using the single images, but you have to pack them beforehand.
Preparing the Texture File:1. Pack a collection of images (64x64) into a single image file using power of 2 constraints (512x512, 1024x1024, etc.). Make sure to have the images sorted by name.
2. Convert the image to DDS, with alpha and BC3 compression.
3. Move that DDS file to a location inside your mod's directory, inside the data directory. I moved mine to
"Data/Public/MyModName_GUID/Assets/Textures".
4. Inside the editor, add that texture to a package in the Resource Manager (I created a package called Textures).
Preparing the Texture Atlas file:1. Open the Texture Atlas Editor.
2. Click File -> New.
3. Select a location for your .lsx file (I put mine in
Public/MyModName_GUID/GUI).
4. Select the DDS file as the texture.
5. Select the size of the individual icons and the size of the image.
6. Select the package you created previously, then click Save.
7. Important: If you get a "That file is already exists" error, move your DDS texture file out of where you placed it, run through the steps to create the atlas file, then move the DDS file back in and re-open your atlas file. This bug seems to exist because the Texture Atlas Editor was originally suppose to make the DDS file itself, but doesn't actually do it right now.Adding Atlas Entries:1. Click Edit -> Add Entries.
2. Navigate to where your collection of single images is.
3. Select all the icons you packed and add them. If you packed your texture right (alphabetically), all of the new atlas entries should match up with the image.
4. Save.
Notes:○ I used
TexturePacker for packaging my icons. Here's my settings:
○ I used
nvidia-texture-tools to convert my image to DDS. I just converted it as a single file. This could be optimized for a more "drag and drop" approach with a batch file. The command I used was:
nvcompress -alpha -bc3 Icons.png Icons.dds
○ TexturePacker has support for a custom exporter data format, so it's possible we could create an exporter for DOS2's atlas format, and skip a few steps.