Skip to main content

Yummy Optimizer for Gorgeous Assets

Project description

Build Status PYPI Version License Gitter

YOGA is a command-line tool and a library that can:

  • convert and optimize images from various format to JPEG and PNG,

  • convert and optimize 3D models from various formats to GLB.

Images are opened using Pillow and optimized using Guetzli (for JPEGs) and Zopflipng (for PNGs).

3D Models are converted and optimized using assimp. If models contain or reference images, they are processed by YOGA’s image optimizer.

Convert and optimize an image from CLI:

yoga  image  input.png  output.png
yoga  image  --output-format=jpeg  --jpeg-quality=84  input.png  output.jpg
yoga  image  --help

Convert and optimize a 3D model from CLI:

yoga  model  input.fbx  output.glb
yoga  model  --no-graph-optimization  --no-meshes-optimization  --image-output-format=jpeg  --image-jpeg-quality=84  input.fbx  output.glb
yoga  model  --help

Install

From PYPI (Linux / Mac OS?)

Run the following command (as root on Linux):

pip install yoga

From this repository (Linux / Mac OS?)

Clone the repository:

git clone https://github.com/wanadev/yoga.git

Go to the project’s directory:

cd yoga

Build and install using the following command:

python setup.py install

Windows

Building YOGA on Windows is not supported yet…

Changelog

  • 0.10.1:

    • Fixes an issue that occures when output file does not already exist

  • 0.10.0:

    • Prevent overwriting of the output file when an error occurs (#17)

    • Unicode path support (#16)

  • 0.10.0b1:

    • Verbose and quiet modes,

    • Allows to pass textures from memory instead of looking on the filesystem,

    • Allows to pass a fallback texture instead of raising an error.

  • 0.9.1b1:

    • Automatic selection of the output format (png or jpeg),

    • Prevent duplication of textures that are shared between materials,

    • Fixes Windows paths of textures.

  • 0.9.0b1: First release (only GLB output for models, no image auto output format)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yoga-0.10.1.tar.gz (2.3 MB view details)

Uploaded Source

File details

Details for the file yoga-0.10.1.tar.gz.

File metadata

  • Download URL: yoga-0.10.1.tar.gz
  • Upload date:
  • Size: 2.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Python-urllib/2.7

File hashes

Hashes for yoga-0.10.1.tar.gz
Algorithm Hash digest
SHA256 d71a8244d82c4f08f171979ea5d93eda68c0e2e9cbc2a834315a712b0d100662
MD5 484c854213f969dac6becfc9eca885a2
BLAKE2b-256 2dfb9cd71dd87eb71199da528c00b26a0498bc83334c2c98b6924a08d7f0e68d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page