sprite sheet utility
Project description
Sprite Sheet
This project develops a uitility box which uses to generate a sprite sheet
Documentaion
The project contains six different parts, include:
Waypoint 1: Find the Most Common Color in an Image
- This function is a tool developed to find the most common color which can be considered as the background color.
Waypoint 2: Write a Class Sprite
- This class is developed to generate a sprite instance which contains the sprite's parameter itself.
Waypoint 3: Find Sprites in an Image
- This function is developed to generate a label map and sort out each sprite in the input image.
Waypoint 4: Draw Sprite Label Bounding Boxes
- This function is developed to create a sprite sheet and its bounding box from a label map and a list of sprite object in the label map itself.
Waypoint 5: Write a Class SpriteSheet
- This class is a automatic machine which have two build-in functions to create a sprite sheet image or a label map and a list of sprite object directly from the instanitiated image.
Waypoint 6: Package and Distribute the Python Library
- This is a pakaging process to create a downloadable and installable distribution of the library for users to easily download, install and use as a python buid-in library
Usage
- This lib is comparable with [python3] only. if you don't have one, you can download the latest version here.
- Get source code from git or a distribution of the library from PyPI, for example:
$ git clone https://github.com/intek-training-jsc/sprite-sheet-tcthai.git
- Import and use the library as any other buid-in lib. Example:
>>> from spriteutil.spritesheet import SpriteSheet
>>> sprite_sheet = SpriteSheet('some_image.png')
>>> sprites, labels = sprite_sheet.find_sprites()
>>> image = sprite_sheet.create_sprite_labels_image()
>>> image.save('barbarian_bounding_boxes.png')
Contact
- Email: thai.tran@f4.intek.edu.vn
- Phone: (+84) 945 577 133
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for sprite-sheet-tcthai-1.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 501426cd37b01ac5f3d1bfa7d9d12aaae655f06fbca74e5d7482b669b520bb40 |
|
MD5 | 70964fe91c28b21d9e691bce9169bcc4 |
|
BLAKE2b-256 | 6665d33603b73b9313ba36cf2b7762c9a98bdf576925565b967b50f6cfcee753 |
Close
Hashes for sprite_sheet_tcthai-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b9e9316af165b4bfb7ac4e900b501837ada8cfb31c194dcf23a8e172995727c5 |
|
MD5 | 30a0e29136e26d6d23733d6f4c48dbd5 |
|
BLAKE2b-256 | ffda22927c399e67f28a71edb511ea044b523928829cb0b1661198d3f0cabcb7 |