A simple android assets generator
Project description
android-asset-generator
Description
android-assset-generator is a command line program for generate ldpi, mdpi, hdpi, xhdpi, xxhdpi and xxxhdpi density images for your Android Studio Project.
Requeriments
- python-resize-image View package
Installing
pip install android-asset-generator
Usage
-
Prepare a folder that contains only the images you want to convert to the different densities.
-
Run the following command.
android-asset-generator path density
Argument | Description | Example |
---|---|---|
path | Full path string of your asset folder. It can be a path or "this" if your console workspace is the asset folder | C:\Users\MyUser\Desktop\img xhdpi or this |
density | The source density. If your images are mdpi, put mdpi as argument | ldpi, mdpi, hdpi, xhdpi, xxhdpi or xxxhdpi |
Note: You must not switch order of the arguments
- The generated images will be saved in different folders within the specified path following the Android Studio standard:
- drawable-ldpi
- drawable-mdpi
- drawable-hdpi
- drawable-xhdpi
- drawable-xxhdpi
- drawable-xxxhdpi
- The source images will be moved to the corresponding folder without having suffered alterations.
- The last step is to import the generated folders to your Android Studio. project
Examples
android-asset-generator C:\Users\MyUser\Desktop\img xhdpi
The asset folder path is C:\Users\MyUser\Desktop\img and asset density is xhdpi
android-asset-generator this
The asset folder path is the console current directory and asset density is hdpi by default
Compatibility
Operating System | Test Results |
---|---|
Windows 10 | passed |
MacOS | No tested |
Linux | No tested |
GitHub Repository
To be uploaded
Licence
The project is licensed under the MIT License
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
Built Distribution
Close
Hashes for android-asset-generator-1.0.4.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d31cd265afd0c6456109c92d328475d371939eddbfc3b13c875ee1ff66c5d9ba |
|
MD5 | 802e59c38c42646f89454c1a962ab67f |
|
BLAKE2b-256 | 3cdff5f839ab1a66a157253f11a9658d0efe4ac96b17bc711672d42ad4d48d4c |
Close
Hashes for android_asset_generator-1.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2e5df62abe05e22dce80823f02409d9cb22a7681095e70f967753e2bdd5e34ad |
|
MD5 | 7897130376cf484dd711c6c3deb92abd |
|
BLAKE2b-256 | b6926e23659271afc406e13e915ea2f0fbac44da31b5a44487d1ecde01a8ca45 |