
将任何视频压缩到精确的大小(Discord 20 MB,WeChat 20 MB,WhatsApp 16 MB),本地使用FFmpeg - 在Windows上作为单一的.exe,没有安装,或通过npm.
概览
将任何视频压缩到任意大小。 当地人。 并保持质量. • 网站和amp;指南; 以QQ为特色 2 500+ npm的下载量 0:0.2:Windows用户可以下载一个半大小.exe并跳过Node.js,npm和安装器完全——一个文件中的CLI,本地网络应用和MCP服务器. 发布注释 WeChat和Discord都停了下来。 电子邮件也一样 所以你打开一个视频编辑器,猜测比特率,导出,检查大小,再导出,仍然无法判断图片是否变差. 它计算比特率,选择实际匹配的分辨率,编码两次,然后用结果测量结果,这样你就可以知道它是否仍然一样。 "让它变小"是一个解决了的问题. 是每个工具让你猜测的部分。 - HandBrake很好,但它要求你思考解码器、RF值和预设值。 - 在线压缩机工作 直到你记得你刚刚上传了一段私人视频给陌生人.
概述(AI 翻译)
半径
将任何视频压缩到任意大小。 当地人。 并保持质量.
· 妇女 网站和amp; 指南 − 快开始… 如何运作 财务问题
以QQ为特色 2 500+ npm的下载量
0:0.2:0中新建:Windows用户可以下载一个半尺寸.exe并跳过Node.js,. npm和安装器完全——一个文件中的CLI,本地网络应用和MCP服务器. 发布注释
– – . . .
WeChat和Discord都以20 MB为站点. 电子邮件也一样 所以你打开一个视频编辑器,猜测比特率,导出,检查大小,再导出,然后仍然 无法分辨照片是否恶化。
[T0] 将它变成一个命令:
它计算比特率,选择实际匹配的分辨率,编码两次,然后测量 与SSIM和VMAF的结果,所以你知道它是否仍然看起来一样。
□为什么这个存在
“让它变小"是一个解决了的问题. {\fn黑体\fs22\bord1\shad0\3aHBE\4aH00\fscx67\fscy66\2cHFFFFFF\3cH808080}请告诉我是否 仍然看起来对”**是每个工具让你猜测的部分.
- HandBrake很好,但它要求你思考解码器、RF值和预设值.
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
halfsize
Compress any video to any size. Locally. And keep the quality.
中文说明 · Website & guides · Quick start · How it works · FAQ
As featured in 阮一峰《科技爱好者周刊》第 418 期 · 2,500+ downloads on npm
New in 0.2.0: Windows users can download one halfsize.exe and skip Node.js, npm and the installer entirely — CLI, local web app and MCP server in one file. Release notes
WeChat and Discord both stop at 20 MB. Email chokes around the same. So you open a video editor, guess a bitrate, export, check the size, export again, and still can’t tell whether the picture got worse.
halfsize turns that into one command:
npx halfsize wedding.mp4 --to 25mb
It computes the bitrate, picks the resolution that actually fits, encodes twice, then measures the result with SSIM and VMAF so you know whether it still looks the same.
halfsize 0.2.0
source.mp4
23.2 MB 8s 1920x1080 30.00 fps h264
target 2.00 MB
plan H.264 960x540 1.81 Mbps audio 128 kbps 2-pass
scale 1920x1080 -> 960x540
estimate 1.94 MB (12x smaller)
output source.2mb.mp4
measuring quality done in 1s
23.2 MB -> 1.99 MB 12x smaller 0.4% under target
VMAF 84.4 SSIM 0.968 slight softening
-> C:\Videos\source.2mb.mp4
Why this exists
“Make it smaller” is a solved problem. “Make it fit in exactly 20 MB, and tell me if it still looks right” is the part every tool makes you guess at.
安装
npx -y halfsize --mcp配置
{
"mcpServers": {
"halfsize": { "command": "npx", "args": ["-y", "halfsize", "--mcp"] }
}
}