# Sandbox.UI.Panel.DrawTexture

```csharp
void DrawTexture(Painter painter, Texture texture, Length defaultSize)
```

Called by Image, SvgPanel and ScenePanel from OnDraw(Painter) to draw their texture without a content cache.
Resolves sizing, position, tint, filtering and rounded clipping from the current style, draws in local coordinates,
and restores the caller's Painter state. CSS borders remain in the separate background pass.

### Parameters

- `painter` (`Painter`)
- `texture` (`Texture`)
- `defaultSize` (`Length`)

Declared in [Sandbox.UI.Panel](/api/Sandbox.UI.Panel).
Assembly: `Sandbox.Engine`.
