create_texture_2d_from_data
Creates a saved UTexture2D asset filled with a solid RGBA color, without an external image file. Specify size, color, and content path to generate or rebuild the texture deterministically.
Instructions
Creates a persisted UTexture2D filled with a solid color (no external file). Allocates the editor source (FTextureSource::Init, BGRA8), fills every pixel with fill_color, calls UpdateResource, registers the asset and saves it to disk. Re-running deletes and rebuilds the asset deterministically. fill_color is an [R, G, B, A] array of 0-255 byte values (default = opaque white).
Returns: { texture_name: string, asset_path: string, created: bool, saved: bool, width: int, height: int, format: string, has_source: bool, fill_color: [int, int, int, int], save_error?: string }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Name of the texture asset to create | |
| width | No | Optional pixel width; clamped 1..8192; defaults to 64 | |
| height | No | Optional pixel height; clamped 1..8192; defaults to 64 | |
| fill_color | No | Optional [R, G, B, A] (0-255 each); defaults to opaque white | |
| package_path | No | Content folder; defaults to /Game/Textures |