NoMansSky:Texture Formats: Difference between revisions

From Step Mods | Change The Game
m (Text replacement - "\[\[Category:NMS-Index-.*\]\]" to "")
 
(25 intermediate revisions by 3 users not shown)
Line 1: Line 1:
__NOTITLE__
{{#set:
{{NMSPage|contentTitle=Reference Guides // TEXTURES // Texture Formats}}
NMSIndex=Textures
{{TOC_right}}
}}{{PageTitle|logo=nomanssky|title=Texture Formats|author=Lo2k}}
{{NMSPage}}
{{TOC}}
== Texture Formats ==
== Texture Formats ==
No Man's Sky uses mainly [https://en.wikipedia.org/wiki/DirectDraw_Surface DDS images] as texture maps but also accepts formats such as PNG, JPEG, and PSD as per [http://www.horde3d.org/docs/html/_formats.html Horde3D specification]. As such, it is highly recommended to use the Nvidia DDS plugin for Photoshop, GIMP, or any image editor of choice with DDS file handling capabilities.
No Man's Sky mainly uses [https://en.wikipedia.org/wiki/DirectDraw_Surface DDS format] to encode its textures but can also accepts some other formats such as PNG, JPEG, and PSD as per [https://www.horde3d.org/docs/html/_formats.html Horde3D specification] (to be confirmed). As such, it is highly recommended to use the [https://software.intel.com/content/www/us/en/develop/articles/intel-texture-works-plugin.html Intel Texture Works plugin] for Photoshop, GIMP, Paint.net or any image editor of your choice with DDS file handling capabilities. You can find the related Tutorial about editing .DDS textures [https://stepmodifications.org/wiki/NoMansSky:Tutorials/HowToTextures here].


Due to the way shaders have been written, the arrangement of textures overall differ from what is more commonly known in other game engines. The most commonly used shader is called the Ubershader and functions similarly to Unity's Standard Shader (physically-based rendering) but with a few differences as discussed below and in the [[NMS:Reference_Guides/MATERIAL_Files|MATERIAL]] page.
Textures are called by [[NMS:Reference_Guides/MATERIAL_Files|Material description files]].


== Accepted Texture Maps ==
== Accepted Texture Maps ==
=== Diffuse Map ===
=== Diffuse Map ===
The basic diffuse is practically the same as a basic 2D texture in most engines. The map contains RGB data containing the albedo colors for your object's texture. It is important to take note of the way channels are read by shaders.
This texture stores main object colors.
* RGB channels - color information for your albedo map.
* RGB channels - color information for your albedo map.
* Alpha channel - this channel is used for metalness, transparency, and emissive textures.
* Alpha channel - this channel is mostly used for transparency but could also be used for metalness or emissive areas. As such, you can't have a texture that is transparent and emissive for example.
*: All these material flags are read from the same channel; as such, you can't have all of these flags running at once.


=== Mask Map ===
=== Mask Map ===
Line 19: Line 20:
* Green channel - a gloss map is used here. Despite the material settings specifying this should be a roughness map, the way they look in the textures implies it's really a gloss map, basically an inverted roughness map.
* Green channel - a gloss map is used here. Despite the material settings specifying this should be a roughness map, the way they look in the textures implies it's really a gloss map, basically an inverted roughness map.
* Blue channel - has something to do with detail textures but is largely unused for most models.
* Blue channel - has something to do with detail textures but is largely unused for most models.
*: This channel appears to be for determining where custom colors are applied while base building
*: This channel appears to be for determining where custom colors are applied for base building items :
*:* White - receives primary color
*:* White - receives primary color
*:* Grey - receives secondary color (#7b7b7b has been used successfully)  
*:* Grey - receives secondary color (#7b7b7b has been used successfully)  
Line 26: Line 27:


=== Normal Map ===
=== Normal Map ===
As of the ''NEXT'' update, the Red and Green channels are flipped in the normal maps. In other words, whatever is usually in the Red channel should be placed in the Green channel and vice versa.
This texture stores the surface reflection angle for each texel.  
{{Notice Small|text= This is reversed compared to standard normal maps, so ensure to note this when creating/editing normal maps for NMS.}}
{{AlertSmall‏‎|type=warning|text=Be aware that fro NMS normal maps, Red and Green channels are flipped compared to standard normal maps.}}


== Terrain Texture Formats ==
== Atlas Terrain Texture Formats ==
The terrain texture files are located in >code>TEXTURES/ATLASES/TERRAIN</code>.
The Atlas terrain texture files are located in <code>TEXTURES/ATLASES/TERRAIN</code>.


These textures are slightly different to the normal textures used by the game as the are volume textures; each file contains 10 layers of textures.
These textures are slightly different to the standard textures as they are volume textures and each file 1 main image and 10 mip-maps.


There are three textures, each in a specific .DDS format:
 
Each Terrain is defined by 3 textures, each in a specific .DDS format:


; Diffuse
; Diffuse
: Four CC | 4-bit DXT1 | 1-bit alpha
: Compression DXT1, 4bpp colors and 1-bit alpha


; HSV
; HSV
: Four CC | 4-bit DXT1 | 1-bit alpha
: Compression DXT1, 4bpp colors and 1-bit alpha
: These files appear to be HSV versions of the RGB diffuse map, however, this isn't confirmed.
: These files appear to be HSV versions of the RGB diffuse map, however, this isn't confirmed.


; Normal
; Normal
: Four CC | 8-bit DXT5
: Compression DXT5, 8bpp colors and interpolated alpha
:* Red channel - most likely a heightmap for texture blending, but unconfirmed at this time
:* Red channel - most likely a heightmap for texture blending (to be confirmed)
:* Green channel - normal map for X
:* Green channel - normal map for X
:* Blue channel - appears to be an inverted specularity map, but unconfirmed at this time
:* Blue channel - appears to be an inverted specularity map (to be confirmed)
:* Alpha channel - normal map for Y
:* Alpha channel - normal map for Y
{{NMSPageClose}}

Latest revision as of 19:06, August 5, 2021

Nomanssky flare.png

Texture Formats

by: Lo2k

Texture Formats

No Man's Sky mainly uses DDS format to encode its textures but can also accepts some other formats such as PNG, JPEG, and PSD as per Horde3D specification (to be confirmed). As such, it is highly recommended to use the Intel Texture Works plugin for Photoshop, GIMP, Paint.net or any image editor of your choice with DDS file handling capabilities. You can find the related Tutorial about editing .DDS textures here.

Textures are called by Material description files.

Accepted Texture Maps

Diffuse Map

This texture stores main object colors.

  • RGB channels - color information for your albedo map.
  • Alpha channel - this channel is mostly used for transparency but could also be used for metalness or emissive areas. As such, you can't have a texture that is transparent and emissive for example.

Mask Map

The mask map contains other color information used by NMS.

  • Red channel - ambient occlusion bakes are attached here. As of Atlas Rises, most new textures no longer use an AO map and seem to just have this channel colored pure white (basically no AO).
  • Green channel - a gloss map is used here. Despite the material settings specifying this should be a roughness map, the way they look in the textures implies it's really a gloss map, basically an inverted roughness map.
  • Blue channel - has something to do with detail textures but is largely unused for most models.
    This channel appears to be for determining where custom colors are applied for base building items :
    • White - receives primary color
    • Grey - receives secondary color (#7b7b7b has been used successfully)
    • Black - retains original texture color
  • Alpha channel - (most likely unused, but unknown at this time)

Normal Map

This texture stores the surface reflection angle for each texel.

Warning-Logo.png
WARNING:
Be aware that fro NMS normal maps, Red and Green channels are flipped compared to standard normal maps.

Atlas Terrain Texture Formats

The Atlas terrain texture files are located in TEXTURES/ATLASES/TERRAIN.

These textures are slightly different to the standard textures as they are volume textures and each file 1 main image and 10 mip-maps.


Each Terrain is defined by 3 textures, each in a specific .DDS format:

Diffuse
Compression DXT1, 4bpp colors and 1-bit alpha
HSV
Compression DXT1, 4bpp colors and 1-bit alpha
These files appear to be HSV versions of the RGB diffuse map, however, this isn't confirmed.
Normal
Compression DXT5, 8bpp colors and interpolated alpha
  • Red channel - most likely a heightmap for texture blending (to be confirmed)
  • Green channel - normal map for X
  • Blue channel - appears to be an inverted specularity map (to be confirmed)
  • Alpha channel - normal map for Y