Skip to content

Instantly share code, notes, and snippets.

View rngtm's full-sized avatar
💭
I may be slow to respond.

rngtm rngtm

💭
I may be slow to respond.
View GitHub Profile
@TakaakiIchijo
TakaakiIchijo / CreateSpriteFromBytes.cs
Created July 23, 2017 05:04
Unityでbyte配列からテクスチャ作ってスプライト化するまでやる
using UnityEngine;
public static class Util
{
public static Sprite CreateSpriteFromBytes(byte[] bytes)
{
//横サイズの判定
int pos = 16;
int width = 0;
for (int i = 0; i < 4; i++)