Skip to content

Commit

Permalink
New Features
Browse files Browse the repository at this point in the history
Added emissive multiplication. Added texture packing modes like RMA.  Normal direction bug fix. Decal support through depth offset.  More detail map blending modes. Added Mod2x and multiply rendering mode. Added smoothness multiplier. Added more recommened settings. Added alpha dithering.
  • Loading branch information
KevinComerford committed Apr 18, 2018
1 parent 636022c commit 5a5e00a
Show file tree
Hide file tree
Showing 48 changed files with 2,146 additions and 316 deletions.
29 changes: 28 additions & 1 deletion Assets/GradientMaker/Gradients/SSS_rampscatter.png.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added Assets/GradientMaker/Gradients/gray_ramp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Assets/GradientMaker/Scripts/GradientMaker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ private void OutputGradient(byte[] bytes){
TextureImporter TI = (TextureImporter)TextureImporter.GetAtPath("Assets/GradientMaker/Gradients/" + _fileName + ".png");
TI.wrapMode = WrapMode;
TI.alphaSource = AlphaMode;
TI.textureCompression = TextureImporterCompression.CompressedHQ;
string logString = alreadyExists ? "Gradient Overwritten: " : "Gradient saved: ";
Debug.Log(logString + outputFile, outputFile);
EditorGUIUtility.PingObject(outputFile);
Expand Down
93 changes: 82 additions & 11 deletions Assets/TheLabRenderer/Editor/ValveAutoUpdateSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@ public class TheLabRenderer_Settings : EditorWindow
const string gpuSkinning = "GPU Skinning";
const string shadowCascades = "Shadow Cascades";
const string pixelLightCount = "Pixel Light Count";
const string UnityShadowEnabled = "Shadow Cascades";
const string unityShadowEnabled = "Unity Shadows";
const string anisotropicFiltering = "Anisotropic Filtering";

#if false // skyboxes are currently broken
#if UNITY_2017_3_OR_NEWER // skyboxes are currently broken
const string singlePassStereoRendering = "Single-Pass Stereo Rendering";
#endif

Expand All @@ -52,8 +53,11 @@ public class TheLabRenderer_Settings : EditorWindow
const bool recommended_GpuSkinning = true;
const int recommended_shadowCascades = 1;
const int recommended_pixelLightCount = 99;
const ShadowQuality reommended_UnityShadowEnabled = ShadowQuality.Disable;
#if false
const ShadowQuality recommended_UnityShadowEnabled = ShadowQuality.Disable;
const AnisotropicFiltering recommended_anisotropicFiltering = AnisotropicFiltering.ForceEnable;

//const QualitySettings.anisotropicFiltering
#if UNITY_2017_3_OR_NEWER
const bool recommended_SinglePassStereoRendering = true;
#endif

Expand All @@ -66,6 +70,7 @@ static TheLabRenderer_Settings()

static void Update()
{

bool show =
(!EditorPrefs.HasKey(ignore + buildTarget) &&
EditorUserBuildSettings.activeBuildTarget != recommended_BuildTarget) ||
Expand Down Expand Up @@ -96,9 +101,11 @@ static void Update()
QualitySettings.shadowCascades != recommended_shadowCascades) ||
(!EditorPrefs.HasKey(ignore + pixelLightCount) &&
QualitySettings.pixelLightCount != recommended_pixelLightCount) ||
(!EditorPrefs.HasKey(ignore + UnityShadowEnabled) &&
QualitySettings.shadows != reommended_UnityShadowEnabled) ||
#if false
(!EditorPrefs.HasKey(ignore + unityShadowEnabled) &&
QualitySettings.shadows != recommended_UnityShadowEnabled) ||
(!EditorPrefs.HasKey(ignore + anisotropicFiltering) &&
QualitySettings.anisotropicFiltering != recommended_anisotropicFiltering) ||
#if UNITY_2017_3_OR_NEWER
(!EditorPrefs.HasKey(ignore + singlePassStereoRendering) &&
PlayerSettings.singlePassStereoRendering != recommended_SinglePassStereoRendering) ||
#endif
Expand Down Expand Up @@ -515,6 +522,32 @@ public void OnGUI()
GUILayout.EndHorizontal();
}


if (!EditorPrefs.HasKey(ignore + unityShadowEnabled) &&
QualitySettings.shadows != recommended_UnityShadowEnabled)
{
++numItems;

GUILayout.Label(unityShadowEnabled + string.Format(currentValue, QualitySettings.shadows));

GUILayout.BeginHorizontal();

if (GUILayout.Button(string.Format(useRecommended, recommended_UnityShadowEnabled)))
{
QualitySettings.shadows = recommended_UnityShadowEnabled;
}

GUILayout.FlexibleSpace();

if (GUILayout.Button("Ignore"))
{
EditorPrefs.SetBool(ignore + unityShadowEnabled, true);
}

GUILayout.EndHorizontal();
}


if (!EditorPrefs.HasKey(ignore + pixelLightCount) &&
QualitySettings.pixelLightCount != recommended_pixelLightCount)
{
Expand All @@ -539,7 +572,35 @@ public void OnGUI()
GUILayout.EndHorizontal();
}

#if false


if (!EditorPrefs.HasKey(ignore + anisotropicFiltering) &&
QualitySettings.anisotropicFiltering != recommended_anisotropicFiltering)
{
++numItems;

GUILayout.Label(anisotropicFiltering + string.Format(currentValue, QualitySettings.anisotropicFiltering));

GUILayout.BeginHorizontal();

if (GUILayout.Button(string.Format(useRecommended, recommended_anisotropicFiltering )))
{
QualitySettings.anisotropicFiltering = recommended_anisotropicFiltering;
}

GUILayout.FlexibleSpace();

if (GUILayout.Button("Ignore"))
{
EditorPrefs.SetBool(ignore + anisotropicFiltering, true);
}

GUILayout.EndHorizontal();
}



#if UNITY_2017_3_OR_NEWER
if (!EditorPrefs.HasKey(ignore + singlePassStereoRendering) &&
PlayerSettings.singlePassStereoRendering != recommended_SinglePassStereoRendering)
{
Expand Down Expand Up @@ -585,7 +646,9 @@ public void OnGUI()
EditorPrefs.DeleteKey(ignore + gpuSkinning);
EditorPrefs.DeleteKey(ignore + shadowCascades);
EditorPrefs.DeleteKey(ignore + pixelLightCount);
#if false
EditorPrefs.DeleteKey(ignore + anisotropicFiltering);
EditorPrefs.DeleteKey(ignore + unityShadowEnabled);
#if UNITY_2017_3_OR_NEWER
EditorPrefs.DeleteKey(ignore + singlePassStereoRendering);
#endif
}
Expand Down Expand Up @@ -632,9 +695,13 @@ public void OnGUI()
PlayerSettings.gpuSkinning = recommended_GpuSkinning;
if (!EditorPrefs.HasKey(ignore + shadowCascades))
QualitySettings.shadowCascades = recommended_shadowCascades;
if (!EditorPrefs.HasKey(ignore + unityShadowEnabled))
QualitySettings.shadows = recommended_UnityShadowEnabled;
if (!EditorPrefs.HasKey(ignore + pixelLightCount))
QualitySettings.pixelLightCount = recommended_pixelLightCount;
#if false
if (!EditorPrefs.HasKey(ignore + recommended_anisotropicFiltering))
QualitySettings.anisotropicFiltering = recommended_anisotropicFiltering;
#if UNITY_2017_3_OR_NEWER
if (!EditorPrefs.HasKey(ignore + singlePassStereoRendering))
PlayerSettings.singlePassStereoRendering = recommended_SinglePassStereoRendering;
#endif
Expand Down Expand Up @@ -676,9 +743,13 @@ public void OnGUI()
EditorPrefs.SetBool(ignore + gpuSkinning, true);
if (QualitySettings.shadowCascades != recommended_shadowCascades)
EditorPrefs.SetBool(ignore + shadowCascades, true);
if (QualitySettings.shadows != recommended_UnityShadowEnabled)
EditorPrefs.SetBool(ignore + unityShadowEnabled, true);
if (QualitySettings.pixelLightCount != recommended_pixelLightCount)
EditorPrefs.SetBool(ignore + pixelLightCount, true);
#if false
if (QualitySettings.anisotropicFiltering != recommended_anisotropicFiltering)
EditorPrefs.SetBool(ignore + anisotropicFiltering, true);
#if UNITY_2017_3_OR_NEWER
if (PlayerSettings.singlePassStereoRendering != recommended_SinglePassStereoRendering)
EditorPrefs.SetBool(ignore + singlePassStereoRendering, true);
#endif
Expand Down
Loading

0 comments on commit 5a5e00a

Please sign in to comment.