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 UnityEngine; | |
using UnityEngine.UI; | |
public class FPSDisplay : MonoBehaviour { | |
[SerializeField] private Canvas _canvas; | |
[SerializeField] private Text _text; | |
[SerializeField] private float _refreshTime = 0.5f; | |
private float _timer = 0; |
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 UnityEngine; | |
using UnityEngine.UI; | |
public class DisplayConsole :MonoBehaviour { | |
[SerializeField] Text text; | |
void OnEnable() { | |
Application.logMessageReceived += LogMessage; | |
} |
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
Shader "Custom/CameraOpaqueTexture_example" { | |
Properties{ | |
_Color ("Color", Color) = (1,1,1,1) | |
_MainTex ("Albedo (RGB)", 2D) = "white" {} | |
[HeaderHelpURL(Rendering)] | |
[Enum(UnityEngine.Rendering.CullMode)] _Culling ("Cull Mode", Int) = 2 | |
[Enum(Off,0,On,1)] _ZWrite("ZWrite", Int) = 1 | |
[Enum(UnityEngine.Rendering.CompareFunction)] _ZTest ("ZTest", Int) = 4 |
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
// -------------------------------------------------------------------------------------------------------------------- | |
// <copyright file="ConfigurableStandard.shader" company="Supyrb"> | |
// https://github.com/supyrb/ConfigurableShaders/blob/master/Shaders/ConfigurableStandard.shader?fbclid=IwAR1lolNLIXdN5clTZaRpCSCxxxXtB8VzWnBWfrWkFlAgdkPcy2mp1xXwZ7g | |
// Copyright (c) 2019 Supyrb. All rights reserved. | |
// </copyright> | |
// <repository> | |
// https://github.com/supyrb/ConfigurableShaders | |
// </repository> | |
// <author> | |
// Johannes Deml |
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
// https://gist.github.com/WonkyKIM/58c75a3226e1e84e8b1af2167accfe1f | |
#if UNITY_EDITOR | |
using System.IO; | |
using UnityEditor; | |
using UnityEngine; | |
public class LookupTextureGenerator : MonoBehaviour { | |
NewerOlder