Skip to content

Instantly share code, notes, and snippets.

Avatar
Focusing

Xiaolin Zhang leoncamel

Focusing
View GitHub Profile
View 0001-webrtcbin-an-element-that-handles-the-transport-aspe.patch
From e465847873fdb54de7bc834c2d3d78639b98427a Mon Sep 17 00:00:00 2001
From: Matthew Waters <matthew@centricular.com>
Date: Tue, 31 Jan 2017 20:56:59 +1100
Subject: [PATCH] webrtcbin: an element that handles the transport aspects of
webrtc connections
SDP's are generated and consumed according to the W3C PeerConnection API
available from https://www.w3.org/TR/webrtc/
The SDP is either created initially from the connected
@leoncamel
leoncamel / webrtc.rst
Last active May 18, 2019 — forked from voluntas/webrtc.rst
WebRTC 資料まとめ
View webrtc.rst
View janus-subscriber-example.md

create

  • POST
{
    "janus":"create",
@leoncamel
leoncamel / Makefile
Last active May 18, 2016
minimum libhdfs example
View Makefile
CC=gcc
JVM_ROOT=/usr/lib/jvm/java-7-openjdk-amd64/
HADOOP_ROOT=/home/xiaolin/work/apache/hadoop-2.7.1
export CLASSPATH=$(shell ${HADOOP_ROOT}/bin/hadoop classpath --glob)
export LD_LIBRARY_PATH=${HADOOP_ROOT}/lib/native:${JVM_ROOT}/jre/lib/amd64/server/
CFLAGS = -O2 -g -Wall -fmessage-length=0 -I${HADOOP_ROOT}/include
OBJS = hello.o
View gist:10d165c24d59db1ca09b
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
def build_argparser():
parser = argparse.ArgumentParser()
parser.add_argument('--foo', action='store_true', help='foo help')
View download_on_time_data.sh
#!/bin/bash
#
# Reference : http://www.transtats.bts.gov/DL_SelectFields.asp?Table_ID=236&DB_Short_Name=On-Time
#
now=`date +"%Y-%m-%d" -d "01/01/1987"`
end=`date +"%Y-%m-%d" -d "05/01/2015"`
# end=`date +"%Y-%m-%d"`
View plot_into_pdf.py
#!/usr/bin/env python
# Reference:
# [1] http://matplotlib.org/examples/pylab_examples/multipage_pdf.html
# This should be executed before other matplotlib imports
import matplotlib
matplotlib.use('Agg')
import datetime
@leoncamel
leoncamel / gist:dfc0492777bc2db97739
Created Jul 14, 2014
Docker build by docker-py
View gist:dfc0492777bc2db97739
import docker
c = docker.Client(base_url="http://localhost:port", version="1.11")
print(c.version())
for i in c.build(fileobj=open("file.tar"), stream=True, custom_context=True):
print(i)
@leoncamel
leoncamel / gist:6076222
Last active Dec 20, 2015
Serialization in C# driver of MongoDB
View gist:6076222
using System;
using System.Collections.Generic;
using MongoDB.Bson;
using MongoDB.Bson.Serialization.Attributes;
using MongoDB.Bson.Serialization.Options;
using MongoDB.Driver;
namespace TestMongoDot
{
class MyEntity
View a.diff
diff --git a/GHC/Integer.hs b/GHC/Integer.hs
index c9b50a7..8fd41d9 100644
--- a/GHC/Integer.hs
+++ b/GHC/Integer.hs
@@ -28,6 +28,7 @@ module GHC.Integer (
eqInteger, neqInteger, absInteger, signumInteger,
leInteger, gtInteger, ltInteger, geInteger, compareInteger,
divModInteger, quotRemInteger, quotInteger, remInteger,
+ modInteger, divInteger,
encodeFloatInteger, decodeFloatInteger, floatFromInteger,
You can’t perform that action at this time.