返回顶部
p

pixel-asset-pipeline像素资产管线

AI pixel art sprite generation + processing pipeline for Godot games. Generate sprite sheets with Seedream, auto-process into Godot-ready assets (hframes, transparent PNG).

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
114
下载量
免费
免费
0
收藏
概述
安装方式
版本历史

pixel-asset-pipeline

🎮 Pixel Asset Pipeline

AI 生成像素游戏素材 → 自动处理为 Godot 可用格式。

Pipeline 概览

Prompt → AI生图(Seedream) → 去背景 → 切帧 → NEAREST缩放 → Godot sprite sheet + 单帧PNG

依赖

  • - Python 3.8+ with Pillow (pip install Pillow)

Quick Start

bash

1. 处理已有的大图


python scripts/processspritesheet.py raw_sprite.png --output-dir ./out --target-size 48 --cols 4

2. 批量生成+处理

python scripts/batchgenerate.py references/sampleconfig.json

支持的生成后端

后端脚本说明
Seedream (默认)lumi-work/脚本/生图/seedreamgenerate.py2048x2048,效果好
通义万相
lumi-work/脚本/生图/wanxgenerate.py | 备选 | | Gemini | OpenClaw image_generate | 备选 |

输出格式

  • - {name}spritesheet.png — 横排 sprite sheet,Godot 设置 hframes=N 即可
  • frames/{name}frame00.png ~ frame_XX.png — 单帧透明 PNG

Prompt 技巧

像素风 prompt 模板(英文效果最佳):

16-bit pixel art sprite sheet, [角色/物品描述], top-down RPG, [N] frames, white background, clean outline, no shading

示例:

  • - 角色:16-bit pixel art sprite sheet, green slime monster, top-down RPG, 4 frames idle animation, white background
  • 物品:pixel art, silver sword with blue glow, 16x16 icon, white background, game asset
  • 瓦片:pixel art tileset, grass and dirt path, top-down RPG, seamless tiles, white background

关键后缀:加 white background 或 black background 确保可去背景。

完整使用示例

  1. 1. 用 Seedream 生成:
bash python lumi-work/脚本/生图/seedreamgenerate.py 16-bit pixel art sprite sheet, red dragon, 4 frames, white background dragonraw.png
  1. 2. 处理为 Godot 素材:
bash python scripts/processspritesheet.py dragonraw.png --output-dir ./gameassets/dragon --target-size 64 --cols 4
  1. 3. 在 Godot 中:Texture2D → Hframes = 4,搞定。

scripts/

  • - processspritesheet.py — 单图处理(去背景→切帧→缩放→输出)
  • batch_generate.py — 批量生成+处理(读JSON配置)

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 pixel-asset-pipeline-1775940257 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 pixel-asset-pipeline-1775940257 技能

通过命令行安装

skillhub install pixel-asset-pipeline-1775940257

下载

⬇ 下载 pixel-asset-pipeline v1.0.0(免费)

文件大小: 8.64 KB | 发布时间: 2026-4-12 10:59

v1.0.0 最新 2026-4-12 10:59
Initial release of pixel-asset-pipeline.

- AI-powered pixel art pipeline for Godot games: generate and process sprite sheets automatically.
- Supports Seedream, 通义万相, and Gemini as image generation backends.
- Processes sprites: removes background, slices frames, resizes using NEAREST, outputs Godot-ready sprite sheets and PNGs.
- Easy CLI usage for both single images and batch jobs.
- Includes prompt tips for best AI sprite results.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部