Skip to content

Instantly share code, notes, and snippets.

View iKalin's full-sized avatar
🎯
Focusing

Kalin Tsekov iKalin

🎯
Focusing
View GitHub Profile
@iKalin
iKalin / BlueVC.h
Created February 1, 2012 14:26 — forked from danitentouch/BlueVC.h
UITableVIew with backgroungColor = clearColor
//
// BlueVC.h
// NavigationTests
//
// Created by Dani Rangelov on 1/4/12.
// Copyright (c) 2012 Ten Touch. All rights reserved.
//
#import <UIKit/UIKit.h>
@iKalin
iKalin / BlueVC.h
Created February 1, 2012 14:26 — forked from danitentouch/BlueVC.h
UITableVIew with backgroungColor = clearColor
//
// BlueVC.h
// NavigationTests
//
// Created by Dani Rangelov on 1/4/12.
// Copyright (c) 2012 Ten Touch. All rights reserved.
//
#import <UIKit/UIKit.h>
@iKalin
iKalin / jquery.imagesloaded.js
Created October 26, 2012 14:28 — forked from desandro/jquery.imagesloaded.js
$.fn.imagesLoaded jQuery plugin
// $('img.photo',this).imagesLoaded(myFunction)
// execute a callback when all images have loaded.
// needed because .load() doesn't work on cached images
// Modified with a two-pass approach to changing image
// src. First, the proxy imagedata is set, which leads
// to the first callback being triggered, which resets
// imagedata to the original src, which fires the final,
// user defined callback.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Jed Schmidt <http://jed.is>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE

Live Transcoding

This is a collection of working commandline examples to show how one could use FFMpeg and VLC for live transcoding of video streams. All examples have been tested on OSX 10.7.5 with FFMPeg 1.1.3 and VLC 2.0.5 in early 2013.

Documentation links

@iKalin
iKalin / Tuple+Generator.swift
Created October 26, 2015 13:27 — forked from jverkoey/Tuple+Generator.swift
Tuple enumeration
/** The returned generator will enumerate each value of the provided tuple. */
func generatorForTuple(tuple: Any) -> AnyGenerator<Any> {
return anyGenerator(Mirror(reflecting: tuple).children.lazy.map { $0.value }.generate())
}
// Blogged at http://design.featherless.software/enumerating-tuple-values-swift/
@iKalin
iKalin / stream_to_youtube.sh
Created January 29, 2016 03:46 — forked from olasd/stream_to_youtube.sh
Stream video to youtube via ffmpeg
#! /bin/bash
#
# Diffusion youtube avec ffmpeg
# Configurer youtube avec une résolution 720p. La vidéo n'est pas scalée.
VBR="2500k" # Bitrate de la vidéo en sortie
FPS="30" # FPS de la vidéo en sortie
QUAL="medium" # Preset de qualité FFMPEG
YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2" # URL de base RTMP youtube
@iKalin
iKalin / async-server.py
Created July 19, 2016 11:27 — forked from derekkwok/async-server.py
Python 3.5 async "Hello World" server
import asyncio
import socket
SERVER_ADDRESS = (HOST, PORT) = '', 8888
REQUEST_QUEUE_SIZE = 5
http_response = b"""\
HTTP/1.1 200 OK
Hello, World!
"""
@iKalin
iKalin / 0. nginx_setup.sh
Created August 19, 2016 09:50 — forked from mikhailov/0. nginx_setup.sh
Nginx + secure pseudo-streaming
# Nginx can serve FLV/MP4 files by pseudo-streaming way without any specific media-server software.
# To do the custom build we use 2 modules: --with-http_secure_link_module --with-http_flv_module
# This module "secure-link" helps you to protect links from stealing away.
#
# NOTE: see more details at coderwall: http://coderwall.com/p/3hksyg
cd /usr/src
wget http://nginx.org/download/nginx-1.5.13.tar.gz
tar xzvf ./nginx-1.5.13.tar.gz && rm -f ./nginx-1.5.13.tar.gz