draw_texture_to_render_target
Draw a texture as a tinted rectangle onto a UTextureRenderTarget2D in one editor canvas pass, alpha-blending over existing GPU pixels without clearing or saving.
Instructions
Draw a texture as a rectangle onto a UTextureRenderTarget2D asset in one canvas pass in the editor world: position and size in render-target pixels from the top-left (size defaults to the whole target), full 0-1 UVs, tinted by color. It alpha-blends over the existing pixels: nothing is cleared, saved or undoable, and render-target contents live on the GPU only, so keep them with create_static_texture_from_render_target or export_render_target. A missing render target or texture is an error; drawn is false, and the call fails, when a width or height that is not positive draws nothing. For a material use draw_material_to_render_target_region.
Returns: { render_target_path: string, texture_path: string, drawn: bool, position: [number], size: [number] }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| size | No | Optional [w, h] destination size, defaults to render target dimensions | |
| color | No | Optional [r, g, b, a] tint color, defaults to opaque white | |
| position | No | Optional [x, y] destination position, default [0,0] | |
| texture_path | Yes | Asset path of the UTexture to draw, e.g. /Engine/EngineResources/WhiteSquareTexture | |
| render_target_path | Yes | Asset path of the destination render target |