Skip to content

Instantly share code, notes, and snippets.

@riocampos
riocampos / らじるらじるm3u8をffmpegで録音する(8放送局)201709以降対応.txt
Last active February 5, 2024 11:54
らじるらじる m3u8 を ffmpeg で録音する(8放送局)2021/4 以降対応
## NHKのネット配信サービスであるらじる★らじる。
# 従来は https://gist.github.com/riocampos/5656450 のように rtmpdump を使う必要がありましたが、
# 2017年9月から m3u8 による配信へ変更になったようです。m3u8 なので10秒単位での録音になります。
# また 2021年4月に更新され、以前の M3U8URL は2022年2月末で廃止されました。
## 録音コマンド(m4a)
ffmpeg -i M3U8URL -c copy outputfilename.m4a
# ファイルサイズ的に m4a が最も小さくなる
# m4a ファイルのときだけ "-c copy" オプションが使える。
@mattmc3
mattmc3 / tasks.json
Created April 6, 2017 00:44
VSCode tasks for running a Makefile
// Makefile
// ${workspaceRoot} the path of the folder opened in VS Code
// ${file} the current opened file
// ${fileBasename} the current opened file's basename
// ${fileDirname} the current opened file's dirname
// ${fileExtname} the current opened file's extension
// ${cwd} the task runner's current working directory on startup
{
"version": "0.1.0",
"command": "bash",
@windyinsc
windyinsc / vlc_ts_error_fix.md
Created March 19, 2017 00:12
Fix for VLC: ts error: libdvbpsi error (PSI decoder): TS duplicate

FIX FOR VLC ERROR BELOW

The following changes to VLC were successful in fixing all playback issues.

  • VLC Version 2.2.4 Weatherwax (Intel 64bit) on OS X 10.9

ISSUE:

ts error: libdvbpsi error (PSI decoder): TS duplicate (received 0, expected 1) for PID 0 ts error: libdvbpsi error (PSI decoder): TS duplicate (received 0, expected 1) for PID 4095

@kastnerkyle
kastnerkyle / extract_feats.py
Last active December 12, 2022 21:27
Extract features with HTK/speech_tools/festival/merlin
from __future__ import print_function
import os
import shutil
import stat
import subprocess
import time
import numpy as np
from scipy.io import wavfile
import re
import glob
@connormanning
connormanning / curl_jsoncpp_example.cpp
Last active August 11, 2022 04:35
Curl HTTP GET and JsonCpp parsing - basic functionality
#include <cstdint>
#include <iostream>
#include <memory>
#include <string>
#include <curl/curl.h>
#include <json/json.h>
namespace
{
@Mic92
Mic92 / botcommands.py
Last active October 22, 2022 00:30
start/stop mpv with python
#!/usr/bin/env python
import socket
import subprocess
import os, sys
MPV_SOCKET = "/tmp/mpvsocket"
CIDER = "cider.hq.c3d2.de"
IS_PYTHON2 = sys.version_info < (3, 0)
if IS_PYTHON2:
@feklee
feklee / README.md
Last active April 24, 2019 16:38
Notes and experiments concerning HTML5 streaming, with an emphasis on live streaming

Introduction

Collection of solutions for streaming via DASH, Dynamic Adaptive Streaming over HTTP, as of November 2014.

Recommended client: Chrome 38

Tool used for encoding live streams: FFmpeg

@kizzx2
kizzx2 / fun.cpp
Last active March 29, 2022 04:12
Illustrative C++ Lua binding example/tutorial
// fun.cpp
// This is for Lua 5.2, for Lua 5.1, see https://gist.github.com/kizzx2/1594905
#include <lua.hpp>
#include <iostream>
#include <sstream>
class Foo
{
@zester
zester / foo.cpp
Created April 21, 2012 17:08
Lua and C++
// fun.cpp
extern "C"
{
#include <lua.h>
#include <lauxlib.h>
#include <lualib.h>
}
#include <iostream>