Add in proper replacing for raw texture types
This commit is contained in:
parent
4b461f2d23
commit
33fff8e4de
Binary file not shown.
@ -69,6 +69,8 @@ namespace FirstPlugin
|
||||
public void Load(System.IO.Stream stream)
|
||||
{
|
||||
CanSave = true;
|
||||
CanRename = true;
|
||||
CanReplace = true;
|
||||
|
||||
using (var reader = new FileReader(stream))
|
||||
{
|
||||
@ -113,6 +115,50 @@ namespace FirstPlugin
|
||||
}
|
||||
}
|
||||
|
||||
public override void Replace(string FileName)
|
||||
{
|
||||
GenericTextureImporterList importer = new GenericTextureImporterList(SupportedFormats);
|
||||
GenericTextureImporterSettings settings = new GenericTextureImporterSettings();
|
||||
|
||||
importer.LoadSettings(new List<GenericTextureImporterSettings>() { settings, });
|
||||
|
||||
if (Utils.GetExtension(FileName) == ".dds" ||
|
||||
Utils.GetExtension(FileName) == ".dds2")
|
||||
{
|
||||
settings.LoadDDS(FileName);
|
||||
ApplySettings(settings);
|
||||
UpdateEditor();
|
||||
}
|
||||
else
|
||||
{
|
||||
settings.LoadBitMap(FileName);
|
||||
if (importer.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
if (settings.GenerateMipmaps && !settings.IsFinishedCompressing)
|
||||
{
|
||||
settings.DataBlockOutput.Clear();
|
||||
settings.DataBlockOutput.Add(settings.GenerateMips(importer.CompressionMode));
|
||||
}
|
||||
|
||||
ApplySettings(settings);
|
||||
UpdateEditor();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void ApplySettings(GenericTextureImporterSettings settings)
|
||||
{
|
||||
//Combine all arrays
|
||||
IGZStructure.TextureInfo.ImageData = Utils.CombineByteArray(
|
||||
settings.DataBlockOutput.ToArray());
|
||||
|
||||
this.Width = settings.TexWidth;
|
||||
this.Height = settings.TexHeight;
|
||||
this.Format = settings.Format;
|
||||
this.MipCount = settings.MipCount;
|
||||
this.Depth = settings.Depth;
|
||||
this.ArrayCount = (uint)settings.DataBlockOutput.Count;
|
||||
}
|
||||
|
||||
public override bool CanEdit { get; set; } = true;
|
||||
|
||||
@ -130,7 +176,11 @@ namespace FirstPlugin
|
||||
return IGZStructure.TextureInfo.ImageData;
|
||||
}
|
||||
|
||||
public override void OnClick(TreeView treeView)
|
||||
public override void OnClick(TreeView treeView) {
|
||||
UpdateEditor();
|
||||
}
|
||||
|
||||
private void UpdateEditor()
|
||||
{
|
||||
ImageEditorBase editor = (ImageEditorBase)LibraryGUI.GetActiveContent(typeof(ImageEditorBase));
|
||||
if (editor == null)
|
||||
|
@ -105,6 +105,10 @@ namespace Toolbox.Library.Forms
|
||||
}
|
||||
}
|
||||
|
||||
public void UpdateTextureIcon(ISingleTextureIconLoader texturIcon) {
|
||||
ObjectTree.LoadGenericTextureIcons(texturIcon);
|
||||
}
|
||||
|
||||
public void UpdateTextureIcon(ISingleTextureIconLoader texturIcon, Image image) {
|
||||
ObjectTree.UpdateTextureIcon(texturIcon,image );
|
||||
}
|
||||
|
@ -57,6 +57,15 @@ namespace Toolbox.Library.Forms
|
||||
foreach (TreeNode n in ((TreeNode)FileFormat).Nodes)
|
||||
FileRoot.Nodes.Add(n);
|
||||
}
|
||||
|
||||
for (int i = 0; i < FileRoot.FileNodes.Count; i++)
|
||||
{
|
||||
if (FileRoot.FileNodes[i].Item1.OpenFileFormatOnLoad)
|
||||
{
|
||||
if (FileRoot.FileNodes[i].Item2 is ArchiveFileWrapper)
|
||||
((ArchiveFileWrapper)FileRoot.FileNodes[i].Item2).OpenFileFormat(treeViewCustom1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void AddNodeCollection(TreeNodeCollection nodes, bool ClearNodes)
|
||||
|
252
Switch_Toolbox_Library/Forms/Editors/TextureImport/GenericTextureImporterList.Designer.cs
generated
Normal file
252
Switch_Toolbox_Library/Forms/Editors/TextureImport/GenericTextureImporterList.Designer.cs
generated
Normal file
@ -0,0 +1,252 @@
|
||||
namespace FirstPlugin
|
||||
{
|
||||
partial class GenericTextureImporterList
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(GenericTextureImporterSettings));
|
||||
this.button2 = new Toolbox.Library.Forms.STButton();
|
||||
this.button1 = new Toolbox.Library.Forms.STButton();
|
||||
this.listViewCustom1 = new Toolbox.Library.Forms.ListViewCustom();
|
||||
this.Name = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.Format = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.label2 = new Toolbox.Library.Forms.STLabel();
|
||||
this.label1 = new Toolbox.Library.Forms.STLabel();
|
||||
this.MipmapNum = new Toolbox.Library.Forms.STNumbericUpDown();
|
||||
this.WidthLabel = new Toolbox.Library.Forms.STLabel();
|
||||
this.HeightLabel = new Toolbox.Library.Forms.STLabel();
|
||||
this.pictureBox1 = new Toolbox.Library.Forms.PictureBoxCustom();
|
||||
this.formatComboBox = new Toolbox.Library.Forms.STComboBox();
|
||||
this.compressionModeCB = new Toolbox.Library.Forms.STComboBox();
|
||||
this.stLabel1 = new Toolbox.Library.Forms.STLabel();
|
||||
this.contentContainer.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.MipmapNum)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// contentContainer
|
||||
//
|
||||
this.contentContainer.Controls.Add(this.compressionModeCB);
|
||||
this.contentContainer.Controls.Add(this.stLabel1);
|
||||
this.contentContainer.Controls.Add(this.label2);
|
||||
this.contentContainer.Controls.Add(this.label1);
|
||||
this.contentContainer.Controls.Add(this.MipmapNum);
|
||||
this.contentContainer.Controls.Add(this.WidthLabel);
|
||||
this.contentContainer.Controls.Add(this.HeightLabel);
|
||||
this.contentContainer.Controls.Add(this.pictureBox1);
|
||||
this.contentContainer.Controls.Add(this.formatComboBox);
|
||||
this.contentContainer.Controls.Add(this.listViewCustom1);
|
||||
this.contentContainer.Controls.Add(this.button2);
|
||||
this.contentContainer.Controls.Add(this.button1);
|
||||
this.contentContainer.Size = new System.Drawing.Size(1092, 557);
|
||||
this.contentContainer.Controls.SetChildIndex(this.button1, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.button2, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.listViewCustom1, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.formatComboBox, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.pictureBox1, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.HeightLabel, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.WidthLabel, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.MipmapNum, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.label1, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.label2, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.stLabel1, 0);
|
||||
this.contentContainer.Controls.SetChildIndex(this.compressionModeCB, 0);
|
||||
//
|
||||
// button2
|
||||
//
|
||||
this.button2.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.button2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.button2.Location = new System.Drawing.Point(1009, 517);
|
||||
this.button2.Name = "button2";
|
||||
this.button2.Size = new System.Drawing.Size(79, 33);
|
||||
this.button2.TabIndex = 5;
|
||||
this.button2.Text = "Cancel";
|
||||
this.button2.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// button1
|
||||
//
|
||||
this.button1.DialogResult = System.Windows.Forms.DialogResult.OK;
|
||||
this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.button1.Location = new System.Drawing.Point(911, 517);
|
||||
this.button1.Name = "button1";
|
||||
this.button1.Size = new System.Drawing.Size(79, 33);
|
||||
this.button1.TabIndex = 4;
|
||||
this.button1.Text = "Ok";
|
||||
this.button1.UseVisualStyleBackColor = true;
|
||||
this.button1.Click += new System.EventHandler(this.button1_Click);
|
||||
//
|
||||
// listViewCustom1
|
||||
//
|
||||
this.listViewCustom1.BorderStyle = System.Windows.Forms.BorderStyle.None;
|
||||
this.listViewCustom1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
|
||||
this.Name,
|
||||
this.Format});
|
||||
this.listViewCustom1.Dock = System.Windows.Forms.DockStyle.Left;
|
||||
this.listViewCustom1.Location = new System.Drawing.Point(0, 25);
|
||||
this.listViewCustom1.Name = "listViewCustom1";
|
||||
this.listViewCustom1.OwnerDraw = true;
|
||||
this.listViewCustom1.Size = new System.Drawing.Size(237, 532);
|
||||
this.listViewCustom1.TabIndex = 6;
|
||||
this.listViewCustom1.UseCompatibleStateImageBehavior = false;
|
||||
this.listViewCustom1.View = System.Windows.Forms.View.Details;
|
||||
this.listViewCustom1.SelectedIndexChanged += new System.EventHandler(this.listViewCustom1_SelectedIndexChanged);
|
||||
//
|
||||
// Name
|
||||
//
|
||||
this.Name.Text = "Name";
|
||||
this.Name.Width = 104;
|
||||
//
|
||||
// Format
|
||||
//
|
||||
this.Format.Text = "Format";
|
||||
this.Format.Width = 133;
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Location = new System.Drawing.Point(756, 42);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(39, 13);
|
||||
this.label2.TabIndex = 22;
|
||||
this.label2.Text = "Format";
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Location = new System.Drawing.Point(757, 109);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(90, 13);
|
||||
this.label1.TabIndex = 21;
|
||||
this.label1.Text = "Number MipMaps";
|
||||
//
|
||||
// MipmapNum
|
||||
//
|
||||
this.MipmapNum.Location = new System.Drawing.Point(854, 107);
|
||||
this.MipmapNum.Name = "MipmapNum";
|
||||
this.MipmapNum.Size = new System.Drawing.Size(130, 20);
|
||||
this.MipmapNum.TabIndex = 20;
|
||||
this.MipmapNum.ValueChanged += new System.EventHandler(this.MipmapNum_ValueChanged);
|
||||
//
|
||||
// WidthLabel
|
||||
//
|
||||
this.WidthLabel.AutoSize = true;
|
||||
this.WidthLabel.Location = new System.Drawing.Point(757, 173);
|
||||
this.WidthLabel.Name = "WidthLabel";
|
||||
this.WidthLabel.Size = new System.Drawing.Size(35, 13);
|
||||
this.WidthLabel.TabIndex = 19;
|
||||
this.WidthLabel.Text = "Width";
|
||||
//
|
||||
// HeightLabel
|
||||
//
|
||||
this.HeightLabel.AutoSize = true;
|
||||
this.HeightLabel.Location = new System.Drawing.Point(757, 142);
|
||||
this.HeightLabel.Name = "HeightLabel";
|
||||
this.HeightLabel.Size = new System.Drawing.Size(38, 13);
|
||||
this.HeightLabel.TabIndex = 18;
|
||||
this.HeightLabel.Text = "Height";
|
||||
//
|
||||
// pictureBox1
|
||||
//
|
||||
this.pictureBox1.BackColor = System.Drawing.Color.Transparent;
|
||||
this.pictureBox1.BackgroundImage = Toolbox.Library.Properties.Resources.CheckerBackground;
|
||||
this.pictureBox1.Dock = System.Windows.Forms.DockStyle.Left;
|
||||
this.pictureBox1.Location = new System.Drawing.Point(237, 25);
|
||||
this.pictureBox1.Name = "pictureBox1";
|
||||
this.pictureBox1.Size = new System.Drawing.Size(513, 532);
|
||||
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
|
||||
this.pictureBox1.TabIndex = 17;
|
||||
this.pictureBox1.TabStop = false;
|
||||
//
|
||||
// formatComboBox
|
||||
//
|
||||
this.formatComboBox.BorderColor = System.Drawing.Color.Empty;
|
||||
this.formatComboBox.BorderStyle = System.Windows.Forms.ButtonBorderStyle.Solid;
|
||||
this.formatComboBox.ButtonColor = System.Drawing.Color.Empty;
|
||||
this.formatComboBox.FormattingEnabled = true;
|
||||
this.formatComboBox.Location = new System.Drawing.Point(853, 39);
|
||||
this.formatComboBox.Name = "formatComboBox";
|
||||
this.formatComboBox.ReadOnly = true;
|
||||
this.formatComboBox.Size = new System.Drawing.Size(233, 21);
|
||||
this.formatComboBox.TabIndex = 16;
|
||||
this.formatComboBox.SelectedIndexChanged += new System.EventHandler(this.formatComboBox_SelectedIndexChanged);
|
||||
//
|
||||
// compressionModeCB
|
||||
//
|
||||
this.compressionModeCB.BorderColor = System.Drawing.Color.Empty;
|
||||
this.compressionModeCB.BorderStyle = System.Windows.Forms.ButtonBorderStyle.Solid;
|
||||
this.compressionModeCB.ButtonColor = System.Drawing.Color.Empty;
|
||||
this.compressionModeCB.FormattingEnabled = true;
|
||||
this.compressionModeCB.Location = new System.Drawing.Point(854, 72);
|
||||
this.compressionModeCB.Name = "compressionModeCB";
|
||||
this.compressionModeCB.ReadOnly = true;
|
||||
this.compressionModeCB.Size = new System.Drawing.Size(233, 21);
|
||||
this.compressionModeCB.TabIndex = 30;
|
||||
this.compressionModeCB.SelectedIndexChanged += new System.EventHandler(this.compressionModeCB_SelectedIndexChanged);
|
||||
//
|
||||
// stLabel1
|
||||
//
|
||||
this.stLabel1.AutoSize = true;
|
||||
this.stLabel1.Location = new System.Drawing.Point(757, 75);
|
||||
this.stLabel1.Name = "stLabel1";
|
||||
this.stLabel1.Size = new System.Drawing.Size(100, 13);
|
||||
this.stLabel1.TabIndex = 29;
|
||||
this.stLabel1.Text = "Compression Mode:";
|
||||
//
|
||||
// BinaryTextureImporterList
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1096, 560);
|
||||
this.KeyPreview = true;
|
||||
this.Text = "Texture Importer";
|
||||
this.Load += new System.EventHandler(this.BinaryTextureImporterList_Load);
|
||||
this.KeyDown += new System.Windows.Forms.KeyEventHandler(this.BinaryTextureImporterList_KeyDown);
|
||||
this.contentContainer.ResumeLayout(false);
|
||||
this.contentContainer.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.MipmapNum)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
private Toolbox.Library.Forms.STButton button2;
|
||||
private Toolbox.Library.Forms.STButton button1;
|
||||
private Toolbox.Library.Forms.ListViewCustom listViewCustom1;
|
||||
private Toolbox.Library.Forms.STLabel label2;
|
||||
private Toolbox.Library.Forms.STLabel label1;
|
||||
private Toolbox.Library.Forms.STNumbericUpDown MipmapNum;
|
||||
private Toolbox.Library.Forms.STLabel WidthLabel;
|
||||
private Toolbox.Library.Forms.STLabel HeightLabel;
|
||||
private Toolbox.Library.Forms.PictureBoxCustom pictureBox1;
|
||||
private Toolbox.Library.Forms.STComboBox formatComboBox;
|
||||
private System.Windows.Forms.ColumnHeader Name;
|
||||
private System.Windows.Forms.ColumnHeader Format;
|
||||
private Toolbox.Library.Forms.STComboBox compressionModeCB;
|
||||
private Toolbox.Library.Forms.STLabel stLabel1;
|
||||
}
|
||||
}
|
@ -0,0 +1,268 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
using System.Windows.Forms;
|
||||
using Toolbox.Library;
|
||||
using Toolbox.Library.Forms;
|
||||
|
||||
namespace FirstPlugin
|
||||
{
|
||||
public partial class GenericTextureImporterList : STForm
|
||||
{
|
||||
public STCompressionMode CompressionMode = STCompressionMode.Fast;
|
||||
|
||||
public int SelectedIndex = -1;
|
||||
public bool ForceMipCount = false;
|
||||
|
||||
public uint SelectedMipCount
|
||||
{
|
||||
set
|
||||
{
|
||||
if (MipmapNum.Maximum <= value)
|
||||
MipmapNum.Value = value;
|
||||
}
|
||||
get
|
||||
{
|
||||
return (uint)MipmapNum.Value;
|
||||
}
|
||||
}
|
||||
|
||||
private bool IsLoaded = false;
|
||||
|
||||
public GenericTextureImporterList(TEX_FORMAT[] SupportedFormats)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
CanResize = false;
|
||||
|
||||
listViewCustom1.FullRowSelect = true;
|
||||
listViewCustom1.CanResizeList = true;
|
||||
|
||||
//Add enums
|
||||
foreach (TEX_FORMAT format in SupportedFormats)
|
||||
{
|
||||
formatComboBox.Items.Add(format);
|
||||
}
|
||||
|
||||
compressionModeCB.Items.Add("Fast (Lower Qaulity)");
|
||||
compressionModeCB.Items.Add("Normal (Good Qaulity)");
|
||||
|
||||
compressionModeCB.SelectedIndex = 0;
|
||||
compressionModeCB.Visible = false;
|
||||
formatComboBox.SelectedIndex = 0;
|
||||
|
||||
IsLoaded = true;
|
||||
|
||||
button1.Select();
|
||||
}
|
||||
GenericTextureImporterSettings SelectedTexSettings;
|
||||
|
||||
public List<GenericTextureImporterSettings> settings = new List<GenericTextureImporterSettings>();
|
||||
public void LoadSetting(GenericTextureImporterSettings setting)
|
||||
{
|
||||
settings.Add(setting);
|
||||
|
||||
listViewCustom1.Items.Add(setting.TexName).SubItems.Add(setting.Format.ToString());
|
||||
listViewCustom1.Items[0].Selected = true;
|
||||
listViewCustom1.Select();
|
||||
}
|
||||
public void LoadSettings(List<GenericTextureImporterSettings> s)
|
||||
{
|
||||
settings = s;
|
||||
|
||||
foreach (var setting in settings)
|
||||
{
|
||||
listViewCustom1.Items.Add(setting.TexName).SubItems.Add(setting.Format.ToString());
|
||||
}
|
||||
listViewCustom1.Items[0].Selected = true;
|
||||
listViewCustom1.Select();
|
||||
}
|
||||
|
||||
private Thread Thread;
|
||||
public void SetupSettings()
|
||||
{
|
||||
if (SelectedTexSettings.Format == TEX_FORMAT.UNKNOWN || SelectedIndex == -1)
|
||||
return;
|
||||
|
||||
|
||||
WidthLabel.Text = $"Width {SelectedTexSettings.TexWidth}";
|
||||
HeightLabel.Text = $"Height {SelectedTexSettings.TexHeight}";
|
||||
|
||||
if (Thread != null && Thread.IsAlive)
|
||||
Thread.Abort();
|
||||
|
||||
if (formatComboBox.SelectedItem is TEX_FORMAT)
|
||||
{
|
||||
SelectedTexSettings.Format = (TEX_FORMAT)formatComboBox.SelectedItem;
|
||||
|
||||
listViewCustom1.Items[SelectedIndex].SubItems[1].Text = SelectedTexSettings.Format.ToString();
|
||||
}
|
||||
|
||||
if (SelectedTexSettings.Format == TEX_FORMAT.BC7_UNORM ||
|
||||
SelectedTexSettings.Format == TEX_FORMAT.BC7_TYPELESS ||
|
||||
SelectedTexSettings.Format == TEX_FORMAT.BC7_UNORM_SRGB)
|
||||
{
|
||||
compressionModeCB.Visible = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
compressionModeCB.Visible = false;
|
||||
}
|
||||
|
||||
Bitmap bitmap = Toolbox.Library.Imaging.GetLoadingImage();
|
||||
|
||||
if (compressionModeCB.SelectedIndex == 0)
|
||||
CompressionMode = STCompressionMode.Fast;
|
||||
else
|
||||
CompressionMode = STCompressionMode.Normal;
|
||||
|
||||
Thread = new Thread((ThreadStart)(() =>
|
||||
{
|
||||
SelectedTexSettings.IsFinishedCompressing = false;
|
||||
ToggleOkButton(false);
|
||||
|
||||
pictureBox1.Image = bitmap;
|
||||
|
||||
var mips = SelectedTexSettings.GenerateMipList(CompressionMode);
|
||||
SelectedTexSettings.DataBlockOutput.Clear();
|
||||
SelectedTexSettings.DataBlockOutput.Add(Utils.CombineByteArray(mips.ToArray()));
|
||||
|
||||
ToggleOkButton(true);
|
||||
SelectedTexSettings.IsFinishedCompressing = true;
|
||||
|
||||
if (SelectedTexSettings.DataBlockOutput.Count > 0) {
|
||||
if (SelectedTexSettings.Format == TEX_FORMAT.BC5_SNORM)
|
||||
{
|
||||
bitmap = DDSCompressor.DecompressBC5(mips[0],
|
||||
(int)SelectedTexSettings.TexWidth, (int)SelectedTexSettings.TexHeight, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
bitmap = STGenericTexture.DecodeBlockGetBitmap(mips[0],
|
||||
SelectedTexSettings.TexWidth, SelectedTexSettings.TexHeight, SelectedTexSettings.Format, new byte[0]);
|
||||
}
|
||||
}
|
||||
|
||||
mips.Clear();
|
||||
|
||||
if (pictureBox1.InvokeRequired)
|
||||
{
|
||||
pictureBox1.Invoke((MethodInvoker)delegate {
|
||||
pictureBox1.Image = bitmap;
|
||||
pictureBox1.Refresh();
|
||||
});
|
||||
}
|
||||
}));
|
||||
Thread.Start();
|
||||
|
||||
}
|
||||
|
||||
private void ToggleOkButton(bool Enable)
|
||||
{
|
||||
if (button1.InvokeRequired)
|
||||
{
|
||||
button1.Invoke((MethodInvoker)delegate {
|
||||
button1.Enabled = Enable;
|
||||
});
|
||||
}
|
||||
else
|
||||
button1.Enabled = Enable;
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void formatComboBox_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (listViewCustom1.SelectedItems.Count > 1)
|
||||
{
|
||||
foreach (int index in listViewCustom1.SelectedIndices)
|
||||
{
|
||||
if (formatComboBox.SelectedItem is TEX_FORMAT)
|
||||
{
|
||||
settings[index].Format = (TEX_FORMAT)formatComboBox.SelectedItem;
|
||||
listViewCustom1.Items[index].SubItems[1].Text = settings[index].Format.ToString();
|
||||
}
|
||||
}
|
||||
|
||||
SetupSettings();
|
||||
}
|
||||
else if (formatComboBox.SelectedIndex > -1 && SelectedTexSettings != null)
|
||||
{
|
||||
SetupSettings();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void listViewCustom1_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (listViewCustom1.SelectedItems.Count == 1)
|
||||
{
|
||||
SelectedIndex = listViewCustom1.SelectedIndices[0];
|
||||
|
||||
SelectedTexSettings = settings[listViewCustom1.SelectedIndices[0]];
|
||||
formatComboBox.SelectedItem = SelectedTexSettings.Format;
|
||||
|
||||
SetupSettings();
|
||||
|
||||
if (ForceMipCount)
|
||||
MipmapNum.Maximum = SelectedTexSettings.MipCount;
|
||||
else
|
||||
{
|
||||
MipmapNum.Maximum = STGenericTexture.GenerateTotalMipCount(
|
||||
SelectedTexSettings.TexWidth, SelectedTexSettings.TexHeight) + 1;
|
||||
}
|
||||
|
||||
MipmapNum.Value = SelectedTexSettings.MipCount;
|
||||
}
|
||||
}
|
||||
|
||||
private void BinaryTextureImporterList_Load(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void MipmapNum_ValueChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsLoaded)
|
||||
return;
|
||||
|
||||
if (MipmapNum.Value > 0)
|
||||
SelectedTexSettings.MipCount = (uint)MipmapNum.Value;
|
||||
else
|
||||
SelectedTexSettings.MipCount = 1;
|
||||
|
||||
SetupSettings();
|
||||
}
|
||||
|
||||
private void BinaryTextureImporterList_KeyDown(object sender, KeyEventArgs e)
|
||||
{
|
||||
if (e.KeyCode == Keys.Enter)
|
||||
{
|
||||
if (button1.Enabled)
|
||||
{
|
||||
DialogResult = DialogResult.OK;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void compressionModeCB_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (formatComboBox.SelectedIndex > -1 && SelectedTexSettings != null)
|
||||
{
|
||||
SetupSettings();
|
||||
}
|
||||
}
|
||||
|
||||
private void ImgDimComb_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,328 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="pictureBox1.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAAlgAAAJYCAMAAACJuGjuAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6
|
||||
JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAADAFBMVEXMzMzNzc3Ozs7Pz8/Q0NDR0dHS
|
||||
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q139oVZ/QQ
|
||||
mGk4zW7tt3aFGa0JAhPXKv5Grfv8ckaj93+veSuXxEAIUwAAAABJRU5ErkJggg==
|
||||
</value>
|
||||
</data>
|
||||
</root>
|
@ -0,0 +1,194 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Imaging;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Toolbox.Library;
|
||||
using Toolbox.Library.IO;
|
||||
|
||||
namespace FirstPlugin
|
||||
{
|
||||
public class GenericTextureImporterSettings
|
||||
{
|
||||
public GenericTextureImporterSettings()
|
||||
{
|
||||
}
|
||||
|
||||
public string TexName;
|
||||
|
||||
public uint MipCount;
|
||||
|
||||
public uint Depth = 1;
|
||||
|
||||
public uint TexWidth;
|
||||
|
||||
public uint TexHeight;
|
||||
|
||||
public TEX_FORMAT Format = TEX_FORMAT.BC1_UNORM_SRGB;
|
||||
|
||||
public STChannelType RedComp = STChannelType.Red;
|
||||
public STChannelType GreenComp = STChannelType.Green;
|
||||
public STChannelType BlueComp = STChannelType.Blue;
|
||||
public STChannelType AlphaComp = STChannelType.Alpha;
|
||||
|
||||
public List<byte[]> DataBlockOutput = new List<byte[]>();
|
||||
public List<byte[]> DecompressedData = new List<byte[]>();
|
||||
|
||||
public bool GenerateMipmaps = false; //If bitmap and count more that 1 then generate
|
||||
public float alphaRef = 0.5f;
|
||||
|
||||
public bool IsFinishedCompressing = false;
|
||||
|
||||
public void LoadDDS(string FileName, byte[] FileData = null)
|
||||
{
|
||||
TexName = STGenericTexture.SetNameFromPath(FileName);
|
||||
|
||||
DDS dds = new DDS();
|
||||
|
||||
if (FileData != null)
|
||||
dds.Load(new FileReader(new MemoryStream(FileData)));
|
||||
else
|
||||
dds.Load(new FileReader(FileName));
|
||||
MipCount = dds.header.mipmapCount;
|
||||
TexWidth = dds.header.width;
|
||||
TexHeight = dds.header.height;
|
||||
|
||||
var surfaces = DDS.GetArrayFaces(dds, dds.ArrayCount);
|
||||
|
||||
RedComp = dds.RedChannel;
|
||||
GreenComp = dds.GreenChannel;
|
||||
BlueComp = dds.BlueChannel;
|
||||
AlphaComp = dds.AlphaChannel;
|
||||
|
||||
foreach (var surface in surfaces)
|
||||
DataBlockOutput.Add(Utils.CombineByteArray(surface.mipmaps.ToArray()));
|
||||
|
||||
Format = dds.Format;
|
||||
}
|
||||
|
||||
public void LoadASTC(string FileName)
|
||||
{
|
||||
DecompressedData.Clear();
|
||||
TexName = STGenericTexture.SetNameFromPath(FileName);
|
||||
|
||||
ASTC astc = new ASTC();
|
||||
astc.Load(new FileStream(FileName, FileMode.Open));
|
||||
|
||||
MipCount = 0;
|
||||
|
||||
TexWidth = (uint)astc.Width;
|
||||
TexHeight = (uint)astc.Height;
|
||||
|
||||
DataBlockOutput.Add(astc.DataBlock);
|
||||
|
||||
Format = astc.Format;
|
||||
}
|
||||
|
||||
public void LoadBitMap(Image Image, string Name)
|
||||
{
|
||||
DecompressedData.Clear();
|
||||
|
||||
TexName = STGenericTexture.SetNameFromPath(Name);
|
||||
|
||||
Format = Runtime.PreferredTexFormat;
|
||||
|
||||
GenerateMipmaps = true;
|
||||
LoadImage(new Bitmap(Image));
|
||||
}
|
||||
|
||||
public void LoadBitMap(string FileName)
|
||||
{
|
||||
DecompressedData.Clear();
|
||||
|
||||
TexName = STGenericTexture.SetNameFromPath(FileName);
|
||||
Format = Runtime.PreferredTexFormat;
|
||||
|
||||
GenerateMipmaps = true;
|
||||
|
||||
//If a texture is .tga, we need to convert it
|
||||
Bitmap Image = null;
|
||||
if (Utils.GetExtension(FileName) == ".tga")
|
||||
{
|
||||
Image = Paloma.TargaImage.LoadTargaImage(FileName);
|
||||
}
|
||||
else
|
||||
{
|
||||
Image = new Bitmap(FileName);
|
||||
}
|
||||
|
||||
LoadImage(Image);
|
||||
}
|
||||
|
||||
private void LoadImage(Bitmap Image)
|
||||
{
|
||||
Image = BitmapExtension.SwapBlueRedChannels(Image);
|
||||
|
||||
TexWidth = (uint)Image.Width;
|
||||
TexHeight = (uint)Image.Height;
|
||||
MipCount = (uint)STGenericTexture.GenerateTotalMipCount(TexWidth, TexHeight);
|
||||
|
||||
DecompressedData.Add(BitmapExtension.ImageToByte(Image));
|
||||
|
||||
Image.Dispose();
|
||||
if (DecompressedData.Count == 0)
|
||||
{
|
||||
throw new Exception("Failed to load " + Format);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
public List<byte[]> GenerateMipList(STCompressionMode CompressionMode, int SurfaceLevel = 0)
|
||||
{
|
||||
Bitmap Image = BitmapExtension.GetBitmap(DecompressedData[SurfaceLevel], (int)TexWidth, (int)TexHeight);
|
||||
|
||||
List<byte[]> mipmaps = new List<byte[]>();
|
||||
for (int mipLevel = 0; mipLevel < MipCount; mipLevel++)
|
||||
{
|
||||
int MipWidth = Math.Max(1, (int)TexWidth >> mipLevel);
|
||||
int MipHeight = Math.Max(1, (int)TexHeight >> mipLevel);
|
||||
|
||||
if (mipLevel != 0)
|
||||
Image = BitmapExtension.Resize(Image, MipWidth, MipHeight);
|
||||
|
||||
mipmaps.Add(STGenericTexture.CompressBlock(BitmapExtension.ImageToByte(Image),
|
||||
Image.Width, Image.Height, Format, alphaRef, CompressionMode));
|
||||
}
|
||||
Image.Dispose();
|
||||
|
||||
return mipmaps;
|
||||
}
|
||||
|
||||
public byte[] GenerateMips(STCompressionMode CompressionMode, int SurfaceLevel = 0)
|
||||
{
|
||||
Bitmap Image = BitmapExtension.GetBitmap(DecompressedData[SurfaceLevel], (int)TexWidth, (int)TexHeight);
|
||||
|
||||
List<byte[]> mipmaps = new List<byte[]>();
|
||||
for (int mipLevel = 0; mipLevel < MipCount; mipLevel++)
|
||||
{
|
||||
int MipWidth = Math.Max(1, (int)TexWidth >> mipLevel);
|
||||
int MipHeight = Math.Max(1, (int)TexHeight >> mipLevel);
|
||||
|
||||
if (mipLevel != 0)
|
||||
Image = BitmapExtension.Resize(Image, MipWidth, MipHeight);
|
||||
|
||||
mipmaps.Add(STGenericTexture.CompressBlock(BitmapExtension.ImageToByte(Image),
|
||||
Image.Width, Image.Height, Format, alphaRef, CompressionMode));
|
||||
}
|
||||
Image.Dispose();
|
||||
|
||||
return Utils.CombineByteArray(mipmaps.ToArray());
|
||||
}
|
||||
|
||||
public void Compress(STCompressionMode CompressionMode)
|
||||
{
|
||||
DataBlockOutput.Clear();
|
||||
foreach (var surface in DecompressedData)
|
||||
{
|
||||
DataBlockOutput.Add(STGenericTexture.CompressBlock(surface,
|
||||
(int)TexWidth, (int)TexHeight, Format, alphaRef, CompressionMode));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -514,8 +514,6 @@ namespace Toolbox.Library
|
||||
parentNode.Nodes.Add(wrapperFile);
|
||||
parentNode = wrapperFile;
|
||||
AddFileNode(wrapperFile);
|
||||
|
||||
if (node.OpenFileFormatOnLoad) wrapperFile.OpenFileFormat(null);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -925,13 +923,21 @@ namespace Toolbox.Library
|
||||
node.Nodes.Insert(index, NewNode);
|
||||
}
|
||||
|
||||
|
||||
NewNode.ImageKey = replaceNode.ImageKey;
|
||||
NewNode.SelectedImageKey = replaceNode.SelectedImageKey;
|
||||
NewNode.Text = replaceNode.Text;
|
||||
|
||||
rootNode.FileNodes.RemoveAt(index);
|
||||
rootNode.FileNodes.Insert(index, Tuple.Create(fileInfo, NewNode));
|
||||
|
||||
if (NewNode is ISingleTextureIconLoader)
|
||||
{
|
||||
ObjectEditor editor = LibraryGUI.GetObjectEditor();
|
||||
if (editor != null) //The editor isn't always in object editor so check
|
||||
{
|
||||
editor.UpdateTextureIcon((ISingleTextureIconLoader)NewNode);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void RenameAction(object sender, EventArgs args)
|
||||
|
Binary file not shown.
Binary file not shown.
@ -242,6 +242,13 @@
|
||||
<Compile Include="Forms\Editors\Object Editor\SearchNodeForm.Designer.cs">
|
||||
<DependentUpon>SearchNodeForm.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Forms\Editors\TextureImport\GenericTextureImporterList.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Forms\Editors\TextureImport\GenericTextureImporterList.Designer.cs">
|
||||
<DependentUpon>GenericTextureImporterList.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Forms\Editors\TextureImport\GenericTextureImporterSettings.cs" />
|
||||
<Compile Include="Forms\Editors\UV\UVEditorForm.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
@ -945,6 +952,9 @@
|
||||
<EmbeddedResource Include="Forms\Editors\Animation\TimeLine.resx">
|
||||
<DependentUpon>TimeLine.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\Editors\TextureImport\GenericTextureImporterList.resx">
|
||||
<DependentUpon>GenericTextureImporterList.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Forms\Editors\TransformMeshTool.resx">
|
||||
<DependentUpon>TransformMeshTool.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
|
Loading…
Reference in New Issue
Block a user