Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/0keponline/mc2svg
Easily convert any Minecraft skin face to SVG with this code & online API.
https://github.com/0keponline/mc2svg
api minecraft minecraft-api minecraft-avatar skin svg unlicense
Last synced: 6 days ago
JSON representation
Easily convert any Minecraft skin face to SVG with this code & online API.
- Host: GitHub
- URL: https://github.com/0keponline/mc2svg
- Owner: 0KepOnline
- License: unlicense
- Created: 2023-12-14T17:54:09.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-06-08T14:06:59.000Z (5 months ago)
- Last Synced: 2024-06-08T15:26:45.870Z (5 months ago)
- Topics: api, minecraft, minecraft-api, minecraft-avatar, skin, svg, unlicense
- Language: C#
- Homepage: https://scenariopla.net/mc2svg/
- Size: 9.77 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ![](https://scenariopla.net/mc2svg/get?texture=a6598aaa29dfc6a2026d6f4a10c4f5c1707935ecba5f71cc168039742ece0e7a&size=24&smaller=1) [MC2SVG](https://scenariopla.net/mc2svg/)
MC2SVG is a fan-made website that provides a simple API endpoint for converting Minecraft faces to Scalable Vector Graphics. It's running on a fairly simple C# code, which is published here.
Uses [Big Gustave](https://github.com/EliotJones/BigGustave) to read PNGs & [Newtonsoft.Json](https://github.com/JamesNK/Newtonsoft.Json) to parse Minecraft API responses.
## Example SVGs
| ![ScenarioPlanet](https://scenariopla.net/mc2svg/get?nickname=ScenarioPlanet&size=128) | ![Luigifan100](https://scenariopla.net/mc2svg/get?nickname=Luigifan100&size=128) | ![SenatorApple](https://scenariopla.net/mc2svg/get?nickname=SenatorApple&size=128) | ![SlimeDiamond](https://scenariopla.net/mc2svg/get?nickname=SlimeDiamond&size=128) | ![eleanorsilly](https://scenariopla.net/mc2svg/get?nickname=eleanorsilly&size=128) | ![stromhurst](https://scenariopla.net/mc2svg/get?nickname=stromhurst&size=128) |
|-|-|-|-|-|-|## Usage
Endpoint documentation is available on the site: https://scenariopla.net/mc2svg/.
## Command line arguments
Main arguments are `input data` and `input data type`, which is a number corresponding to this table:
| Input data type | Input data |
|-----------------|------------------------------------------------------|
| `0` | Player UUID |
| `1` | Player nickname |
| `2` | Skin texture SHA-256 (key on textures.minecraft.net) |Also, you can specify these optional parameters (order is required):
`[input data] [input data type] [hat overlay] [size] [crisp edges] [no stroke]`
Example set of arguments: `ScenarioPlanet 1 0 256 1 0`
| Argument | Description |
|---------------|-----------------------------------------------------------|
| `hat overlay` | use hat overlay layer, **boolean**, *default: true* |
| `size` | size in pixels, **number** > 0, *default: 512* |
| `crisp edges` | add crispEdges attribute, **boolean**, *default: true* |
| `no stroke` | don't add stroke attribute, **boolean**, *default: false* |