Skip to content

Instantly share code, notes, and snippets.

@zloedi
Last active Apr 5, 2019
Embed
What would you like to do?
Unity Debug.DrawImage and Debug.DrawText routines in single file/static class.
using UnityEngine;
using System.Collections.Generic;
#if UNITY_EDITOR
using UnityEditor;
#endif
public static class DebugEx
{
public static float CharactersOffset = -4;
public static void DrawImage(Vector3 worldPos, Texture2D tex, Rect rect, Rect uv, Color? color = null,
float duration = 0.0f)
{
#if UNITY_EDITOR
var img = new Image {
WorldPos = worldPos,
Tex = tex,
Rect = rect,
UV = uv,
Color = color != null ? color.Value : Color.white,
EndTime = Time.time + duration,
};
_images.Add(img);
#endif
}
public static void DrawText(Vector3 worldPos, string text, Vector2 pos, Color? color = null, float duration = 0.0f)
{
#if UNITY_EDITOR
float charSz = CharSz;
float d = (float)FontTexWidth;
float charUV = charSz / d;
float start = pos.x + CharactersOffset;
for (int i = 0; i < text.Length; i++) {
int c = text[i];
Rect src = new Rect((c % 16) * charSz / d, (c / 16) * charSz / d, charUV, charUV);
Rect dst = new Rect(start + (charSz + CharactersOffset) * i, pos.y, charSz, -charSz);
DrawImage(worldPos, _fontTex, dst, src, color, duration);
}
#endif
}
public static void DrawText(Vector3 worldPos, string text, float offset = 0, Color? color = null, float duration = 0.0f)
{
#if UNITY_EDITOR
float w = (CharSz + CharactersOffset) * text.Length;
DrawText(worldPos, text, new Vector2(-w / 2, -offset), color, duration);
#endif
}
#if UNITY_EDITOR // PRIVATES
private class Image {
public Vector3 WorldPos;
public Texture2D Tex;
public Rect Rect;
public Rect UV;
public Color Color;
public float EndTime;
}
private const int FontTexWidth = 192;
private const int CharSz = FontTexWidth / 16;
private static Texture2D _fontTex;
static DebugEx()
{
SceneView.onSceneGUIDelegate -= OnScene;
SceneView.onSceneGUIDelegate += OnScene;
EditorApplication.update -= OnUpdate;
EditorApplication.update += OnUpdate;
int side = FontTexWidth;
_fontTex = new Texture2D(side, side);
for (int y = 0, i = 0; y < side; y++ ) {
for ( int x = 0; x < side; x++, i++ ) {
_fontTex.SetPixel( x, y, new Color32(0xff, 0xff, 0xff, _font[i] == 0 ? (byte)0x00 : (byte)0xff));
}
}
_fontTex.Apply();
}
private static List<Image> _images = new List<Image>();
private static void DrawImage(Image img)
{
GUI.color = img.Color;
Camera cam = SceneView.lastActiveSceneView.camera;
Vector3 screenPos = cam.WorldToScreenPoint(img.WorldPos);
Rect r = new Rect(img.Rect.x + screenPos.x,
img.Rect.y + (cam.pixelRect.height - screenPos.y),
img.Rect.width,
img.Rect.height);
GUI.DrawTextureWithTexCoords(r, img.Tex, img.UV);
}
private static void Update()
{
if (Application.isPlaying && _images.Count > 0) {
Handles.BeginGUI();
for (int i = _images.Count - 1; i >= 0; i--) {
var img = _images[i];
if (img.EndTime < Time.time) {
_images.RemoveAt(i);
} else {
DrawImage(img);
}
}
Handles.EndGUI();
}
}
private static void OnUpdate()
{
if (_images.Count > 0) {
SceneView.RepaintAll();
}
}
private static void OnScene(SceneView sceneView)
{
Update();
}
private static readonly byte [] _font =
{
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
1,1,1,1,1,1,1,1,1,1,1,1,
0,0,0,0,0,0,0,0,0,0,0,0,
1,1,1,1,1,1,1,1,1,1,1,1,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,1,1,1,1,1,1,0,0,0,
0,0,0,1,1,1,1,1,1,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,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