← 返回
未分类

图标粒子化

Generate a particle convergence animation video from any logo or image. 10,000 particles scatter and converge into the logo shape with synthesized music that builds to a "ding" reveal. Supports any image (auto-detects background, transparent PNGs, dark/light backgrounds). Use when the user wants to create a particle animation, logo reveal video, or motion graphics from an image.
支持图片、LOGO 一键生成粒子汇聚动画。万粒光点飘散聚合成型,音效层层递进,收尾清脆音效定格画面。自动适配画面底色,兼容透明图与深浅背景,快速制作 LOGO 开场动态特效视频。
Danny的时光机
未分类 community v1.0.0 1 版本 100000 Key: 无需
★ 1
Stars
📥 61
下载
💾 0
安装
1
版本
#latest

概述

Particle Logo Convergence

Generate a 1080p particle animation video from any logo or image. Pure local processing — Python + FFmpeg, no API key needed.

When to Use

Trigger this skill when the user wants to:

  • Create a particle animation or logo reveal video
  • Turn a logo / image into a motion graphics clip
  • Generate a short video with synthesized music from a static image

Requirements

  • FFmpeg must be installed (brew install ffmpeg)
  • Python deps: numpy, Pillow (installed automatically via uv run --with)

Workflow

Step 1: Confirm inputs

Ask the user for (if not already provided):

  • Input image — any PNG/JPG/WEBP; transparent-background PNGs work best
  • Output path — e.g. output.mp4
  • Size (optional) — defaults to auto-detect from image aspect ratio
  • Duration (optional) — defaults to 6 seconds
  • Particles (optional) — defaults to 10,000
  • Background color (optional) — defaults to auto-detect

Step 2: Run the script

uv run --with numpy --with Pillow python3 <skill-path>/scripts/particle_logo.py <input_image> <output.mp4> [--size WxH] [--duration N] [--particles N] [--fps 30|60] [--bg COLOR] [--no-audio]

The script path is scripts/particle_logo.py relative to this SKILL.md.

Parameters:

ParameterDefaultDescription
---------------------------------
--size WxHautoVideo size (e.g. 1920x1080, 1080x1920, 1080)
--duration N6.0Duration in seconds (range 3-30)
--particles N10000Particle count (range 1000-50000). More = finer detail but slower
`--fps 30\60`60Frame rate. 30 = smaller file, 60 = smoother
--bg COLORautoBackground color: auto / white / black / #RRGGBB
--no-audiooffSkip audio synthesis, output video only

Examples:

# Auto size (preserves image aspect ratio)
uv run --with numpy --with Pillow python3 <skill-path>/scripts/particle_logo.py logo.png output.mp4

# Force specific size
uv run --with numpy --with Pillow python3 <skill-path>/scripts/particle_logo.py logo.png output.mp4 --size 1920x1080

# Custom duration and particles
uv run --with numpy --with Pillow python3 <skill-path>/scripts/particle_logo.py logo.png output.mp4 --duration 10 --particles 20000

# Fast preview (fewer particles, lower fps, no audio)
uv run --with numpy --with Pillow python3 <skill-path>/scripts/particle_logo.py logo.png output.mp4 --particles 3000 --fps 30 --no-audio

# Black background, portrait video
uv run --with numpy --with Pillow python3 <skill-path>/scripts/particle_logo.py logo.png output.mp4 --bg black --size 1080x1920

Step 3: Verify output

Check that:

  1. The output file exists and is > 1 MB (a near-zero file means all-black video)
  2. The script printed a sensible Auto BG color and a non-zero targets count

If targets is 0 or the file is too small, see Troubleshooting below.

Auto-Detection Behavior

Image typeBackgroundForeground mask
-----------------------------------------
Light background (white/gray)Sampled from 4 cornersOtsu threshold on color distance
Dark backgroundSampled from 4 cornersOtsu threshold on color distance
Transparent PNG (RGBA)Forced to whiteAlpha channel directly

Size auto-detection (when --size is not given):

  • Longest side ≤ 1920, shortest side ≤ 1080, original aspect ratio preserved
  • 1:1 image → ~1080×1080, 16:9 → 1920×1080, 4:3 → 1440×1080

Output Specs

PropertyValue
-----------------
Duration6 seconds (configurable 3-30s via --duration)
FPS60 (or 30 via --fps)
CodecH.264, CRF 18
AudioAAC 192k, synthesized build-up music (disable via --no-audio)
Particles10,000 (configurable 1k-50k via --particles)
Convergence~58% duration particle build → ding → logo reveal

Troubleshooting

SymptomCauseFix
---------------------
File ~0.2 MB, all blackParticle color == background (e.g., black icon on transparent → black bg)Should be auto-fixed; if not, check that the image has an alpha channel
targets: 0 errorNo foreground pixels detectedImage may have very low contrast; not currently supported
ffmpeg: command not foundFFmpeg not installedbrew install ffmpeg
Very slow (>5 min)Too many target pixels (>500k)Use a simpler/smaller logo

版本历史

共 1 个版本

  • v1.0.0 Initial release 当前
    2026-05-25 13:55 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

design-media

Video Frames

steipete
使用 ffmpeg 从视频中提取帧或短片。
★ 134 📥 53,014
design-media

Nano Banana Pro

steipete
使用 Nano Banana Pro (Gemini 3 Pro Image) 生成或编辑图像。支持文生图、图生图及 1K/2K/4K 分辨率,适用于图像创建、修改及编辑请求,使用 --input-image 指定输入图像。
★ 430 📥 117,280
design-media

Openai Whisper

steipete
使用 Whisper CLI 进行本地语音转文字(无需 API 密钥)
★ 332 📥 94,164