Add bone x ray option

This commit is contained in:
KillzXGaming 2019-03-28 20:25:10 -04:00
parent 52d8b06d23
commit 7abeb6c2b9
2 changed files with 32 additions and 15 deletions

View file

@ -33,6 +33,7 @@
this.chkBoxNormalMap = new Switch_Toolbox.Library.Forms.STCheckBox();
this.shadingComboBox = new System.Windows.Forms.ComboBox();
this.panel2 = new Switch_Toolbox.Library.Forms.STPanel();
this.boneXRayChk = new Switch_Toolbox.Library.Forms.STCheckBox();
this.stLabel9 = new Switch_Toolbox.Library.Forms.STLabel();
this.cameraMaxSpeedUD = new Switch_Toolbox.Library.Forms.NumericUpDownFloat();
this.alphaChannelBtn = new Switch_Toolbox.Library.Forms.STButton();
@ -61,6 +62,7 @@
this.chkBoxStereoscopy = new Switch_Toolbox.Library.Forms.STCheckBox();
this.label2 = new Switch_Toolbox.Library.Forms.STLabel();
this.panel1 = new Switch_Toolbox.Library.Forms.STPanel();
this.enableVersionCheckCHK = new Switch_Toolbox.Library.Forms.STCheckBox();
this.GLSLVerLabel = new Switch_Toolbox.Library.Forms.STLabel();
this.openGLVerLabel = new Switch_Toolbox.Library.Forms.STLabel();
this.btnSave = new Switch_Toolbox.Library.Forms.STButton();
@ -85,7 +87,6 @@
this.bgGradientTop = new System.Windows.Forms.PictureBox();
this.stLabel2 = new Switch_Toolbox.Library.Forms.STLabel();
this.preferredTexFormatCB = new System.Windows.Forms.ComboBox();
this.enableVersionCheckCHK = new Switch_Toolbox.Library.Forms.STCheckBox();
this.contentContainer.SuspendLayout();
this.panel2.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.cameraMaxSpeedUD)).BeginInit();
@ -157,6 +158,7 @@
//
// panel2
//
this.panel2.Controls.Add(this.boneXRayChk);
this.panel2.Controls.Add(this.stLabel9);
this.panel2.Controls.Add(this.cameraMaxSpeedUD);
this.panel2.Controls.Add(this.alphaChannelBtn);
@ -193,6 +195,16 @@
this.panel2.Size = new System.Drawing.Size(534, 293);
this.panel2.TabIndex = 4;
//
// boneXRayChk
//
this.boneXRayChk.AutoSize = true;
this.boneXRayChk.Location = new System.Drawing.Point(268, 137);
this.boneXRayChk.Name = "boneXRayChk";
this.boneXRayChk.Size = new System.Drawing.Size(120, 17);
this.boneXRayChk.TabIndex = 30;
this.boneXRayChk.Text = "Display Bone X Ray";
this.boneXRayChk.CheckedChanged += new System.EventHandler(this.boneXRayChk_CheckedChanged);
//
// stLabel9
//
this.stLabel9.AutoSize = true;
@ -429,7 +441,7 @@
// chkBoxDisplayPolyCount
//
this.chkBoxDisplayPolyCount.AutoSize = true;
this.chkBoxDisplayPolyCount.Location = new System.Drawing.Point(268, 137);
this.chkBoxDisplayPolyCount.Location = new System.Drawing.Point(268, 160);
this.chkBoxDisplayPolyCount.Name = "chkBoxDisplayPolyCount";
this.chkBoxDisplayPolyCount.Size = new System.Drawing.Size(114, 17);
this.chkBoxDisplayPolyCount.TabIndex = 13;
@ -589,6 +601,17 @@
this.panel1.Size = new System.Drawing.Size(215, 96);
this.panel1.TabIndex = 5;
//
// enableVersionCheckCHK
//
this.enableVersionCheckCHK.AutoSize = true;
this.enableVersionCheckCHK.Location = new System.Drawing.Point(0, 67);
this.enableVersionCheckCHK.Name = "enableVersionCheckCHK";
this.enableVersionCheckCHK.Size = new System.Drawing.Size(131, 17);
this.enableVersionCheckCHK.TabIndex = 16;
this.enableVersionCheckCHK.Text = "Enable Version Check";
this.enableVersionCheckCHK.UseVisualStyleBackColor = true;
this.enableVersionCheckCHK.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged_2);
//
// GLSLVerLabel
//
this.GLSLVerLabel.AutoSize = true;
@ -874,17 +897,6 @@
this.preferredTexFormatCB.TabIndex = 0;
this.preferredTexFormatCB.SelectedIndexChanged += new System.EventHandler(this.preferredTexFormatCB_SelectedIndexChanged);
//
// enableVersionCheckCHK
//
this.enableVersionCheckCHK.AutoSize = true;
this.enableVersionCheckCHK.Location = new System.Drawing.Point(0, 67);
this.enableVersionCheckCHK.Name = "enableVersionCheckCHK";
this.enableVersionCheckCHK.Size = new System.Drawing.Size(131, 17);
this.enableVersionCheckCHK.TabIndex = 16;
this.enableVersionCheckCHK.Text = "Enable Version Check";
this.enableVersionCheckCHK.UseVisualStyleBackColor = true;
this.enableVersionCheckCHK.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged_2);
//
// Settings
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@ -981,5 +993,6 @@
private Switch_Toolbox.Library.Forms.STLabel stLabel9;
private Switch_Toolbox.Library.Forms.NumericUpDownFloat cameraMaxSpeedUD;
private Switch_Toolbox.Library.Forms.STCheckBox enableVersionCheckCHK;
private Switch_Toolbox.Library.Forms.STCheckBox boneXRayChk;
}
}

View file

@ -68,6 +68,7 @@ namespace Toolbox
chkBoxDisplayBones.Checked = Runtime.renderBones;
boneSizeUD.Value = (decimal)Runtime.bonePointSize;
cameraMaxSpeedUD.Value = (decimal)Runtime.MaxCameraSpeed;
boneXRayChk.Checked = Runtime.boneXrayDisplay;
GLSLVerLabel.Text = $"Open GL Version: {Runtime.GLSLVersion}";
openGLVerLabel.Text = $"GLSL Version: {Runtime.openGLVersion}";
@ -365,9 +366,12 @@ namespace Toolbox
UpdateViewportSettings();
}
private void cameraMaxSpeedUD_ValueChanged(object sender, EventArgs e)
{
private void cameraMaxSpeedUD_ValueChanged(object sender, EventArgs e) {
Runtime.MaxCameraSpeed = (float)cameraMaxSpeedUD.Value;
}
private void boneXRayChk_CheckedChanged(object sender, EventArgs e) {
Runtime.boneXrayDisplay = boneXRayChk.Checked;
}
}
}