Add gdx-tools dependency, add TextureSetup class

This commit is contained in:
Matt Low 2018-11-22 17:36:28 +04:00
parent 9e8e00e9af
commit 7ff4d3307a
2 changed files with 18 additions and 0 deletions

View File

@ -44,6 +44,7 @@ project(":desktop") {
dependencies { dependencies {
compile project(":core") compile project(":core")
compile "com.badlogicgames.gdx:gdx-tools:$gdxVersion"
compile "com.badlogicgames.gdx:gdx-backend-lwjgl:$gdxVersion" compile "com.badlogicgames.gdx:gdx-backend-lwjgl:$gdxVersion"
compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop" compile "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
compile "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-desktop" compile "com.badlogicgames.gdx:gdx-box2d-platform:$gdxVersion:natives-desktop"

View File

@ -0,0 +1,17 @@
package com.me.brickbuster.desktop;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.tools.texturepacker.TexturePacker;
public class TextureSetup {
public static void main(String[] args) {
TexturePacker.Settings settings = new TexturePacker.Settings();
settings.paddingX = 8;
settings.paddingY = 8;
settings.filterMin = Texture.TextureFilter.MipMapLinearLinear;
settings.filterMag = Texture.TextureFilter.MipMapLinearLinear;
TexturePacker.process(settings,"sprites", "./", "textures");
}
}