Skip to main content

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

Metadata

Release files for sprite-sheet-tcthai 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sprite-sheet-tcthai 1.0.1
File Size Uploaded
sprite-sheet-tcthai-1.0.1.tar.gz 2.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sprite-sheet-tcthai 1.0.1
File Interpreter ABI Platform
sprite_sheet_tcthai-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 5.2 kB

Release files / sprite-sheet-tcthai-1.0.1.tar.gz

Download URL sprite-sheet-tcthai-1.0.1.tar.gz
Size 2.1 kB
Tags Source
SHA-256 checksum
How to use checksums
501426cd37b01ac5f3d1bfa7d9d12aaae655f06fbca74e5d7482b669b520bb40
BLAKE2b-256 checksum
How to use checksums
6665d33603b73b9313ba36cf2b7762c9a98bdf576925565b967b50f6cfcee753
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.0 CPython/3.8.1

Release files / sprite_sheet_tcthai-1.0.1-py3-none-any.whl

Download URL sprite_sheet_tcthai-1.0.1-py3-none-any.whl
Size 3.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b9e9316af165b4bfb7ac4e900b501837ada8cfb31c194dcf23a8e172995727c5
BLAKE2b-256 checksum
How to use checksums
ffda22927c399e67f28a71edb511ea044b523928829cb0b1661198d3f0cabcb7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.0 CPython/3.8.1

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page