Skip to main content
Glama
viktor-haag

scuffed-painter

by viktor-haag

Scuffed Painter

Pillowを使用して描画コマンドをラスター画像にレンダリングするMCP(Model Context Protocol)サーバーです。次の2つのツールを公開しています。

  • draw_image — コマンドをレンダリングし、結果をインラインPNG画像として返します。

  • draw_image_to_file — コマンドをレンダリングし、結果をファイルに保存します。

サポートされている図形は5つで、それぞれは "shape" フィールドで判別されるJSONオブジェクトです。

shape

パラメーター

line

start, end, color, width

rect

box (left, top, right, bottom), fill, outline, width

circle

center, radius, fill, outline, width

ellipse

box (x0, y0, x1, y1), fill, outline, width

triangle

points (厳密に3つの頂点), fill, outline, width

コマンドは、固定サイズの白いキャンバス上でリストの順序に従って実行されます。後続のコマンドは先行するコマンドの上に描画されます。色はCSSの色名または16進コードで指定します。

インストール

pip install .

これにより、stdio経由でMCPサーバーを起動する scuffed-painter コンソールスクリプトが提供されます(デフォルト)。python -m scuffed_painter も同等の代替手段です。同じコマンドで、HTTP(MCP Streamable HTTP トランスポート)経由でサーバーを提供することもできます。

scuffed-painter                              # stdio transport (default)
scuffed-painter --transport http             # HTTP on 127.0.0.1:8000
scuffed-painter --transport http --host H --port P

--host--port はHTTPトランスポートにのみ適用されます。デフォルトは 127.0.0.18000 です。必要に応じて --enable-cors でCORSを有効にできます。

Related MCP server: openai-imagegen-mcp

MCPホスト設定

stdio

MCPホストのstdioサーバー設定にサーバーを追加してください。

{
  "mcpServers": {
    "scuffed-painter": {
      "command": "scuffed-painter"
    }
  }
}

注: PATHが制限されたホスト上、または仮想環境(virtualenv)内で実行している場合は、インストールされた scuffed-painter スクリプトの絶対パスを使用してください(例: which scuffed-painter が出力するパス)。

Streamable HTTP

サーバーを自分で起動し、MCPホストをエンドポイント(パスは /mcp)に向けてください。

scuffed-painter --transport http --host 127.0.0.1 --port 8000
{
  "mcpServers": {
    "scuffed-painter": {
      "type": "streamable-http",
      "url": "http://127.0.0.1:8000/mcp"
    }
  }
}

(キー名は、使用しているMCPホストの設定形式に合わせて調整してください。)

注: draw_image_to_file を使用する場合、output_path はサーバーが実行されているマシンを指します。stdio経由ではMCPクライアントと同じホストですが、HTTP経由でサーバーにアクセスする場合はサーバーのホストになります。

ツール呼び出しの例

{
  "width": 200,
  "height": 200,
  "commands": [
    {"shape": "circle", "center": [100, 80], "radius": 50, "fill": "gold", "outline": "orange", "width": 3},
    {"shape": "triangle", "points": [[50, 170], [150, 170], [100, 70]], "fill": "darkgreen"},
    {"shape": "line", "start": [20, 185], "end": [180, 185], "color": "black", "width": 2}
  ]
}

開発

リポジトリ構成:

scuffed_painter/          the package
  server.py             server, tools, command models, rendering
  __init__.py           re-exports mcp, defines __version__
  __main__.py           python -m scuffed_painter support
  py.typed              typing marker
tests/                  pytest suite (in-process fastmcp.Client)

セットアップとテストの実行:

pip install -e ".[dev]"
python -m pytest
Install Server
A
license - permissive license
A
quality
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

View all related MCP servers

Related MCP Connectors

  • Generate images, GIFs, and PDFs from HTML, URLs, or templates — from your AI agent.

  • Create diagrams in chat, rendered as live interactive draw.io diagrams. 10,000+ searchable shapes.

  • Generate logos, social posts, app screenshots, comic panels & visual-novel assets from prompts.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/viktor-haag/scuffed-painter'

If you have feedback or need assistance with the MCP directory API, please join our Discord server