Exporting From Substance Painter To Unity: A Step-By-Step Guide

how to export from substance painter to unity

Exporting from Substance Painter to Unity is a crucial step in bringing high-quality, textured 3D assets into your game or real-time project. Substance Painter allows artists to create intricate textures and materials, which can then be seamlessly integrated into Unity for rendering and gameplay. The process involves exporting textures in the correct format, such as PNG or TGA, and configuring the material settings in Substance Painter to match Unity's requirements. Once exported, the textures are imported into Unity, where they are applied to the corresponding 3D model using a standard or custom shader. Proper setup ensures that details like normal maps, roughness, and metallic properties are accurately represented, maintaining the visual fidelity intended by the artist. This workflow bridges the gap between texturing and real-time rendering, enabling developers to achieve professional-grade visuals in their Unity projects.

Characteristics Values
Export Format Supports .sbsar (Substance Archive) and .tga, .png, or .exr textures.
Texture Maps Exported Base Color, Normal, Metallic, Roughness, Height, Emissive, Ambient Occlusion, Opacity, etc.
Texture Resolution Adjustable (e.g., 1K, 2K, 4K) based on project needs.
File Structure Organized folders for Albedo, Normal, Metallic, Roughness, etc.
Unity Import Settings Automatically detects and assigns textures to appropriate shader channels.
Shader Compatibility Works with Unity Standard, URP, HDRP, and custom shaders.
Normal Map Format Supports OpenGL and DirectX formats (adjustable in Substance Painter).
Compression Settings Allows texture compression (e.g., DXT5, BC7) for optimization.
Export Presets Customizable presets for different platforms (PC, Mobile, Console).
Material Creation Automatically generates Unity materials upon import.
UDIM Support Supports UDIM workflows for high-poly models.
Export Time Varies based on texture resolution and complexity.
Plugin Requirement No additional plugin needed; Unity natively supports .sbsar files.
Version Compatibility Works with Substance Painter 2023+ and Unity 2021+.
Post-Processing Requires manual adjustments in Unity for final material tweaks.
Documentation Official Substance Painter and Unity documentation available.

cypaint

Setting up Substance Painter export presets for Unity compatibility

Exporting textures from Substance Painter to Unity requires precision to ensure compatibility and optimal performance. Setting up custom export presets in Substance Painter streamlines this process, tailoring outputs to Unity’s specific needs. Start by navigating to the "Export Maps" window in Substance Painter and selecting "Create Preset." Name the preset clearly, such as "Unity_Standard_Shader," to differentiate it from other configurations. This foundational step ensures consistency across projects and saves time by eliminating manual adjustments for each export.

Unity’s Standard Shader demands specific texture maps, including Albedo, Normal, Metallic, Roughness, and Ambient Occlusion. When configuring your preset, map these channels accordingly: assign the Base Color to Albedo, the Metallic and Roughness to their respective channels, and combine Height and Normal maps into a single Normal map. Ensure the color space is set to sRGB for Albedo and Linear for all other maps, as Unity expects this format. Adjust the bit depth to 8 bits per channel for most textures, but consider 16 bits for Normal maps if higher precision is required for complex surfaces.

One critical aspect often overlooked is the texture size. Unity performs best with textures that are powers of two (e.g., 1024x1024, 2048x2048). In Substance Painter, set the resolution in the export preset to match this requirement. Additionally, enable mipmaps during export, as Unity uses them for level-of-detail optimization. If your project includes mobile or low-end platforms, consider reducing texture sizes or using compression formats like DXT5 or ETC2, which can be selected in Unity’s import settings post-export.

A common pitfall is misaligned UVs or incorrect texture flipping. To avoid this, ensure the "Flip Green Channel" option is enabled for Normal maps in the export preset, as Unity’s Normal map convention differs from some other engines. Test your preset by exporting a sample material and importing it into Unity. Inspect the textures in the Texture Import Settings to verify that channels are mapped correctly and compression settings align with your project’s needs. Iterating on your preset based on these tests ensures a seamless workflow.

Finally, organize your presets for scalability. Create separate presets for different Unity shaders or platforms, such as "Unity_URP_Shader" or "Unity_Mobile." Store these presets in a shared location for team access, ensuring consistency across projects. By investing time in setting up these presets, you not only enhance Unity compatibility but also future-proof your workflow, allowing for smoother transitions as projects evolve or new team members join.

cypaint

Baking maps in Substance Painter for Unity integration

Baking maps in Substance Painter is a critical step for achieving high-quality, optimized textures in Unity. This process transfers details like normals, ambient occlusion, and curvature from high-poly models to low-poly versions, ensuring your assets look intricate without taxing performance. Think of it as capturing the essence of a detailed sculpture in a lightweight, game-ready form.

Baking isn't just about aesthetics; it's about efficiency. Unity thrives on optimized assets, and baked maps significantly reduce polygon count while preserving visual fidelity. This is especially crucial for real-time rendering, where every triangle and texture pixel counts.

The baking process in Substance Painter is straightforward but demands attention to detail. First, ensure your high-poly and low-poly models are perfectly aligned, with corresponding UVs. Substance Painter's automatic alignment tools can help, but manual adjustments are often necessary for complex meshes. Next, select the maps you need – normals, ambient occlusion, curvature, and more – and configure baking settings. Pay close attention to cage settings, which define the baking area and prevent unwanted artifacts.

A common pitfall is overlooking texture size. Baked maps should match the resolution of your final textures in Unity. Baking at a higher resolution than needed wastes resources, while lower resolutions result in blurry, unusable maps. Aim for a balance between quality and performance, typically ranging from 1024x1024 to 4096x4096 pixels, depending on the asset's importance.

Once baked, inspect your maps carefully. Look for seams, bleeding, or missing details. Substance Painter's 3D viewport allows for real-time preview, making it easy to identify and rectify issues. Remember, these maps will directly influence your asset's appearance in Unity, so meticulousness at this stage pays off.

Finally, exporting baked maps for Unity is a breeze. Substance Painter's export presets include Unity-specific settings, ensuring correct texture formats (like PNG or TGA) and color space (typically sRGB for diffuse maps, Linear for normals). Double-check that your export path aligns with your Unity project's structure for seamless integration. With properly baked maps, your assets will transition smoothly from Substance Painter to Unity, ready to shine in your game or application.

cypaint

Exporting textures in Unity-supported file formats

Substance Painter excels at creating photorealistic textures, but Unity needs them in specific formats for optimal performance. Understanding Unity's preferred file types is crucial for seamless integration.

PNG reigns supreme for albedo (base color) maps due to its lossless compression and support for transparency. This ensures crisp details and accurate color representation in your Unity materials.

TGA is another viable option, offering lossless compression and alpha channel support, though its file sizes can be larger than PNG. Consider TGA if PNG's compression artifacts become noticeable in your textures.

While Substance Painter allows exporting in various formats, not all are Unity-friendly. Avoid formats like EXR or TIFF, which, while offering high dynamic range, can significantly increase file size and may not be fully supported by Unity's shader system.

JPEG, though widely used, is a lossy format that can introduce compression artifacts, compromising texture quality. Reserve JPEG for situations where file size is absolutely critical and visual fidelity can be compromised.

Exporting from Substance Painter to Unity involves more than just choosing the right format. Texture size plays a vital role in performance. Aim for powers of two (e.g., 512x512, 1024x1024) for optimal GPU handling. Substance Painter's export settings allow you to resize textures during export, ensuring compatibility with Unity's texture importer.

Remember, the goal is to strike a balance between visual fidelity and performance. Experiment with different formats and compression settings in Substance Painter's export dialog to find the sweet spot for your specific project. Unity's texture importer provides further control over mipmapping, filtering, and compression, allowing you to fine-tune your textures for the best possible in-engine results.

cypaint

Importing Substance Painter textures into Unity projects

Exporting textures from Substance Painter to Unity is a seamless process when you understand the workflow. Begin by ensuring your textures are set to the correct resolution and format in Substance Painter. Unity supports various texture formats, but PNG and TGA are commonly used for their balance of quality and performance. Once your textures are ready, navigate to the File menu in Substance Painter, select Export Textures, and choose the Unity preset. This preset automatically configures the export settings to align with Unity’s requirements, including correct channel packing and file naming conventions.

After exporting, import the textures into Unity by dragging the folder containing the exported files into the Assets panel. Unity will automatically detect and process the textures, applying the appropriate settings for albedo, normal, metallic, and roughness maps. However, it’s crucial to verify that the Texture Import Settings are optimized for your project. For instance, set the Texture Type to Default for albedo maps and Normal Map for normal maps. Adjust the Compression settings to Compressed for better performance, but use Truecolor for textures requiring higher fidelity, like emissive maps.

One common challenge is ensuring proper material setup in Unity. Create a new Material and assign the imported textures to their respective slots in the Standard Shader. For example, drag the albedo map to the Albedo slot, the normal map to the Normal Map slot, and so on. If your textures include packed channels (e.g., metallic and roughness in a single texture), enable the Use Metallic Roughness option in the material settings. This ensures Unity interprets the texture correctly, maintaining the intended visual fidelity.

To streamline the process further, consider using Unity’s Addressable Assets system or a Material Pipeline script to automate texture assignment and material creation. This is particularly useful for large projects with numerous assets. Additionally, leverage Unity’s Post-Processing Stack to enhance the final look of your materials, applying effects like ambient occlusion or color grading to match your desired aesthetic. By combining Substance Painter’s texturing power with Unity’s material system, you can achieve professional-grade results efficiently.

Finally, test your imported textures in different lighting conditions within Unity to ensure they behave as expected. Use the Scene View’s lighting tools to simulate various environments and verify that the materials respond realistically. If discrepancies arise, revisit the export settings in Substance Painter or adjust the texture import settings in Unity. With careful attention to detail and a structured workflow, importing Substance Painter textures into Unity becomes a straightforward and rewarding process.

cypaint

Applying exported materials to Unity game objects

Exporting materials from Substance Painter to Unity is just the first step; the real magic happens when you apply these materials to your game objects. Unity’s workflow is designed to seamlessly integrate Substance Painter exports, but knowing the nuances can save you hours of trial and error. Start by importing the exported package into Unity, which typically includes textures, maps, and a material preset. Drag the material from the Project window onto your game object, and Unity will automatically apply the textures based on the naming conventions Substance Painter uses (e.g., _BaseColor, _Normal, _Metallic). This process is straightforward, but it’s the foundation for achieving the visual fidelity you designed in Substance Painter.

One critical aspect often overlooked is the importance of texture compression settings in Unity. By default, Unity may compress textures to save memory, which can degrade the quality of your exported materials. To preserve the high-quality output from Substance Painter, navigate to the Texture Import Settings and set the compression to Compressed (ARGB 32-bit) or Truecolor for key textures like Base Color and Normal maps. Additionally, ensure the Generate Mip Maps option is enabled to maintain quality across different distances in your game. These adjustments ensure the material looks as intended, without Unity’s compression algorithms introducing unwanted artifacts.

Applying materials to complex game objects with multiple sub-meshes requires a bit more finesse. Unity’s Standard Shader works well with Substance Painter exports, but for objects with varying materials, you’ll need to assign materials to specific sub-meshes. In the Mesh Renderer component, expand the Materials array and drag the corresponding materials from the Project window into each slot. For instance, if your object has a metal body and rubber tires, assign the metal material to the body sub-mesh and the rubber material to the tires. This level of detail ensures each part of the object reflects its intended material properties, enhancing realism.

Lighting plays a pivotal role in how materials appear in Unity, and Substance Painter’s exports are no exception. After applying materials, test your game object under different lighting conditions to ensure the textures react as expected. Unity’s Post-Processing Stack can further enhance the visual impact by adding effects like bloom, depth of field, or screen-space reflections. For instance, metallic materials benefit from screen-space reflections, while rough surfaces like concrete may require subtle ambient occlusion. Experimenting with these settings bridges the gap between Substance Painter’s static preview and Unity’s dynamic environment.

Finally, consider optimizing your materials for performance, especially in large-scale projects. Unity’s Shader Graph allows you to create custom shaders that leverage Substance Painter’s maps while reducing draw calls. For example, you can combine multiple texture maps into a single texture atlas or use Unity’s Triplanar Mapping for terrain or large objects. These optimizations ensure your game runs smoothly without sacrificing the visual quality achieved in Substance Painter. By balancing aesthetics and performance, you can create game objects that are both stunning and efficient.

Frequently asked questions

Use the PNG or TGA format for exporting textures from Substance Painter to Unity. Both formats are widely supported and preserve quality. PNG is lossless and compressed, while TGA is uncompressed but ensures no data loss.

In Substance Painter, go to File > Export Textures. Ensure the Template is set to Unity (Standard). Adjust the Texture Set to include all necessary maps (Albedo, Normal, Metallic, Roughness, etc.). Set the Resolution to match your Unity project’s requirements and export.

After exporting, drag the texture folder into Unity’s Assets panel. Create a new Material and assign the Shader to Standard or Universal Render Pipeline (URP)/HDRP depending on your project. Drag the corresponding textures (Albedo, Normal, etc.) into the material’s properties to apply them.

Written by
Reviewed by
Share this post
Print
Did this article help you?

Leave a comment