This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections.Generic; | |
using UnityEngine; | |
public static class PolygonReduction | |
{ | |
public static List<Vector2> DouglasPeuckerReductionPoints(List<Vector2> points, float tolerance) | |
{ | |
if (points == null || points.Count < 3) | |
return points; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Text; | |
namespace Engine.Mathematics | |
{ | |
public static unsafe class MetroHash | |
{ | |
private const ulong K0 = 0xD6D018F5; | |
private const ulong K1 = 0xA2AA033B; | |
private const ulong K2 = 0x62992FC1; | |
private const ulong K3 = 0x30BC5B29; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.IO; | |
using System.Text; | |
using System.Collections.Generic; | |
public static class Config | |
{ | |
public const string TypeUint8 = "uint8"; | |
public const string TypeUint16 = "uint16"; | |
public const string TypeUint32 = "uint32"; | |
public const string TypeUint64 = "uint64"; |