Skip to content

Instantly share code, notes, and snippets.

View MarcAlx's full-sized avatar
🌱

MarcAlx MarcAlx

🌱
View GitHub Profile
@MarcAlx
MarcAlx / Main.cs
Created January 15, 2019 17:03
Unity Scene to Equirectangular png (spherical image)
/*
* This script produces a .png image from an Unity scene.
*
* Result image looks like this : https://fr.wikipedia.org/wiki/Fichier:Paris_s%27éveille_equirectangular_panorama.jpg
*
* inspired from : https://docs.unity3d.com/ScriptReference/RenderTexture.ConvertToEquirect.html
* and https://docs.unity3d.com/ScriptReference/Camera.RenderToCubemap.html
*
* To use it add this script to your scene then run
*/
@MarcAlx
MarcAlx / RandomNumberGenerator.cs
Created July 8, 2018 09:53
Mersenne Twister - C#
/// <summary>
/// Random Number Generator based on Mersenne-Twister algorithm
///
/// Usage :
/// RandomNumberGenerator.Instance.Generate());
/// RandomNumberGenerator.Instance.Generate(1.1,2.2);
/// RandomNumberGenerator.Instance.Generate(1,100)
///
/// inspired from : http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/VERSIONS/C-LANG/980409/mt19937-2.c
/// </summary>
@MarcAlx
MarcAlx / Usefull React - Redux links
Created May 24, 2018 19:37
Usefull React/Redux links
@MarcAlx
MarcAlx / notifications.py
Last active February 14, 2026 19:48
Send macOS notifications from python 3
#!/usr/local/bin/python3.4
# -*- coding: utf-8 -*-
# Crée par MarcAlx
import os
def displayNotification(message,title=None,subtitle=None,soundname=None):
"""
Display an OSX notification with message title an subtitle
sounds are located in /System/Library/Sounds or ~/Library/Sounds
@MarcAlx
MarcAlx / Usefull UWP .NET links
Last active May 24, 2018 19:33
Usefull UWP/.NET links