So i'm making textures and I was running into a huge problem: the default.settings file in the uncompressed effects folder converts the textures to huge file sizes (they look great though). So i was looking around for a better default.settings, and I haven't been able to find the perfect one yet. I need a great balance between file size (less than 1MB for diffuse is preferable) and quality. I have been using this for mobile units Code: texture-max-size: 512 Everything else is 1024. There doesn't seem to be anything around that says what the best one is @bgolus
Code: C:\Users\Eoin>"C:\Program Files (x86)\Steam\SteamApps\common\Planetary Annihilation Titans\bin_x64\tools\papadump.exe" "C:\Users\Eoin\AppData\Local\Uber Entertainment\Planetary Annihilation\server_mods\com.pa.legion-expansion.server\pa\units\land\L_storage\L_storage_diffuse.papa" 1 texture: 0: name: "/pa/units/land/tank_light_laser/L_storage_diffuse.png" format: TF_DXT5 width: 256 height: 256 mips: 8 srgb: 1 0 vertex buffers. 0 index buffers. 0 materials. 0 meshes. 0 skeletons. 0 models. 0 animations. Well I got this from a few tiny textures and it seems like this is the best setting. But I'm very confused as to how the wireframe is so high resolution... that just doesn't make sense. THe wire is almost perfect yet the texture is tiny. wtf? Is the wireframe calculated by the game?
Do you mean the build preview wireframe? I believe that is calculated by the game using shaders, similar to pinbender's puppet example, on which I based an emulation of the build preview
I figured out that the diffuse layer needs to have a grey background (133,133,133). The wireframe is placed onto the diffuse layer and this color seems to be the best. Not that anyone will need to know this.
The best texture resolution depends on the unit. There are no real guidelines, just set the max resolution as low as you can get before you notice it. Most of the unit textures start to fall apart when you get too close because they're not really intended to be seen from those distance. Also the wireframe is done in shader using the inner glow as a dirty approximation of a distance field. Signed distance fields are pretty much the defacto standard for font rendering in games, and it gets used elsewhere as well because you can get very sharp details with very few pixels.
Does that mean TEMP_texelinfo is a ratio between the texture size and the unit size? On a related note, if you are trying to control how the wireframe appears, you may need to adjust TEMP_texelinfo. In my emulation that was pretty much the perfect number to plug in to make it look good for any buildable unit (some commanders are weird)
If I remember the final iteration of that correctly it is roughly the average UV coverage distance / (128 / 2048). I had something in the export utilities that spit out the correct number to put into the .json file, but most artists ignored it so most commanders got ignored. Plus it wasn't super accurate so some units needed a lot of hand tuning (like all of the Titans). I actually had a way to do it more accurately late in development of Titans, but it wasn't worth redoing all of the units for it. Also it was called TEMP_texelinfo because it was supposed to get handled automatically on import, but I never got a graphics programmer willing to spend the time for that.