Skip to content

Instantly share code, notes, and snippets.

@HedioKojima
HedioKojima / webdav.lua osd版
Last active July 2, 2026 02:57
mpv WebDAV lua 由Qwen3.7-Max编写的osd版 功能灵感来自https://github.com/Ladersbt/mpv-config/blob/master/scripts/uosc_webdav.lua 🖖
local mp = require('mp')
local msg = require('mp.msg')
local options = require('mp.options')
local utils = require('mp.utils')
local commandv = mp.commandv
local command_native_async = mp.command_native_async
local set_property = mp.set_property
local get_property = mp.get_property
local osd_message = mp.osd_message
@zhongfly
zhongfly / set_proxy.lua
Last active April 4, 2026 11:36
Get windows system proxy(only support http proxy) and auto set proxy for mpv and ytdl_hook
local mp = require 'mp'
local block = true
function string:trim()
return (self:gsub("^%s*(.-)%s*$", "%1"))
end
-- safe protocol (copied from mpv ytdl_hook.lua)
------------------------------------------------------------------------
local function Set (t)
@kevinlekiller
kevinlekiller / sofalizer.lua
Last active January 17, 2026 02:07
Lua script for mpv to enable sofalizer, with sofa file inside of mpv's ~~/
--[[
Copyright (C) 2023 kevincs
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.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
@KCCat
KCCat / mpv-mvtools-blksize64.py
Last active March 25, 2026 00:28
mpv-mvtools.vpy
import vapoursynth as vs
core = vs.core
clip = video_in
vfps = int(container_fps*1e8)
dfps = 60000
#dfps = 0
def ffps(fps):
rfps = int('%.0f' % fps)
if ( abs(fps - (rfps/1.001)) < abs(fps - (rfps/1.000)) ):
@Zehkul
Zehkul / Convert Script – README.md
Last active July 16, 2026 14:02
Script to quickly convert and crop videos from within mpv

#README:

This script for mpv intends to offer the fastest and simplest way to convert parts of a video—while you’re watching it and not really more work intensive than making a screenshot. A short demonstration: https://d.maxfile.ro/omdwzyhkoa.webm

##Installation:

You need:

  • yad (at least 0.26) (AUR)