sudo apt update
sudo apt install software-properties-common -y
import cv2 | |
import numpy as np | |
img = np.zeros((100, 300, 3), dtype=np.uint8) | |
ft = cv2.freetype.createFreeType2() | |
ft.loadFontData(fontFileName='Ubuntu-R.ttf', | |
id=0) | |
ft.putText(img=img, | |
text='Quick Fox', |
using AOT; | |
using System; | |
using System.Collections.Generic; | |
namespace WebGL | |
{ | |
public static class FileSystem | |
{ | |
#if UNITY_WEBGL && !UNITY_EDITOR | |
[DllImport("__Internal")] |
/// Singleton example | |
using UnityEngine; | |
public class SomeSingletonClass : MonoBehaviour | |
{ | |
public static SomeSingletonClass instance; | |
void Awake() { instance = this; } | |
public float someValue; |
using UnityEditor; | |
using UnityEngine; | |
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Text.RegularExpressions; | |
// Object rendering code based on Dave Carlile's "Create a GameObject Image Using Render Textures" post | |
// Link: http://crappycoding.com/2014/12/create-gameobject-image-using-render-textures/ |