Skip to content

Instantly share code, notes, and snippets.

print "hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world hello world "
I've found a way to use pc like an headset with Android phone (for making callings).
!!! I've use pulseaudio from jessie-backports: I don't know how much this takes risks ;-) !!!
In /etc/apt/sources.list add:
deb http://ftp.jp.debian.org/debian/ jessie-backports main contrib non-free
deb-src http://ftp.jp.debian.org/debian/ jessie-backports main contrib non-free
$ sudo apt-get update
$ sudo apt-get install pulseaudio=7.1-2~bpo8+1 pulseaudio-utils=7.1-2~bpo8+1 \
@upgradeQ
upgradeQ / AReadME.md
Last active November 25, 2025 14:19
Text editors configuration. Neovim, sublimetext

Installing neovim on windows

download zip, create nvim folder in local appdata, write to file inside neovim : e path/to/nvim/init.vim

this will create config with right permissions

download vim plug via powershell

download git

download zig

@upgradeQ
upgradeQ / beep.lua
Last active September 19, 2022 13:43
Beep when the replay buffer has fully stopped. [windows]
local obs = obslua
local ffi = require("ffi")
ffi.cdef[[
void Beep(int freq,int dur);
]]
function beep()
ffi.C.Beep(7000,300)
end
@upgradeQ
upgradeQ / print_properties.lua
Last active September 25, 2024 17:56
Double pointers obslua
-- https://obsproject.com/forum/threads/how-to-enumerate-script-properties-in-lua.83406/#post-397381
-- create source with name tmp , then add Color Correction filter named color
local obs = obslua
local ffi = require("ffi")
local obsffi
ffi.cdef[[
struct obs_source;
local obs = obslua
--- name of a scene item
local source_name = ''
--- get the name of the current scene
local function current_scene_name()
local source = obs.obs_frontend_get_current_scene()
local name = obs.obs_source_get_name(source)
obs.obs_source_release(source)
local obs = obslua
local coroutine = require 'coroutine'
local math = require 'math'
local Timer = {}
function Timer:init(o)
o = o or {}
setmetatable(o,self)
self.__index = self
return o
@upgradeQ
upgradeQ / TriggerHotkeyByName.lua
Created November 22, 2020 18:11
Hotkey enumeration via obs_enum_hotkeys
local obs = obslua
local ffi = require 'ffi'
local obsffi
if ffi.os == "OSX" then
obsffi = ffi.load("obs.0.dylib")
else
obsffi = ffi.load("obs")
end
ffi.cdef[[
@upgradeQ
upgradeQ / audio_level.lua
Created November 22, 2020 18:13
audio volume level. RIP source_volume_level
local obs = obslua
local ffi = require 'ffi'
local jit = require 'jit'
local obsffi
if ffi.os == "OSX" then
obsffi = ffi.load("obs.0.dylib")
else
obsffi = ffi.load("obs")
end
@upgradeQ
upgradeQ / shader1.lua
Last active May 2, 2023 16:44
Simple multi pass shaders for OBS Studio
S = obslua
local ffi = require"ffi"
local C = ffi.C
local _OR = bit.bor
ffi.cdef[[
typedef struct {int x, y;} Point;
bool GetCursorPos(Point *lpPoint);
]]
RESOLUTION = {2560,1440};
local mouse_pos = ffi.new("Point")