Skip to content

Instantly share code, notes, and snippets.

View tudour3's full-sized avatar

tudou tudour3

  • D3Plus
  • china
  • 19:10 (UTC -12:00)
View GitHub Profile
@jeffcrouse
jeffcrouse / SteamVR_TrackedObject_Plus.cs
Last active December 12, 2024 16:05
SteamVR_TrackedObject_Plus
//======= Copyright (c) Valve Corporation, All rights reserved. ===============
//
// Purpose: For controlling in-game objects with tracked devices.
// Update jeff at seethrouhlab
// - Added ability to specify a serial number to assign to the TrackedObject
// - Added a configurable lag value.
// - use with GameManager https://gist.github.com/jeffcrouse/6419e84d7060c08c17cf97b9c41ddd14
//=============================================================================
using System.Collections;
@Farfarer
Farfarer / CubemapToEquirectangularWizard.cs
Last active July 2, 2024 06:54
Create dynamic equirectangular maps for Unity. These have the benefit that, as they're flat images, you can sample lower mips to get blurry reflections. The straight cubemap version (detailed here: http://www.farfarer.com/blog/2011/07/25/dynamic-ambient-lighting-in-unity/ ) will give you hard seams when you sample mips from the cubemap. Although…
// Wizard to convert a cubemap to an equirectangular cubemap.
// Put this into an /Editor folder
// Run it from Tools > Cubemap to Equirectangular Map
using UnityEditor;
using UnityEngine;
using System.IO;
class CubemapToEquirectangularWizard : ScriptableWizard {