Skip to content

Instantly share code, notes, and snippets.

View huanle0610's full-sized avatar
🎯
Focusing

huanle0610 huanle0610

🎯
Focusing
  • Shenzhen, China
View GitHub Profile
@huanle0610
huanle0610 / run_python_script_in_conda_env.bat
Created November 29, 2023 06:07 — forked from maximlt/run_python_script_in_conda_env.bat
Run a Python script in a conda environment from a batch file
@echo OFF
rem How to run a Python script in a given conda environment from a batch file.
rem It doesn't require:
rem - conda to be in the PATH
rem - cmd.exe to be initialized with conda init
rem Define here the path to your conda installation
set CONDAPATH=C:\ProgramData\Miniconda3
rem Define here the name of the environment
@huanle0610
huanle0610 / win32-test-with-dlls.cmake
Created November 15, 2022 02:13 — forked from micahsnyder/win32-test-with-dlls.cmake
An example using CMake/CTest to collect runtime DLL dependencies prior to testing
lib/lib.h:
lib/lib_private.h:
lib/lib.c:
#
# Assume some C library that makes use of OpenSSL
#
lib/CMakeLists.txt:
#
# Test executables
@huanle0610
huanle0610 / lyrics.lua
Last active September 27, 2021 02:02 — forked from youthlin/lyrics.lua
show lyrics in vlc
--[[--
show lyrics on visualization 在可视化界面显示歌词
url 项目地址: https://gist.github.com/youthlin/a3b3fc033586bede6046086f3d889322
author 作者: youthlin
author url 作者博客: https://youthlin.com
How to install:
1. put this file on lua/intf/
2. enable extra interface: luaintf (Settings[Show all] -> Interface -> Main Interfaces -> extract modules='luaintf'[make the 'Lua interpreter' checked])
(important: extraintf=luaintf not lua)
@huanle0610
huanle0610 / lyrics.lua
Created September 27, 2021 02:01 — forked from youthlin/lyrics.lua
show lyrics in vlc
--[[--
show lyrics on visualization 在可视化界面显示歌词
url 项目地址: https://gist.github.com/youthlin/a3b3fc033586bede6046086f3d889322
author 作者: youthlin
author url 作者博客: https://youthlin.com
How to install:
1. put this file on lua/intf/
2. enable extra interface: luaintf (Settings[Show all] -> Interface -> Main Interfaces -> extract modules='luaintf'[make the 'Lua interpreter' checked])
(important: extraintf=luaintf not lua)
@huanle0610
huanle0610 / installation.md
Created July 19, 2020 02:19 — forked from abcdefg30/installation.md
Unofficial, manual content installation for OpenRA

Manual (unrecommended) installation of the required content files for OpenRA

⚠️ This method is not recommended and should only be applied if automatic installation fails. Success of manually installing the files can not be guaranteed. ⚠️

⚠️ The automatic installation may fail for non-english content. OpenRA does not support other languages at the current stage of development and no such content should be installed. ⚠️

⚠️ Manually installing files can corrupt your game and lead to crashes. ⚠️

If you have trouble with automatic installation, please contact the developers (via IRC, our forum, the webpage comments or our issue tracker) before attempting a manual install.

@huanle0610
huanle0610 / .ssh_config
Created April 20, 2020 00:48 — forked from andyvanee/.ssh_config
Fix unix_listener too long for Unix domain socket
Host *
ControlPath ~/.ssh/control/%C
ControlMaster auto
@huanle0610
huanle0610 / Index.html
Created February 11, 2020 06:33 — forked from meziantou/Index.html
Javascript - Record audio
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title></title>
</head>
<body>
<h1>Audio</h1>
@huanle0610
huanle0610 / get_indexdb_sizes.js
Last active February 11, 2020 03:50 — forked from tralves/get_indexdb_sizes.js
Calculate sizes of all IndexDB database and tables
var getTableSize = function (db, dbName) {
return new Promise((resolve, reject) => {
if (db == null) {
return reject();
}
var size = 0;
db = event.target.result;
var transaction = db.transaction([dbName])
.objectStore(dbName)
.openCursor();
@huanle0610
huanle0610 / ffmpeg.md
Created January 6, 2020 03:40 — forked from protrolium/ffmpeg.md
using ffmpeg to extract audio from video files

ffmpeg

Converting Audio into Different Formats / Sample Rates

Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma

You can get the list of supported formats with:
ffmpeg -formats

Convert WAV to MP3, mix down to mono (use 1 audio channel), set bit rate to 64 kbps and sample rate to 22050 Hz:

@huanle0610
huanle0610 / Audio.WebAudio.Browser.Compat.md
Created November 28, 2019 10:28 — forked from uupaa/Audio.WebAudio.Browser.Compat.md
Audio, WebAudio, Blob, ArrayBuffer
  1. Audio(url)
  2. Audio(arraybuffer)
  3. Audio(blob)
  4. WebAudio(arraybuffer)
  5. WebAudio(blob)

Audio file access with streaming

http://uupaa.net/issues/3/ の結果