Skip to content

Instantly share code, notes, and snippets.

@chikuzen
chikuzen / my_build.sh
Created September 2, 2011 13:09
How to compile libav/x264cli on windows
#!/bin/bash
# CAUTION!!! THIS SCRIPT IS NO WARRANTY!!!
: << _COMMENT_
How to compile libav/x264 binaries for both 32bit and 64bit on Windows
At first, you should install Git into your Windows.
1. Download Git from
http://msysgit.googlecode.com/files/Git-1.7.6-preview20110708.exe
#!/bin/env python
# reorder_args.py for Python 2.x
# written by Chikuzen
import sys
import os
def usage():
print "usage : reorder_args.py <func name> <num of args> <new order> <filename>\n"
@chikuzen
chikuzen / vsenc.py
Last active March 27, 2016 21:06
vapoursynth sample
#vsenc.py
#coding: utf-8
import sys
from subprocess import Popen, PIPE
import vapoursynth as vs
x264_binary_path = 'D:/tools/x86/x264.exe'
avconv_binary_path = 'D:/tools/x86/avconv.exe'
@chikuzen
chikuzen / jpeg2yuv.c
Created October 14, 2012 11:34
JPEG2YUV - TurboJPEG/OSS sample
#include <stdio.h>
#include <stdlib.h>
#include <sys/stat.h>
#include "turbojpeg.h"
typedef struct {
tjhandle tjh;
FILE *src;
unsigned char *src_buff;
unsigned char *dst_buff;
@chikuzen
chikuzen / finesharp.py
Last active October 13, 2015 00:37
vapoursynth sample
#finesharp.py - finesharp module for VapourSynth
#original author : Didee (http://forum.doom9.org/showthread.php?t=166082)
# requirement: RemoveGrain.dll, Repair.dll
import vapoursynth as vs
class InvalidArgument(Exception):
def __init__(self, value):
self.value = value
@chikuzen
chikuzen / easyvfr.py
Last active July 28, 2020 18:26
port of EasyVFR for VapourSynth
#!/usr/bin/env python3
'''port of EasyVFR for VapourSynth'''
__author__ = 'Chikuzen <chikuzen.mo at gmail dot com>'
__version__ = '0.2.5'
import vapoursynth as vs
@chikuzen
chikuzen / finesharp.py
Created July 29, 2013 11:17
finesharp for vapoursynth r19 or later
#finesharp.py - finesharp module for VapourSynth
#original author : Didee (http://forum.doom9.org/showthread.php?t=166082)
# requirement: RemoveGrain.dll, Repair.dll
# VapourSynth r19 or later
import vapoursynth as vs
class InvalidArgument(Exception):
def __init__(self, value):
@chikuzen
chikuzen / histeresis.cpp
Last active December 20, 2015 15:28
Hysteresis mask for avisynth2.6
#include <windows.h>
#include "avisynth.h"
static const AVS_Linkage* AVS_linkage = 0;
class Footprint {
int index;
int width;
int height;
BYTE* map;
@chikuzen
chikuzen / transpose.cpp
Last active December 21, 2015 16:09
Transpose for avisynth2.6x
#include <stdint.h>
#include <malloc.h>
#include <windows.h>
#include <emmintrin.h>
#include "avisynth.h"
static const AVS_Linkage* AVS_linkage = 0;
static __forceinline __m128i mm_movehl_si128(const __m128i& xmm0)
{
#define LOGO "RemoveGrain 1.0\n"
// An Avisynth plugin for removing grain from progressive video
//
// By Rainer Wittmann <gorw@gmx.de>
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 2 of the License, or
// (at your option) any later version.
//