Skip to content

Instantly share code, notes, and snippets.

View RomainKurtz's full-sized avatar

Romain Kurtz RomainKurtz

View GitHub Profile
Scene Detection :
ffmpeg -f dshow -i video="OBS Virtual Camera" -filter:v "select='gt(scene,0.2)',showinfo" -f null -
I was able to find a VERY QUICK AND DIRTY way to use the media-autobuild suite to compile my own 64-bit static FFmpeg for Windows with the NDI library.
Download it and extract to a place on your computer, and keep note of the path. I put it in "D:\ndi\media-autobuild_suite-master", so for the sake of these instructions when you see "<autobuild>", you need to substitute whatever path you've put it in.
During the initial setup process, request to use the static build and add whatever else you'd like to have in your ffmpeg, then pause what you're doing when the on-screen prompts tell you the ffmpeg_options file has been written, then go into <autobuild>\build\ffmpeg_options.txt and add somewhere a line with
Code:
--enable-libndi_newtek
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
[InitializeOnLoad]
public class AlignCameraView : MonoBehaviour {
public bool Enable;
public static List<AlignCameraView> list;
// sending to sender-client only
socket.emit('message', "this is a test");
// sending to all clients, include sender
io.emit('message', "this is a test");
// sending to all clients except sender
socket.broadcast.emit('message', "this is a test");
// sending to all clients in 'game' room(channel) except sender
@RomainKurtz
RomainKurtz / casparcg_ndi_instructions.md
Created June 25, 2017 19:41
How to get NDI output to work in CasparCG

How to get NDI output to work in CasparCG

  1. Install NewTek Network Video Send.exe
  2. Install NewTek NDI AirSend Updater.exe
  3. The AirSend Updater has a bug, and will not properly copy the x64 version of the DLL to the correct place. So, you'll need to manually copy C:\Program Files\NewTek\NewTek NDI AirSend Updater\Processing.AirSend.x64.dll to C:\Windows\System32\, overwriting the existing file.
  4. Restart your PC.
  5. Configure the CasparCG Server to use a Newtek iVGA output. Even though it says iVGA, it will actually be outputting NDI thanks to the updated AirSend DLLs.
  • You can do this manually by adding a `` consumer to your casparcg.config, or you can do it via the third-party [Caspar
public void StartLoadingPhoto(){
IEnumerator coroutine = LoadPhoto("http://website/photo.png");
StartCoroutine(coroutine);
}
IEnumerator LoadPhoto(string url)
{
string url = url;
Texture2D tex;
tex = new Texture2D(4, 4, TextureFormat.DXT1, false);
function rotatePoint(point, center, angle){
angle = (angle ) * (Math.PI/180); // Convert to radians
var rotatedX = Math.cos(angle) * (point.x - center.x) - Math.sin(angle) * (point.y-center.y) + center.x;
var rotatedY = Math.sin(angle) * (point.x - center.x) + Math.cos(angle) * (point.y - center.y) + center.y;
return new THREE.Vector2(rotatedX,rotatedY);
}
@RomainKurtz
RomainKurtz / adn-css-render-demo.html
Created February 24, 2016 18:28 — forked from leefsmp/adn-css-render-demo.html
CSS3D Renderer Demo
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>ADN CSS3D Demo</title>
<style>
body {
background-color: #ffffff;
margin: 0;
overflow: hidden;
var app = require('express')();
var __dirname = "./public/"
/* serves main page */
app.get("/", function(req, res) {
res.sendfile( __dirname +'index.html');
});
app.post("/user/add", function(req, res) {
@RomainKurtz
RomainKurtz / MySingleton.js
Last active September 20, 2015 19:51 — forked from jasonwyatt/MySingleton.js
Singleton Pattern with Require JS
define(function(){
var instance = null;
function MySingleton(){
if(instance !== null){
throw new Error("Cannot instantiate more than one MySingleton, use MySingleton.getInstance()");
}
this.initialize();
}