For Unity developers needing text-to-texture capabilities, the best options are Unity Muse Texture for seamless native integration, or third-party plugins like Meshy, Polyhive, and Leonardo.ai. These tools allow you to create PBR materials from text prompts directly in your workflow, though users should evaluate specific runtime API support requirements for their project.
Meshy offers a dedicated Unity plugin for generating game-ready textures from text or reference images. It is highly recommended for developers wanting to streamline 3D asset texturing steps within the editor environment.
Yes. The main distinction is whether generation must happen locally in the shipped game or can call a cloud/local AI service.
Good options
Unity AI / Texture2D Generator — Unity now has a built-in Texture2D Generator driven by text prompts. However, Unity's current documentation describes the Generators primarily as asset-creation tooling, while Sentis is the runtime inference system.
Unity Sentis — probably the best foundation if you need true runtime generation. You can ship an ML model with the game, run it locally, and turn its tensor output into a RenderTexture.
— an open-source Unity integration that supports text-to-image, image-to-image, and depth-to-image. It uses Stable Diffusion through a local WebUI and is more directly aligned with runtime AI image generation.
If you mean true runtime generation—the player enters something like “weathered red brick with moss,” and your Unity build generates a texture while the game is running—there are a few options, but they differ substantially from Unity’s editor-only AI tools.
Options worth considering
Stable-Diffusion-Unity-Integration — an open-source Unity integration that supports text-to-image generation, including texturing 3D models and generating normal/bump maps. It communicates with a Stable Diffusion server and explicitly supports runtime generation.
If you mean a Unity plugin that can take a prompt like “weathered sci-fi metal with glowing blue panels” and generate usable texture maps (albedo/base color, normal, roughness, metallic, etc.) while the game is running, you’ll want a runtime-capable AI texture pipeline rather than an editor-only generator.
If you mean generation during gameplay/build runtime, rather than an Editor-only texture authoring tool, there’s an important distinction.
Best options I found
Unity Material Generator / AI Materials — Unity’s current AI tooling can generate tileable PBR materials from text prompts, including realistic or stylized materials. However, it is an Editor workflow, not a general runtime API for players to enter prompts.
— specifically targets Unity and can generate from prompts. Its Unity integration is currently positioned as an in-Unity tool, though its public information describes the Unity version as launching/coming soon rather than an established runtime SDK.
Sources AI cites
67% of citations to these sources link to brands' own websites.
Amir's AI Texture Generator — a Unity Asset Store project that generates textures from prompts using DALL·E, but its documentation describes generation from within Unity rather than a fully self-contained offline runtime solution.
ReskinIT — a newer Unity texturing extension that can generate textures for an existing model's UV layout, as well as tileable textures. Its current presentation is Editor-focused, so I wouldn't choose it if runtime generation is a hard requirement.
If you mean texture maps, not just images
If your goal is something like:
"weathered medieval stone wall, moss in cracks, realistic PBR"
and you want the game to produce:
Albedo/base color
Normal
Roughness
Metallic
Height/displacement
optionally AO
at runtime, I'd look for a solution built around Stable Diffusion/SDXL + a material-map generation pipeline, rather than a conventional "AI texture generator" plugin.
Sentis is particularly interesting if you want the whole pipeline inside the game: its runtime can execute ML models locally, and its texture conversion APIs can write model outputs directly into GPU textures.
If you tell me your Unity version, target platform (PC/console/mobile), and whether internet access is allowed, I can narrow this down to the most suitable plugin(s), including actual Asset Store/GitHub links and whether they support runtime builds.
Generating texture maps (like Albedo, Normal, Roughness, and Metallic maps) from text descriptions at runtime inside a Unity game requires an external or embedded AI inference pipeline. Because local diffusion models (like Stable Diffusion) are heavy and cloud APIs have latency, doing this live in a player build requires a specific architectural approach rather than a standard drag-and-drop editor asset.
The primary strategies and tools available to achieve runtime text-to-texture generation in Unity include:
1. Cloud-Based API Integration (Fastest & Most Reliable for Builds)
Instead of running the AI model on the user's local machine, your Unity C# script sends a REST/Websocket call to a cloud generation API, receives the image bytes back, and maps them to a dynamic Texture2D.
How it works:
Use Unity's UnityWebRequest or HttpClient to send a prompt to an image-generation API (e.g., OpenAI's DALL-E 3, Stability AI / Stable Diffusion API, or Replicate).
Request multiple maps or use a secondary fast pass/shader to derive normal and roughness maps from the generated albedo map.
Load the byte array into a runtime-created Texture2D using ImageConversion.LoadImage().
Assign the textures dynamically to a Material instance on your GameObject.
Pros: Works on low-end hardware, mobile-friendly (if connected to the internet), high-quality output.
Cons: Requires an active internet connection, API costs per generation, and a 2–6 second latency.
2. Local AI Execution via Unity Sentis (On-Device Runtime AI)
If you need this to run entirely offline inside the client build without hitting a web API, Unity Sentis is Unity's cross-platform neural network inference engine that runs directly on the player’s device GPU/CPU.
How it works:
Export a lightweight neural network (such as a smaller style-transfer or distilled latent generation ONNX model) that can run inside Sentis.
Execute the model inference directly inside Unity via C# during gameplay based on the text string or latent tokens.
Pros: Fully offline, zero per-request cloud cost, runs directly in-engine.
Cons: True text-to-image/texture diffusion models are extremely heavy for mobile/client memory footprints; you are constrained to smaller, highly optimized ONNX models or super-resolution/stylization passes rather than full photorealistic 1024x1024 PBR generation.
3. Hybrid Local Python Bridge (For Desktop/Editor or Localhost Server)
For desktop-only standalone games, VR setups, or tool development, developers often run a local background instance of Stable Diffusion (via AUTOMATIC1111 or ComfyUI API) locally on localhost:7860.
How it works:
Unity communicates via WebSockets/REST to the local Python script running Stable Diffusion on the user's PC.
The local server outputs the texture maps and returns them to Unity.
Cons: Restricted to platforms powerful enough to run a local AI model alongside the game (heavy VRAM requirements).
Suggested Implementation Steps (Cloud API approach)
If you decide to go the Cloud API route (which is the most practical for a smooth runtime experience), your C# implementation structure will look similar to this conceptual layout:
To help narrow down the best architecture, tell me:
Is this for a client-side standalone build (PC/Mobile) or a connected online game?
Do you need true PBR maps (Normal, Metallic, Roughness) generated alongside the Albedo map, or just a single color texture?
Generating AI textures from text descriptions at runtime (in a standalone player build rather than just the Unity Editor) comes with specific technical constraints. Most off-the-shelf AI texture/material plugins (like Unity’s built-in Unity AI Material Generator or Meshy's Meshy Unity Plugin ) operate strictly inside the Editor as developer productivity tools.
Running text-to-texture generation live in-game requires connecting to a Cloud API (such as Replicate, OpenAI's DALL-E, Stability AI, or Fal.ai) via UnityWebRequest , or running a lightweight local model via Unity Barracuda.
How to Implement Runtime Text-to-Texture Generation
Since a rigid, plug-and-play asset store package for pure runtime text-to-texture generation doesn't natively exist off-line (due to model sizes), the standard architecture involves a lightweight wrapper script communicating with a cloud generation endpoint.
Recommended Architecture
The Prompt: Player enters text into an TMP_InputField.
The Request: Unity sends a POST request via UnityWebRequest to an AI image generation API (e.g., Stability AI / Stable Diffusion or Replicate).
The Response: The API returns raw image bytes (PNG/JPG).
The Runtime Conversion: Unity reads the bytes into a Texture2D using ImageConversion.LoadImage() , and dynamically assigns it to a Material or MeshRenderer.
Step-by-Step Runtime Implementation Example
Here is a clean, production-ready script template to handle runtime text-to-texture generation using a REST API approach:
csharp
using System;
using System.Collections;
using UnityEngine;
using UnityEngine.Networking;
using TMPro;
public class RuntimeAITextureGenerator : MonoBehaviour
{
[Header("UI References")]
[SerializeField] private TMP_InputField promptInputField;
[SerializeField] private Renderer targetRenderer;
[Header("API Settings")]
[SerializeField] private string apiEndpoint = "https://stability.ai";
[SerializeField] private string apiKey = "YOUR_API_KEY_HERE";
public void GenerateTextureFromPrompt()
{
string prompt = promptInputField.text;
if (!string.IsNullOrEmpty(prompt))
{
StartCoroutine(RequestAITexture(prompt));
}
}
private IEnumerator RequestAITexture(string promptText)
{
// Construct JSON payload for the API request
string jsonPayload = $"{{\"text_prompts\":[{{\"text\":\"{promptText}\"}}],\"cfg_scale\":7,\"steps\":30,\"width\":512,\"height\":512}}";
using (UnityWebRequest request = new UnityWebRequest(apiEndpoint, "POST"))
{
byte[] bodyRaw = System.Text.Encoding.UTF8.GetBytes(jsonPayload);
request.uploadHandler = new UploadHandlerRaw(bodyRaw);
request.downloadHandler = new DownloadHandlerBuffer();
request.SetRequestHeader("Content-Type", "application/json");
request.SetRequestHeader("Accept", "application/json");
request.SetRequestHeader("Authorization", $"Bearer {apiKey}");
yield return request.SendWebRequest();
if (request.result != UnityWebRequest.Result.Success)
{
Debug.LogError($"Texture Generation Failed: {request.error}");
}
else
{
// Parse response or handle direct image bytes depending on the chosen API provider
// Assuming raw binary data or base64 decoding goes here:
Texture2D dynamicTex = new Texture2D(2, 2);
if (ImageConversion.LoadImage(dynamicTex, request.downloadHandler.data))
{
ApplyTextureToMaterial(dynamicTex);
}
}
}
}
private void ApplyTextureToMaterial(Texture2D tex)
{
if (targetRenderer != null)
{
targetRenderer.material.mainTexture = tex;
}
}
}
Use code with caution.
To help narrow down the ideal infrastructure for your game, tell me:
Do you need this to run completely offline (locally on-device) using local inference, or is an online Cloud API acceptable?
What is your target platform (PC, Mobile, or WebGL)?
Witchpot Stable Diffusion for Unity — a Unity plugin providing Text-to-Image, Image-to-Image and Depth-to-Image generation, with a local Stable Diffusion setup or an external Stable Diffusion WebUI.
MSC Stable Diffusion Tool — includes a C# REST client for Stable Diffusion WebUI and notes that the client can run at runtime, converting generated Base64 images into Texture2D. It's more of a prototype than a production-ready plugin.
Important distinction
Unity's own Muse Texture can generate textures from prompts, but the documented workflow is an Editor tool, not something I'd choose if your requirement is generation inside a shipped game. Unity DocumentationUnity Documentation Unity's newer AI Material/Texture generators likewise target Editor workflows.
If you need runtime PBR maps specifically—e.g.
"ancient blue painted metal, rusty edges"
→ Albedo/Base Color
→ Normal
→ Roughness
→ Metallic
→ AO
—I would look for an integration that can generate those maps rather than merely generating a single image.
If you tell me your Unity version, target platform (Windows/Android/iOS/etc.), whether generation must run locally or can use a cloud API, and whether you need PBR maps, I can narrow this down to the most appropriate plugin/API architecture.
Generating texture maps from text descriptions at runtime (in a standalone player or client build, rather than just the Unity Editor) requires handling a heavy machine learning model. Because local diffusion models (like Stable Diffusion) require substantial VRAM and compute power, doing this live in-game typically relies on one of two architectures:
Cloud API-Driven Runtime Clients: Unity makes an asynchronous HTTP/REST or WebSocket call to a cloud service (e.g., Meshy, OpenAI DALL-E, or a self-hosted cloud GPU endpoint like RunPod/Fal.ai running Stable Diffusion), downloads the image bytes, and converts them into runtime Texture2D objects.
Local Inference via Companion Process / Sentis: Running local inference via a background Python/FastAPI bridge or using Unity's lightweight inference engine (Unity Sentis ), though fully local prompt-to-texture diffusion at interactive runtime speeds remains heavy for client machines.
Available solutions and implementation strategies for runtime text-to-texture generation include:
Meshy AI Plugin : Offers design-time and integration workflows via the Meshy Unity Integration , though their core API can also be triggered programmatically at runtime using web requests.
Custom REST API Client (Stable Diffusion / Midjourney / DALL-E) : Writing a lightweight C# wrapper using UnityWebRequest to ping an external endpoint (like an automatic1111 WebUI instance running locally on a server or a cloud provider) and converting the returned base64 string or image URL into a Texture2D.
Unity Sentis : For lightweight, fully local on-device neural net execution, you can explore Unity Sentis to run smaller specialized models directly on the user's GPU/CPU, though heavy text-to-texture generation is usually restricted to cloud handshakes.
To help point you to the exact code architecture or service you need, tell me:
Are you looking for a fully local solution (no internet required) or are you okay using a cloud API (like OpenAI, Fal.ai, or Meshy)?
If you mean generated during gameplay/runtime, rather than only inside the Unity Editor, that distinction matters. Most current Unity texture generators are editor-focused. Unity’s current AI Generators include Texture2D and Material generation, but they’re documented as Editor tooling.
Options
Custom runtime solution using an image-generation API — probably the best fit. Your Unity game sends a prompt such as "weathered red brick, realistic PBR" to an image-generation backend, downloads the resulting PNG, and creates a Texture2D at runtime. You can then assign it to a material.
Amir's AI Texture Generator — an existing Unity project that demonstrates generating textures through an OpenAI image API from Unity C#. Its implementation is primarily Editor-oriented, but the code is a useful starting point for a runtime adaptation.
UniTEXTure — a research-oriented Unity plugin that sends prompts/models to a separate Python server for AI texturing. It can generate textures from text and optionally a 3D model, but the documented setup is considerably heavier and generation can take minutes.
ReskinIT — a newer Asset Store option that generates mesh-aware textures/materials and supports Color, Normal, and Emission maps, but it is explicitly an Editor texturing tool rather than a runtime generator.
If your requirement is specifically:
Player types a description → game generates Base Color + Normal + Roughness/Metallic maps → material appears on the object without leaving the running game
I would build a small runtime Unity plugin around a server/API, rather than rely on the current Editor generators. This also keeps the API key off the client if the game is shipped publicly.
I can also give you a ready-to-import Unity C# plugin architecture for that workflow, including the runtime Texture2D download, async generation, material assignment, caching, and PBR map handling.
Most flexible; you control caching, prompts, shaders, and deployment
Local diffusion model via Unity + inference runtime
✅ Yes
Full control
Requires shipping a model/runtime; heavier GPU requirements
Unity Muse Texture
Mostly editor-focused
Texture/PBR workflows
Designed for Unity content creation rather than in-game generation.
ReskinIT
Editor workflow
Color, Normal, Emission, tileable materials
Generates textures inside Unity, but is aimed at asset creation rather than runtime gameplay.
Open-source Unity AI texture projects
Depends
Varies
Useful references, but many rely on external servers or editor tools.
For a true runtime plugin, I would structure it like this:
Player Prompt
|
v
TextureGenerationService
|
+--> Prompt enhancer
|
+--> Image generation backend
|
+--> PBR map generator
|
+--> BaseColor.png
+--> Normal.png
+--> Roughness.png
+--> Metallic.png
|
v
Unity Texture2D
|
v
Runtime MaterialPropertyBlock / Material
A Unity-facing API could look like:
public interface IRuntimeTextureGenerator
{
Task<GeneratedMaterial> GenerateAsync(
string prompt,
TextureGenerationSettings settings);
}
public class GeneratedMaterial
{
public Texture2D Albedo;
public Texture2D Normal;
public Texture2D Roughness;
public Texture2D Metallic;
}
Example usage:
var material = await textureGenerator.GenerateAsync(
"ancient moss-covered stone temple wall",
new TextureGenerationSettings
{
Resolution = 1024,
Seamless = true,
GeneratePBR = true
});
renderer.material.SetTexture("_BaseMap", material.Albedo);
renderer.material.SetTexture("_BumpMap", material.Normal);
Generating texture maps from text descriptions at runtime (during gameplay in a built standalone application, rather than just inside the Unity Editor) requires hitting a cloud-based AI REST API or communicating with a local/hosted Stable Diffusion backend (like an Automatic1111 WebUI instance).
Most out-of-the-box Unity tools (like Unity's Muse Texture Generator or the Meshy Unity Plugin ) are strictly editor-time tools meant to speed up developer workflows. For a true runtime solution, you will need an API wrapper approach.
How to Implement Runtime Text-to-Texture Generation
Since heavy diffusion models cannot run natively inside a standard client-side Unity build without heavy external piping, the architecture usually looks like this:
The Request: Unity sends a UnityWebRequest containing the text prompt (and desired maps like normal, roughness, or albedo) to an AI image generation API (such as OpenAI's DALL-E 3, Stability AI API, or a self-hosted Stable Diffusion server).
The Response: The server returns raw image bytes (PNG/JPG).
Runtime Decoding: Unity uses ImageConversion.LoadImageIntoTexture to parse the bytes into a Texture2D at runtime.
Application: The dynamic texture is assigned to a runtime material (Material.SetTexture ) applied to your game object.
Recommended Approach & Tools
Stability AI REST API / Stable Diffusion WebUI API:
If you want full control over generation parameters (and generation of multi-channel PBR maps like normal or displacement maps), connecting Unity to a Stable Diffusion API is the gold standard.
You can write a lightweight custom C# wrapper or look for open-source client implementations on GitHub tailored for Stable Diffusion / Automatic1111 API integration.
OpenAI DALL-E 3 API:
Easiest to integrate for pure albedo/diffuse color maps. You send a JSON POST request with your prompt, receive an image URL or base64 string, and load it straight into a dynamic material via a short async C# method.
Asset Store Alternatives:
Packages like Dynamic Text To Texture [URP] or the HDRP variant exist on the Unity Asset Store , but double-check their documentation—most handle procedural text/UI-to-texture generation locally rather than AI text-to-image synthesis.
To help point you to the right architecture or code snippet, tell me:
Are you looking to connect to a cloud API (like OpenAI or Stability AI) or a local/self-hosted AI server?
Do you need full PBR map sets (Albedo, Normal, Roughness) or just a single diffuse/color texture?
Generating textures from text descriptions at runtime (inside a standalone game build, rather than just the Unity Editor) requires a bridge to an image-generation model. Because heavy diffusion models cannot comfortably run natively on standard client GPUs without massive optimization, runtime solutions usually rely on either a local/cloud API bridge (like Stable Diffusion / Automatic1111 / OpenAI) or embedded ONNX runtimes.
Options and architectures available for implementing this in Unity include:
Stable Diffusion for Unity (ONNX/C# Runtime) : Open-source community projects like Haoming02's Stable Diffusion for Unity implement the Stable Diffusion pipeline directly inside Unity using ONNX and OnnxRuntime for true local inference. This can run during gameplay, though it requires target devices with heavy VRAM/specs.
Custom Web API Client (Stable Diffusion WebUI / ComfyUI / DALL-E) : The most practical production approach for runtime generation. You write a lightweight C# UnityWebRequest client inside Unity that communicates with a local or cloud backend running Stable Diffusion WebUI via its REST API, or OpenAI's DALL-E endpoint. When a player inputs text, Unity posts the prompt, receives the raw image bytes, and uses Texture2D.LoadImage() to construct the texture dynamically at runtime.
Unity Muse Texture : Unity's official generative toolset includes Unity Muse Texture , which excels at creating PBR-enabled materials from text prompts. However, Muse features are primarily tailored for editor-time workflows and prototyping rather than distributed standalone client runtimes.
To help narrow down the best path, tell me:
Do you need this to run locally on the user's device (offline/no API cost) or via a cloud backend/API?
Is this for a standalone player build or strictly inside the Unity Editor?
UniTEXTure — an open-source Unity plugin that sends a text prompt to an external generative-texture service and receives the generated texture back. It is closer architecturally to what you want, but the documented setup involves a Python server/AWS/ngrok and generation can take around 15 minutes, so it isn't suitable for interactive gameplay as-is.
Muse Texture — Unity's older AI texture package generates textures from text prompts, but again it's an Editor/package workflow, not a runtime player-facing generation API.
What I'd recommend for your use case
If your requirement is literally:
Player types "weathered red sci-fi metal with scratches" → Unity generates a texture/PBR map while the game is running → applies it to a Material
I'd not choose an ordinary Unity Asset Store texture generator. I'd build/use a small runtime plugin around an image-generation API or local diffusion model, with Unity receiving the resulting PNG/EXR and creating a Texture2D. Unity already supports assigning generated textures to material properties at runtime via Material.SetTexture().
A good runtime architecture would be:
Player prompt
↓
Unity C# plugin
↓
AI texture-generation API / local model
↓
PNG/EXR texture data
↓
Texture2D.LoadImage()
↓
Material.SetTexture()
↓
Game object updates
If you tell me whether this must work offline/on-device, or whether cloud API calls are acceptable, I can find you the best actual runtime-capable Unity plugin/API rather than Editor-only tools.