mirror of
https://github.com/maxartz15/MA_TextureAtlasser.git
synced 2025-06-30 05:46:06 +02:00
Export presets, wrap uv's, bugfixes and formatting.
[MA_TextureAtlas] Updated export window to use scriptable asset export presets. The option to wrap uv's (default = true). Bigfixes and code formatting.
This commit is contained in:
@ -16,7 +16,7 @@ namespace MA_TextureAtlasserPro
|
||||
public MA_TextureAtlasserProQuad selectedTextureQuad;
|
||||
private Rect editorWorkRect;
|
||||
public bool showTextures = false;
|
||||
|
||||
public MA_TextureAtlasserProExportSettings exportSettings;
|
||||
|
||||
//Data
|
||||
public Vector2 textureAtlasSize;
|
||||
|
@ -0,0 +1,63 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
using MA_Texture;
|
||||
|
||||
namespace MA_TextureAtlasserPro
|
||||
{
|
||||
[System.Serializable]
|
||||
public class MA_TextureAtlasserProExportSettings : ScriptableObject
|
||||
{
|
||||
[HideInInspector]
|
||||
public bool canModify = true;
|
||||
|
||||
public ModelExportSettings modelExportSettings = new ModelExportSettings();
|
||||
public TextureExportSettings textureExportSettings = new TextureExportSettings();
|
||||
}
|
||||
|
||||
[System.Serializable]
|
||||
public class ModelExportSettings
|
||||
{
|
||||
[Header("Model settings:")]
|
||||
public ModelFormat modelFormat = ModelFormat.Obj;
|
||||
public bool replaceModel = false;
|
||||
public bool uvFlipY = true;
|
||||
public int uvChannel = 0;
|
||||
public bool uvWrap = true;
|
||||
}
|
||||
|
||||
[System.Serializable]
|
||||
public class TextureExportSettings
|
||||
{
|
||||
[Header("Texture settings:")]
|
||||
public TextureFormat textureFormat = TextureFormat.Png;
|
||||
public TextureType textureType = TextureType.Default;
|
||||
public MA_TextureUtils.TextureScaleMode textureScaleMode = MA_TextureUtils.TextureScaleMode.Bilinear;
|
||||
}
|
||||
|
||||
public enum ExportPreset
|
||||
{
|
||||
Custom,
|
||||
Default,
|
||||
Sprites,
|
||||
ReplaceObjMeshes
|
||||
}
|
||||
|
||||
public enum ModelFormat
|
||||
{
|
||||
None,
|
||||
Obj
|
||||
}
|
||||
|
||||
public enum TextureFormat
|
||||
{
|
||||
None,
|
||||
Png
|
||||
}
|
||||
|
||||
public enum TextureType
|
||||
{
|
||||
Default,
|
||||
Sprite,
|
||||
SpriteSliced
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user