Compare commits
42 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 31b16329bc | |||
| 7529a7c4cd | |||
| c51b5f34bb | |||
| 63de3742ec | |||
| e9b32e14fd | |||
| f4ea151244 | |||
| fd39abf5a7 | |||
| 27a04ca294 | |||
| 8edf1f1128 | |||
| c5dfc3bd35 | |||
| 372519d01f | |||
| 6be2ab7a4f | |||
| e326bb7753 | |||
| 7a765c32d8 | |||
| b57e98b64c | |||
| eadb477bcd | |||
| 33b1177815 | |||
| 792db85b79 | |||
| 889c7ff578 | |||
| 5994f8875e | |||
| b2d70af9c3 | |||
| da535854cc | |||
| bc1578b0ca | |||
| d3779f9f57 | |||
| 213daa85e9 | |||
| 6e4d4ab03d | |||
| 4222d72318 | |||
| 8159c091e8 | |||
| 2b44837bb9 | |||
| 1d849e54cb | |||
| 811f5762e6 | |||
| 2f63adfba0 | |||
| 7cb8325e44 | |||
| eafb9ce365 | |||
| 0ef6027371 | |||
| 92f9611a39 | |||
| edf694313f | |||
| 894c5610d0 | |||
| f7175c0373 | |||
| 238a17d57d | |||
| 97237b3aa8 | |||
| 1be0cd45db |
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7cf8e0d1fc8d94fb9944cf32a03c4cfa
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,74 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
using Coffee.UIEffects;
|
||||
using UnityEngine.Events;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class ControlByScript : MonoBehaviour
|
||||
{
|
||||
[SerializeField]
|
||||
private UIEffect m_Effect;
|
||||
|
||||
[SerializeField]
|
||||
private ControlTemplate m_ControlTemplate;
|
||||
|
||||
private void Start()
|
||||
{
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsDropDown(nameof(m_Effect.toneFilter), typeof(ToneFilter),
|
||||
(int)m_Effect.toneFilter, x => m_Effect.toneFilter = (ToneFilter)x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsSlider(nameof(m_Effect.toneIntensity), m_Effect.toneIntensity, x => m_Effect.toneIntensity = x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsDropDown(nameof(m_Effect.colorFilter), typeof(ColorFilter),
|
||||
(int)m_Effect.colorFilter, x => m_Effect.colorFilter = (ColorFilter)x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsSlider(nameof(m_Effect.colorIntensity), m_Effect.colorIntensity, x => m_Effect.colorIntensity = x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsColorDropDown(nameof(m_Effect.color), m_Effect.color, x => m_Effect.color = x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsSlider("Hue", m_Effect.color.r, x =>
|
||||
{
|
||||
var color = m_Effect.color;
|
||||
color.r = x;
|
||||
m_Effect.color = color;
|
||||
});
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsToggle(nameof(m_Effect.colorGlow), m_Effect.colorGlow, x => m_Effect.colorGlow = x);
|
||||
}
|
||||
|
||||
|
||||
private void AddColor(ColorFilter filter, Action<ColorFilter> filterSetter,
|
||||
float intensity, Action<float> intensitySetter,
|
||||
Color color, Action<Color> colorSetter,
|
||||
bool glow, Action<bool> glowSetter)
|
||||
{
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsDropDown(nameof(m_Effect.colorFilter), typeof(ColorFilter),
|
||||
(int)m_Effect.colorFilter, x => m_Effect.colorFilter = (ColorFilter)x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsSlider(nameof(m_Effect.colorIntensity), m_Effect.colorIntensity, x => m_Effect.colorIntensity = x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsColorDropDown(nameof(m_Effect.color), m_Effect.color, x => m_Effect.color = x);
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsSlider("Hue", m_Effect.color.r, x =>
|
||||
{
|
||||
var color = m_Effect.color;
|
||||
color.r = x;
|
||||
m_Effect.color = color;
|
||||
});
|
||||
|
||||
m_ControlTemplate.Instantiate()
|
||||
.InitAsToggle(nameof(m_Effect.colorGlow), m_Effect.colorGlow, x => m_Effect.colorGlow = x);
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 402a2dd4d098a4d708b9f6e7ce0557cd
|
||||
guid: 3fbf547b561114807adbec486aa2b977
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fda8f6b673bdc4e84b040385ee78bf83
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,110 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
using Coffee.UIEffects;
|
||||
using UnityEngine.Events;
|
||||
using UnityEngine.Serialization;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class ControlTemplate : MonoBehaviour
|
||||
{
|
||||
[SerializeField]
|
||||
private Text m_Label;
|
||||
|
||||
[SerializeField]
|
||||
private Dropdown m_Dropdown;
|
||||
|
||||
[SerializeField]
|
||||
private Slider m_Slider;
|
||||
|
||||
[SerializeField]
|
||||
private Toggle m_Toggle;
|
||||
|
||||
[SerializeField]
|
||||
private RawImage m_RawImage;
|
||||
|
||||
public ControlTemplate Instantiate()
|
||||
{
|
||||
var go = Instantiate(gameObject, transform.parent, false);
|
||||
return go.GetComponent<ControlTemplate>();
|
||||
}
|
||||
|
||||
public void InitAsDropDown(string label, Type enumType, int value, UnityAction<int> onValueChanged)
|
||||
{
|
||||
m_Label.text = label;
|
||||
|
||||
m_Dropdown.ClearOptions();
|
||||
m_Dropdown.AddOptions(Enum.GetNames(enumType).ToList());
|
||||
m_Dropdown.onValueChanged.RemoveAllListeners();
|
||||
m_Dropdown.onValueChanged.AddListener(onValueChanged);
|
||||
m_Dropdown.SetValueWithoutNotify(value);
|
||||
|
||||
// m_Dropdown.gameObject.SetActive(false);
|
||||
m_Slider.gameObject.SetActive(false);
|
||||
m_Toggle.gameObject.SetActive(false);
|
||||
m_RawImage.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
|
||||
private static readonly (string name, Color color)[] s_Colors = new (string, Color)[]
|
||||
{
|
||||
("-", Color.clear),
|
||||
("White", Color.white),
|
||||
("Red", Color.red),
|
||||
("Green", Color.green),
|
||||
("Blue", Color.blue),
|
||||
("Yellow", Color.yellow),
|
||||
("Cyan", Color.cyan),
|
||||
("Magenta", Color.magenta),
|
||||
("Black", Color.black)
|
||||
};
|
||||
|
||||
public void InitAsColorDropDown(string label, Color value, UnityAction<Color> onValueChanged)
|
||||
{
|
||||
m_Label.text = label;
|
||||
|
||||
m_Dropdown.ClearOptions();
|
||||
m_Dropdown.AddOptions(s_Colors.Select(x => x.name).ToList());
|
||||
m_Dropdown.onValueChanged.RemoveAllListeners();
|
||||
m_Dropdown.onValueChanged.AddListener(x =>
|
||||
{
|
||||
m_RawImage.color = s_Colors[x].color;
|
||||
onValueChanged(s_Colors[x].color);
|
||||
});
|
||||
m_RawImage.color = value;
|
||||
m_Dropdown.SetValueWithoutNotify(0);
|
||||
|
||||
// m_Dropdown.gameObject.SetActive(false);
|
||||
m_Slider.gameObject.SetActive(false);
|
||||
m_Toggle.gameObject.SetActive(false);
|
||||
m_RawImage.gameObject.SetActive(true);
|
||||
}
|
||||
|
||||
public void InitAsSlider(string label, float value, UnityAction<float> onValueChanged)
|
||||
{
|
||||
m_Label.text = label;
|
||||
|
||||
m_Slider.onValueChanged.RemoveAllListeners();
|
||||
m_Slider.onValueChanged.AddListener(onValueChanged);
|
||||
m_Slider.SetValueWithoutNotify(value);
|
||||
|
||||
m_Dropdown.gameObject.SetActive(false);
|
||||
// m_Slider.gameObject.SetActive(false);
|
||||
m_Toggle.gameObject.SetActive(false);
|
||||
m_RawImage.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
public void InitAsToggle(string label, bool value, UnityAction<bool> onValueChanged)
|
||||
{
|
||||
m_Label.text = label;
|
||||
|
||||
m_Toggle.onValueChanged.RemoveAllListeners();
|
||||
m_Toggle.onValueChanged.AddListener(onValueChanged);
|
||||
m_Toggle.SetIsOnWithoutNotify(value);
|
||||
|
||||
m_Dropdown.gameObject.SetActive(false);
|
||||
m_Slider.gameObject.SetActive(false);
|
||||
// m_Toggle.gameObject.SetActive(false);
|
||||
m_RawImage.gameObject.SetActive(false);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3aef1549bb83f4e6babaf8bc9648ee1b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: bb16138913ad1451aa438c3edd486c67
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 23 KiB |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 098475820cf634867a339bb9af940722
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 0
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 0
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 0
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 64
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 50 KiB |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1851730bef7524e58b285a364983e21e
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 0
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 0
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 0
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 64
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 31 KiB |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9617fea85692e4f5fb65fb2ddd4496ce
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 0
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 0
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 0
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 64
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 4.6 KiB |
@@ -0,0 +1,171 @@
|
||||
fileFormatVersion: 2
|
||||
guid: be1fa55f69843fb4aaf4d0ff56004fba
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 0
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 0
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 0
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 16, y: 16, z: 16, w: 16}
|
||||
spriteGenerateFallbackPhysicsShape: 0
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 1
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 64
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Windows Store Apps
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,61 @@
|
||||
using Coffee.UIEffects;
|
||||
using UnityEngine;
|
||||
|
||||
public class PatternAndEdge : MonoBehaviour
|
||||
{
|
||||
private UIEffect[] _effects;
|
||||
|
||||
// Start is called before the first frame update
|
||||
private void Start()
|
||||
{
|
||||
_effects = GetComponentsInChildren<UIEffect>();
|
||||
}
|
||||
|
||||
public void SetTransitionWidth(float value)
|
||||
{
|
||||
foreach (var effect in _effects)
|
||||
{
|
||||
effect.transitionWidth = value;
|
||||
}
|
||||
}
|
||||
|
||||
public void SetTransitionRotation(float value)
|
||||
{
|
||||
foreach (var effect in _effects)
|
||||
{
|
||||
effect.transitionRotation = value;
|
||||
}
|
||||
}
|
||||
|
||||
public void SetTransitionAutoSpeed(float value)
|
||||
{
|
||||
foreach (var effect in _effects)
|
||||
{
|
||||
effect.transitionAutoPlaySpeed = value;
|
||||
}
|
||||
}
|
||||
|
||||
public void SetEdgeWidth(float value)
|
||||
{
|
||||
foreach (var effect in _effects)
|
||||
{
|
||||
effect.edgeWidth = value;
|
||||
}
|
||||
}
|
||||
|
||||
public void SetShinyWidth(float value)
|
||||
{
|
||||
foreach (var effect in _effects)
|
||||
{
|
||||
effect.edgeShinyWidth = value;
|
||||
}
|
||||
}
|
||||
|
||||
public void SetShinySpeed(float value)
|
||||
{
|
||||
foreach (var effect in _effects)
|
||||
{
|
||||
effect.edgeShinyAutoPlaySpeed = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e095cc53c91de44459b0fda6a14d0eff
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,64 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!687078895 &4343727234628468602
|
||||
SpriteAtlas:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: PatternAndEdge
|
||||
m_EditorData:
|
||||
serializedVersion: 2
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
anisoLevel: 1
|
||||
compressionQuality: 50
|
||||
maxTextureSize: 2048
|
||||
textureCompression: 0
|
||||
filterMode: 1
|
||||
generateMipMaps: 0
|
||||
readable: 0
|
||||
crunchedCompression: 0
|
||||
sRGB: 1
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
m_BuildTarget: DefaultTexturePlatform
|
||||
m_MaxTextureSize: 2048
|
||||
m_ResizeAlgorithm: 0
|
||||
m_TextureFormat: -1
|
||||
m_TextureCompression: 1
|
||||
m_CompressionQuality: 50
|
||||
m_CrunchedCompression: 0
|
||||
m_AllowsAlphaSplitting: 0
|
||||
m_Overridden: 0
|
||||
m_AndroidETC2FallbackOverride: 0
|
||||
m_ForceMaximumCompressionQuality_BC6H_BC7: 1
|
||||
packingSettings:
|
||||
serializedVersion: 2
|
||||
padding: 4
|
||||
blockOffset: 1
|
||||
allowAlphaSplitting: 0
|
||||
enableRotation: 1
|
||||
enableTightPacking: 0
|
||||
enableAlphaDilation: 0
|
||||
secondaryTextureSettings: {}
|
||||
variantMultiplier: 1
|
||||
packables:
|
||||
- {fileID: 102900000, guid: bb16138913ad1451aa438c3edd486c67, type: 3}
|
||||
bindAsDefault: 1
|
||||
isAtlasV2: 0
|
||||
cachedData: {fileID: 0}
|
||||
m_MasterAtlas: {fileID: 0}
|
||||
m_PackedSprites:
|
||||
- {fileID: 21300000, guid: 098475820cf634867a339bb9af940722, type: 3}
|
||||
- {fileID: 21300000, guid: 9617fea85692e4f5fb65fb2ddd4496ce, type: 3}
|
||||
- {fileID: 21300000, guid: 1851730bef7524e58b285a364983e21e, type: 3}
|
||||
- {fileID: 21300000, guid: be1fa55f69843fb4aaf4d0ff56004fba, type: 3}
|
||||
m_PackedSpriteNamesToIndex:
|
||||
- Badge_Checked
|
||||
- Badge_Police
|
||||
- Badge_Level
|
||||
- FlatCornered_64
|
||||
m_RenderDataMap: {}
|
||||
m_Tag: PatternAndEdge
|
||||
m_IsVariant: 0
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 855c67a9aa5494a5eb7dab6da5100e95
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 263e512bc0ad44038af0c3a4e37b6b33
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -252,6 +252,7 @@ MonoBehaviour:
|
||||
m_Target: {fileID: 1567169363}
|
||||
m_UseTargetTransform: 1
|
||||
m_SamplingScale: 1
|
||||
m_AllowToModifyMeshShape: 1
|
||||
--- !u!114 &571623417
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -522,6 +523,7 @@ MonoBehaviour:
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 5
|
||||
m_SamplingIntensity: 0.197
|
||||
m_SamplingWidth: 1
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 3
|
||||
m_TransitionRate: 0.411
|
||||
@@ -533,9 +535,14 @@ MonoBehaviour:
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.071
|
||||
m_TransitionSoftness: 0.401
|
||||
m_TransitionRange:
|
||||
m_Min: 0
|
||||
m_Max: 1
|
||||
m_TransitionColorFilter: 6
|
||||
m_TransitionColor: {r: 0, g: 0.5019608, b: 1.0039216, a: 1}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TransitionPatternReverse: 0
|
||||
m_TransitionAutoPlaySpeed: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 0.22352943, g: 0.87843144, b: 0.9450981, a: 1}
|
||||
m_TargetRange: 0.118
|
||||
@@ -586,7 +593,15 @@ MonoBehaviour:
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: -0.349
|
||||
m_GradationScale: 0.62374645
|
||||
m_AllowExtendVertex: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
m_EdgeMode: 0
|
||||
m_EdgeWidth: 0.5
|
||||
m_EdgeColorFilter: 4
|
||||
m_EdgeColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_EdgeShinyWidth: 0.5
|
||||
m_EdgeShinySpeed: 1
|
||||
m_PatternArea: 1
|
||||
--- !u!114 &1120943173
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -706,9 +721,13 @@ MonoBehaviour:
|
||||
m_Delay: 0.5
|
||||
m_Duration: 1
|
||||
m_Interval: 0.5
|
||||
m_PlayOnEnable: 1
|
||||
m_PlayOnEnable: 3
|
||||
m_ResetTimeOnEnable: 1
|
||||
m_WrapMode: 1
|
||||
m_UpdateMode: 0
|
||||
m_OnComplete:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
--- !u!114 &1242517206
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -730,6 +749,7 @@ MonoBehaviour:
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 1
|
||||
m_SamplingIntensity: 1
|
||||
m_SamplingWidth: 1
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 3
|
||||
m_TransitionRate: 0.408
|
||||
@@ -741,9 +761,14 @@ MonoBehaviour:
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.074
|
||||
m_TransitionSoftness: 0.27
|
||||
m_TransitionRange:
|
||||
m_Min: 0
|
||||
m_Max: 1
|
||||
m_TransitionColorFilter: 6
|
||||
m_TransitionColor: {r: 0, g: 0.5019608, b: 1.0039216, a: 1}
|
||||
m_TransitionColorGlow: 1
|
||||
m_TransitionPatternReverse: 0
|
||||
m_TransitionAutoPlaySpeed: 0
|
||||
m_TargetMode: 1
|
||||
m_TargetColor: {r: 0.22352943, g: 0.87843144, b: 0.9450981, a: 1}
|
||||
m_TargetRange: 0.118
|
||||
@@ -794,7 +819,15 @@ MonoBehaviour:
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: -0.349
|
||||
m_GradationScale: 0.62374645
|
||||
m_AllowExtendVertex: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
m_EdgeMode: 2
|
||||
m_EdgeWidth: 0.5
|
||||
m_EdgeColorFilter: 6
|
||||
m_EdgeColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_EdgeShinyWidth: 0.5
|
||||
m_EdgeShinySpeed: 1
|
||||
m_PatternArea: 1
|
||||
--- !u!114 &1242517207
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -894,6 +927,7 @@ MonoBehaviour:
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 0
|
||||
m_SamplingIntensity: 0.5
|
||||
m_SamplingWidth: 1
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 0
|
||||
m_TransitionRate: 0.5
|
||||
@@ -905,9 +939,14 @@ MonoBehaviour:
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.2
|
||||
m_TransitionSoftness: 0.2
|
||||
m_TransitionRange:
|
||||
m_Min: 0
|
||||
m_Max: 1
|
||||
m_TransitionColorFilter: 6
|
||||
m_TransitionColor: {r: 0, g: 0.5, b: 1, a: 1}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TransitionPatternReverse: 0
|
||||
m_TransitionAutoPlaySpeed: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TargetRange: 0.1
|
||||
@@ -958,7 +997,15 @@ MonoBehaviour:
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: 0
|
||||
m_GradationScale: 1
|
||||
m_AllowExtendVertex: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
m_EdgeMode: 0
|
||||
m_EdgeWidth: 0.5
|
||||
m_EdgeColorFilter: 4
|
||||
m_EdgeColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_EdgeShinyWidth: 0.5
|
||||
m_EdgeShinySpeed: 1
|
||||
m_PatternArea: 1
|
||||
--- !u!114 &1567169364
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -1039,5 +1086,9 @@ MonoBehaviour:
|
||||
m_Duration: 1
|
||||
m_Interval: 0.5
|
||||
m_PlayOnEnable: 1
|
||||
m_ResetTimeOnEnable: 1
|
||||
m_WrapMode: 1
|
||||
m_UpdateMode: 0
|
||||
m_OnComplete:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
|
||||
@@ -0,0 +1,110 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 8
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: CarterOne-Regular SDF - Outline
|
||||
m_Shader: {fileID: 4800000, guid: fe393ace9b354375a9cb14cdbbc28be4, type: 3}
|
||||
m_ValidKeywords:
|
||||
- OUTLINE_ON
|
||||
- UNDERLAY_ON
|
||||
m_InvalidKeywords: []
|
||||
m_LightmapFlags: 4
|
||||
m_EnableInstancingVariants: 0
|
||||
m_DoubleSidedGI: 0
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
disabledShaderPasses: []
|
||||
m_SavedProperties:
|
||||
serializedVersion: 3
|
||||
m_TexEnvs:
|
||||
- _BumpMap:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _Cube:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _FaceTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _MainTex:
|
||||
m_Texture: {fileID: -5656930091445551790, guid: bc6ef582a0efa420683ff976adff235a,
|
||||
type: 2}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _OutlineTex:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Ints: []
|
||||
m_Floats:
|
||||
- _Ambient: 0.5
|
||||
- _Bevel: 0.5
|
||||
- _BevelClamp: 0
|
||||
- _BevelOffset: 0
|
||||
- _BevelRoundness: 0
|
||||
- _BevelWidth: 0
|
||||
- _BumpFace: 0
|
||||
- _BumpOutline: 0
|
||||
- _ColorMask: 15
|
||||
- _CullMode: 0
|
||||
- _Diffuse: 0.5
|
||||
- _FaceDilate: 0
|
||||
- _FaceUVSpeedX: 0
|
||||
- _FaceUVSpeedY: 0
|
||||
- _GlowInner: 0.05
|
||||
- _GlowOffset: 0
|
||||
- _GlowOuter: 0.05
|
||||
- _GlowPower: 0.75
|
||||
- _GradientScale: 10
|
||||
- _LightAngle: 3.1416
|
||||
- _MaskSoftnessX: 0
|
||||
- _MaskSoftnessY: 0
|
||||
- _OutlineSoftness: 0
|
||||
- _OutlineUVSpeedX: 0
|
||||
- _OutlineUVSpeedY: 0
|
||||
- _OutlineWidth: 0.25
|
||||
- _PerspectiveFilter: 0.875
|
||||
- _Reflectivity: 10
|
||||
- _ScaleRatioA: 0.9
|
||||
- _ScaleRatioB: 0.73125
|
||||
- _ScaleRatioC: 0.365625
|
||||
- _ScaleX: 1
|
||||
- _ScaleY: 1
|
||||
- _ShaderFlags: 0
|
||||
- _Sharpness: 0
|
||||
- _SpecularPower: 2
|
||||
- _Stencil: 0
|
||||
- _StencilComp: 8
|
||||
- _StencilOp: 0
|
||||
- _StencilReadMask: 255
|
||||
- _StencilWriteMask: 255
|
||||
- _TextureHeight: 1024
|
||||
- _TextureWidth: 1024
|
||||
- _UnderlayDilate: 1
|
||||
- _UnderlayOffsetX: 1
|
||||
- _UnderlayOffsetY: -1
|
||||
- _UnderlaySoftness: 0
|
||||
- _VertexOffsetX: 0
|
||||
- _VertexOffsetY: 0
|
||||
- _WeightBold: 0.75
|
||||
- _WeightNormal: 0
|
||||
m_Colors:
|
||||
- _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767}
|
||||
- _EnvMatrixRotation: {r: 0, g: 0, b: 0, a: 0}
|
||||
- _FaceColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _GlowColor: {r: 0, g: 1, b: 0, a: 0.5}
|
||||
- _MaskCoord: {r: 0, g: 0, b: 32767, a: 32767}
|
||||
- _OutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectFaceColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _ReflectOutlineColor: {r: 0, g: 0, b: 0, a: 1}
|
||||
- _SpecularColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
- _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5}
|
||||
m_BuildTextureStacks: []
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: cab5405a1d5e24ca7858d78bc295cc25
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 2100000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -15,10 +15,6 @@ ShaderVariantCollection:
|
||||
passType: 0
|
||||
- keywords: COLOR_ADDITIVE
|
||||
passType: 0
|
||||
- keywords: COLOR_ADDITIVE SAMPLING_BLUR_FAST
|
||||
passType: 0
|
||||
- keywords: COLOR_ADDITIVE SAMPLING_BLUR_FAST UNITY_UI_CLIP_RECT
|
||||
passType: 0
|
||||
- keywords: COLOR_CONTRAST
|
||||
passType: 0
|
||||
- keywords: COLOR_HSV_MODIFIER
|
||||
@@ -29,30 +25,50 @@ ShaderVariantCollection:
|
||||
passType: 0
|
||||
- keywords: COLOR_MULTIPLY
|
||||
passType: 0
|
||||
- keywords: COLOR_MULTIPLY SAMPLING_BLUR_FAST SHADOW_COLOR_REPLACE TARGET_HUE
|
||||
TONE_GRAYSCALE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_DISSOLVE
|
||||
- keywords: COLOR_MULTIPLY SHADOW_COLOR_REPLACE
|
||||
passType: 0
|
||||
- keywords: COLOR_MULTIPLY_ADDITIVE
|
||||
passType: 0
|
||||
- keywords: COLOR_MULTIPLY_ADDITIVE SAMPLING_BLUR_FAST TONE_GRAYSCALE TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_DISSOLVE
|
||||
passType: 0
|
||||
- keywords: COLOR_MULTIPLY_ADDITIVE SAMPLING_RGB_SHIFT TONE_GRAYSCALE TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_DISSOLVE
|
||||
passType: 0
|
||||
- keywords: COLOR_MULTIPLY_LUMINANCE
|
||||
passType: 0
|
||||
- keywords: COLOR_REPLACE
|
||||
passType: 0
|
||||
- keywords: COLOR_REPLACE SAMPLING_BLUR_FAST
|
||||
passType: 0
|
||||
- keywords: COLOR_SUBTRACTIVE
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_PLAIN
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_PLAIN SHADOW_COLOR_MULTIPLY_ADDITIVE
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_SHINY
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_SHINY SAMPLING_EDGE_ALPHA
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_SHINY SHADOW_COLOR_MULTIPLY_ADDITIVE
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_SHINY TRANSITION_COLOR_MULTIPLY
|
||||
TRANSITION_PATTERN
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_SHINY TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_PATTERN
|
||||
passType: 0
|
||||
- keywords: EDGE_PLAIN SHADOW_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY TRANSITION_PATTERN
|
||||
passType: 0
|
||||
- keywords: EDGE_PLAIN TRANSITION_COLOR_MULTIPLY TRANSITION_PATTERN
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_DETAIL
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_FAST
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_FAST TONE_GRAYSCALE
|
||||
- keywords: SAMPLING_BLUR_FAST SHADOW_COLOR_MULTIPLY_ADDITIVE
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_FAST SHADOW_COLOR_MULTIPLY_ADDITIVE UNITY_UI_CLIP_RECT
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_FAST SHADOW_COLOR_REPLACE
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_FAST SHADOW_COLOR_REPLACE TONE_GRAYSCALE
|
||||
passType: 0
|
||||
- keywords: SAMPLING_BLUR_MEDIUM
|
||||
passType: 0
|
||||
@@ -70,6 +86,8 @@ ShaderVariantCollection:
|
||||
passType: 0
|
||||
- keywords: SAMPLING_RGB_SHIFT
|
||||
passType: 0
|
||||
- keywords: SHADOW_COLOR_REPLACE
|
||||
passType: 0
|
||||
- keywords: TONE_GRAYSCALE
|
||||
passType: 0
|
||||
- keywords: TONE_NEGATIVE
|
||||
@@ -84,6 +102,8 @@ ShaderVariantCollection:
|
||||
passType: 0
|
||||
- keywords: TRANSITION_BURN TRANSITION_COLOR_MULTIPLY_ADDITIVE UNITY_UI_CLIP_RECT
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY TRANSITION_PATTERN
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_DISSOLVE
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_DISSOLVE UNITY_UI_CLIP_RECT
|
||||
@@ -94,6 +114,8 @@ ShaderVariantCollection:
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_MELT UNITY_UI_CLIP_RECT
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_PATTERN
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_SHINY
|
||||
passType: 0
|
||||
- keywords: TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_SHINY UNITY_UI_CLIP_RECT
|
||||
@@ -107,17 +129,24 @@ ShaderVariantCollection:
|
||||
- first: {fileID: 4800000, guid: e65241fa80a374114b3f55ed746c04d9, type: 3}
|
||||
second:
|
||||
variants:
|
||||
- keywords: SAMPLING_RGB_SHIFT TONE_RETRO TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_SHINY
|
||||
passType: 0
|
||||
- keywords: SAMPLING_RGB_SHIFT TRANSITION_CUTOFF
|
||||
passType: 0
|
||||
- first: {fileID: 4800000, guid: 935b7be1c88464d2eb87204fdfab5a38, type: 3}
|
||||
second:
|
||||
variants:
|
||||
- keywords: COLOR_ADDITIVE GLOW_ON SAMPLING_BLUR_FAST UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: COLOR_HSV_MODIFIER GLOW_ON UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_REPLACE EDGE_PLAIN GLOW_ON UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: EDGE_COLOR_REPLACE EDGE_SHINY GLOW_ON UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_BLUR_DETAIL UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_BLUR_FAST SHADOW_COLOR_MULTIPLY_ADDITIVE UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_EDGE_LUMINANCE UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_PIXELATION UNDERLAY_ON
|
||||
@@ -127,61 +156,48 @@ ShaderVariantCollection:
|
||||
- keywords: GLOW_ON SHADOW_COLOR_REPLACE TRANSITION_BURN TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SHADOW_COLOR_REPLACE UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TONE_RETRO UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_BURN TRANSITION_COLOR_MULTIPLY_ADDITIVE UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY TRANSITION_PATTERN UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_DISSOLVE
|
||||
UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_MELT UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_PATTERN UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_SHINY UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_REPLACE TRANSITION_MELT UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: SAMPLING_PIXELATION TONE_RETRO
|
||||
passType: 0
|
||||
- keywords: SAMPLING_RGB_SHIFT TONE_RETRO TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_SHINY
|
||||
passType: 0
|
||||
- keywords: SAMPLING_RGB_SHIFT TRANSITION_CUTOFF
|
||||
passType: 0
|
||||
- first: {fileID: 4800000, guid: c67f821adbb6348a3a21573a25b55de0, type: 3}
|
||||
second:
|
||||
variants:
|
||||
- keywords: COLOR_ADDITIVE GLOW_ON SAMPLING_BLUR_FAST UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: COLOR_HSV_MODIFIER GLOW_ON UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_BLUR_DETAIL UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_EDGE_LUMINANCE UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_PIXELATION UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON SAMPLING_RGB_SHIFT UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TONE_RETRO UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_BURN TRANSITION_COLOR_MULTIPLY_ADDITIVE UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_DISSOLVE
|
||||
UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_MELT UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_SHINY UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: GLOW_ON TRANSITION_COLOR_REPLACE TRANSITION_MELT UNDERLAY_ON
|
||||
passType: 0
|
||||
- keywords: SAMPLING_PIXELATION TONE_RETRO
|
||||
passType: 0
|
||||
- first: {fileID: 4800000, guid: d1cb940e3804b4adcaf9b22083fadfad, type: 3}
|
||||
second:
|
||||
variants:
|
||||
- keywords: SAMPLING_RGB_SHIFT TONE_RETRO TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_SHINY
|
||||
passType: 0
|
||||
- keywords: SAMPLING_RGB_SHIFT TRANSITION_CUTOFF
|
||||
passType: 0
|
||||
- first: {fileID: 4800000, guid: 63a1dba10bff94661a909d63808a9a3b, type: 3}
|
||||
second:
|
||||
variants:
|
||||
- keywords: SAMPLING_RGB_SHIFT TONE_RETRO TRANSITION_COLOR_MULTIPLY_ADDITIVE
|
||||
TRANSITION_SHINY
|
||||
passType: 0
|
||||
- keywords: SAMPLING_RGB_SHIFT TRANSITION_CUTOFF
|
||||
passType: 0
|
||||
--- !u!114 &11400000
|
||||
@@ -200,6 +216,7 @@ MonoBehaviour:
|
||||
m_RuntimePresets:
|
||||
- {fileID: 1645081683573595507, guid: 3b09ad143990c4c8795c6e93760e132a, type: 3}
|
||||
- {fileID: 1645081683573595507, guid: 4f70ff0f1e25b4388b9bcb38d619f7bf, type: 3}
|
||||
m_UseHDRColorPicker: 1
|
||||
m_ShaderVariantCollection: {fileID: -8740588384831342173}
|
||||
m_ShaderVariantRegistry:
|
||||
m_OptionalShaders: []
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e9a477d4a32184f16b50f56f7de5fa4e
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 962016ab124fa4720be1e24ff58c8522
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"name": "Coffee.UIEffect.EditorTests",
|
||||
"references": [
|
||||
"Coffee.UIEffect"
|
||||
],
|
||||
"optionalUnityReferences": [
|
||||
"TestAssemblies"
|
||||
],
|
||||
"includePlatforms": [
|
||||
"Editor"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 182e53eada385475e905b8ca6d82d6ad
|
||||
AssemblyDefinitionImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Reflection;
|
||||
using NUnit.Framework;
|
||||
using UnityEditor;
|
||||
|
||||
public class ReflectionTests
|
||||
{
|
||||
[Test]
|
||||
public void ShaderVariantCollectionInspector_DrawShaderEntry()
|
||||
{
|
||||
var type = Type.GetType("UnityEditor.ShaderVariantCollectionInspector, UnityEditor");
|
||||
Assert.IsNotNull(type, "'UnityEditor.ShaderVariantCollectionInspector, UnityEditor' is not found");
|
||||
|
||||
var miDrawShaderEntry = type.GetMethod("DrawShaderEntry", BindingFlags.NonPublic | BindingFlags.Instance);
|
||||
Assert.IsNotNull(miDrawShaderEntry);
|
||||
|
||||
var parameters = miDrawShaderEntry.GetParameters();
|
||||
Assert.AreEqual(1, parameters.Length);
|
||||
Assert.AreEqual(typeof(int), parameters[0].ParameterType);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void SerializedProperty_gradientValue()
|
||||
{
|
||||
var piGradient = typeof(SerializedProperty)
|
||||
.GetProperty("gradientValue", BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance);
|
||||
Assert.IsNotNull(piGradient);
|
||||
|
||||
Assert.IsTrue(piGradient.CanRead);
|
||||
Assert.IsTrue(piGradient.CanWrite);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7c5d391ce913d41fb9118c3d28b21059
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -5,7 +5,7 @@
|
||||
"depth": 0,
|
||||
"source": "git",
|
||||
"dependencies": {},
|
||||
"hash": "5d0bd14be288153555f975240608e7ee1576b091"
|
||||
"hash": "9f5f59b492aed618d0123ce2f55d041e61c5f246"
|
||||
},
|
||||
"com.coffee.minimal-resource": {
|
||||
"version": "https://github.com/mob-sakai/Coffee.Internal.git?path=Packages/MinimalResource",
|
||||
|
||||
@@ -1,3 +1,85 @@
|
||||
## [5.3.3](https://github.com/mob-sakai/UIEffect/compare/5.3.2...5.3.3) (2025-02-06)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* when modifying TextMeshPro vertices, element disapear ([7529a7c](https://github.com/mob-sakai/UIEffect/commit/7529a7c4cd8db27a6d3312bce0a6ed6b13e40f35)), closes [#305](https://github.com/mob-sakai/UIEffect/issues/305)
|
||||
|
||||
## [5.3.2](https://github.com/mob-sakai/UIEffect/compare/5.3.1...5.3.2) (2025-02-04)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* some effects are not working correctly for TextMeshProUGUI in Unity 6 ([63de374](https://github.com/mob-sakai/UIEffect/commit/63de3742ecd7fcdcaa8dcca8dc104c7288291211))
|
||||
|
||||
## [5.3.1](https://github.com/mob-sakai/UIEffect/compare/5.3.0...5.3.1) (2025-01-27)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* shader keywords for UIEfect are not recognized in Unity 6 ([fd39abf](https://github.com/mob-sakai/UIEffect/commit/fd39abf5a71138919f8feee587576ba187075304)), closes [#301](https://github.com/mob-sakai/UIEffect/issues/301)
|
||||
|
||||
# [5.3.0](https://github.com/mob-sakai/UIEffect/compare/5.2.4...5.3.0) (2025-01-26)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `SamplingFilter.EdgeAlpha` and `SamplingFilter.EdgeLuminance` now support the `Sampling Width` property for edge width ([33b1177](https://github.com/mob-sakai/UIEffect/commit/33b1177815b935a887c5a8918748cbeafec32b6b))
|
||||
* add `EdgeMode` feature ([eadb477](https://github.com/mob-sakai/UIEffect/commit/eadb477bcd91f8909bfa7b8976241411363ee12c))
|
||||
* add `ResetOnEnable` option for `UIEffectTweener` ([e326bb7](https://github.com/mob-sakai/UIEffect/commit/e326bb77537b921df775646142105a490ae54851)), closes [#299](https://github.com/mob-sakai/UIEffect/issues/299)
|
||||
* add `TransitionAutoSpeed` property ([7a765c3](https://github.com/mob-sakai/UIEffect/commit/7a765c32d87f6dfbdb990d5b3a272dd80696b374))
|
||||
* add `TransitionFilter.Pattern` feature ([b57e98b](https://github.com/mob-sakai/UIEffect/commit/b57e98b64c61a7c7eb3ca97f3bd7e909956ee469))
|
||||
|
||||
## [5.2.4](https://github.com/mob-sakai/UIEffect/compare/5.2.3...5.2.4) (2025-01-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* properties may not update correctly when changed via code or animation ([5994f88](https://github.com/mob-sakai/UIEffect/commit/5994f8875ed2280e5c863c30f9c7900d4dce70ed)), closes [#300](https://github.com/mob-sakai/UIEffect/issues/300)
|
||||
|
||||
## [5.2.3](https://github.com/mob-sakai/UIEffect/compare/5.2.2...5.2.3) (2025-01-23)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* `SamplingFilter.None` now correctly respects the sampling scale setting ([bc1578b](https://github.com/mob-sakai/UIEffect/commit/bc1578b0ca91b830b976bf200d387d0ac6963ae6))
|
||||
* fix the shadow mode inspector in editor ([da53585](https://github.com/mob-sakai/UIEffect/commit/da535854ccbeeb98b2556423425d39058bd5f479))
|
||||
* UIEffect may not work correctly when using `FallbackAtlas` with TextMeshProUGUI ([d3779f9](https://github.com/mob-sakai/UIEffect/commit/d3779f9f57d0410fa4526527ebed30885bfbc2dd)), closes [#298](https://github.com/mob-sakai/UIEffect/issues/298)
|
||||
|
||||
## [5.2.2](https://github.com/mob-sakai/UIEffect/compare/5.2.1...5.2.2) (2025-01-18)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* in Unity 6, `Shadow Color` has no effect on TextMeshPro ([6e4d4ab](https://github.com/mob-sakai/UIEffect/commit/6e4d4ab03db786e4c28d0f2c57d9e58655c5d029)), closes [#297](https://github.com/mob-sakai/UIEffect/issues/297)
|
||||
|
||||
## [5.2.1](https://github.com/mob-sakai/UIEffect/compare/5.2.0...5.2.1) (2025-01-14)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* shadow color being transparent at maximum `Shadow Fade` ([1d849e5](https://github.com/mob-sakai/UIEffect/commit/1d849e54cb57218a67afc2f8ad36d345bfdd0f74)), closes [#296](https://github.com/mob-sakai/UIEffect/issues/296)
|
||||
* TextMeshPro is not displayed in prefab mode ([2b44837](https://github.com/mob-sakai/UIEffect/commit/2b44837bb9c93e1cc817a2c1cd112b244cd09391)), closes [#295](https://github.com/mob-sakai/UIEffect/issues/295)
|
||||
* TextMeshProUGUI disappears when the Y-axis scale is changed ([8159c09](https://github.com/mob-sakai/UIEffect/commit/8159c091e8a6805a7781046ae0f660a3be13862c)), closes [#295](https://github.com/mob-sakai/UIEffect/issues/295)
|
||||
|
||||
# [5.2.0](https://github.com/mob-sakai/UIEffect/compare/5.1.0...5.2.0) (2025-01-07)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* `Gradation` properties do not update when a preset is loaded ([edf6943](https://github.com/mob-sakai/UIEffect/commit/edf694313f101b66f760bca64593fb87037dcb3d)), closes [#291](https://github.com/mob-sakai/UIEffect/issues/291)
|
||||
* an error occurs when saving a preset ([894c561](https://github.com/mob-sakai/UIEffect/commit/894c5610d044f211067037b6c69f9860ac496ffc)), closes [#293](https://github.com/mob-sakai/UIEffect/issues/293)
|
||||
* fix gradation gradient edge (angle gradient) ([0ef6027](https://github.com/mob-sakai/UIEffect/commit/0ef60273714c7b68131f2f0d233b16335a5cd367))
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* `Angle Gradient` gradation supports fixed mode gradient ([7cb8325](https://github.com/mob-sakai/UIEffect/commit/7cb8325e445350d2175865f736186f719e1cbe00))
|
||||
* `Angle Gradient` gradation supports RectTransform pivot ([2f63adf](https://github.com/mob-sakai/UIEffect/commit/2f63adfba057bec7f8183a5b34654cdf84163a34))
|
||||
* add `Use HDR Color Picker` option for project settings (editor) ([1be0cd4](https://github.com/mob-sakai/UIEffect/commit/1be0cd45db952d05e51d508c58f65a6541df9de0)), closes [#290](https://github.com/mob-sakai/UIEffect/issues/290)
|
||||
* the `Allow To Modify Mesh Shape` property should remain unchanged when loading a preset ([f7175c0](https://github.com/mob-sakai/UIEffect/commit/f7175c037371278eb7a0c7883cffccb5c31dba0a)), closes [#294](https://github.com/mob-sakai/UIEffect/issues/294)
|
||||
* the `Sampling Scale` property should remain unchanged when loading a preset ([238a17d](https://github.com/mob-sakai/UIEffect/commit/238a17d57ddf1f6b859ce830e80a1be6c3d739f1)), closes [#292](https://github.com/mob-sakai/UIEffect/issues/292)
|
||||
|
||||
# [5.1.0](https://github.com/mob-sakai/UIEffect/compare/5.0.2...5.1.0) (2024-12-31)
|
||||
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
using UnityEngine;
|
||||
using System.Linq;
|
||||
using System;
|
||||
using System.Reflection;
|
||||
using Object = UnityEngine.Object;
|
||||
|
||||
namespace Coffee.UIEffects.Editors
|
||||
@@ -13,6 +14,17 @@ namespace Coffee.UIEffects.Editors
|
||||
[CanEditMultipleObjects]
|
||||
public class UIEffect2Editor : Editor
|
||||
{
|
||||
private static readonly PropertyInfo s_PiGradient = typeof(SerializedProperty)
|
||||
.GetProperty("gradientValue", BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance);
|
||||
|
||||
private static readonly Func<SerializedProperty, Gradient> s_GetGradient =
|
||||
(Func<SerializedProperty, Gradient>)Delegate.CreateDelegate(typeof(Func<SerializedProperty, Gradient>),
|
||||
s_PiGradient.GetMethod);
|
||||
|
||||
private static readonly Action<SerializedProperty, Gradient> s_SetGradient =
|
||||
(Action<SerializedProperty, Gradient>)Delegate.CreateDelegate(typeof(Action<SerializedProperty, Gradient>),
|
||||
s_PiGradient.SetMethod);
|
||||
|
||||
private SerializedProperty _toneFilter;
|
||||
private SerializedProperty _toneIntensity;
|
||||
|
||||
@@ -23,6 +35,7 @@ namespace Coffee.UIEffects.Editors
|
||||
|
||||
private SerializedProperty _samplingFilter;
|
||||
private SerializedProperty _samplingIntensity;
|
||||
private SerializedProperty _samplingWidth;
|
||||
private SerializedProperty _samplingScale;
|
||||
|
||||
private SerializedProperty _transitionFilter;
|
||||
@@ -35,9 +48,12 @@ namespace Coffee.UIEffects.Editors
|
||||
private SerializedProperty _transitionKeepAspectRatio;
|
||||
private SerializedProperty _transitionWidth;
|
||||
private SerializedProperty _transitionSoftness;
|
||||
private SerializedProperty _transitionRange;
|
||||
private SerializedProperty _transitionColorFilter;
|
||||
private SerializedProperty _transitionColor;
|
||||
private SerializedProperty _transitionColorGlow;
|
||||
private SerializedProperty _transitionPatternReverse;
|
||||
private SerializedProperty _transitionAutoPlaySpeed;
|
||||
|
||||
private SerializedProperty _targetMode;
|
||||
private SerializedProperty _targetColor;
|
||||
@@ -68,7 +84,15 @@ namespace Coffee.UIEffects.Editors
|
||||
private SerializedProperty _gradationScale;
|
||||
private SerializedProperty _gradationRotation;
|
||||
|
||||
private bool _expandOthers;
|
||||
private SerializedProperty _edgeMode;
|
||||
private SerializedProperty _edgeWidth;
|
||||
private SerializedProperty _edgeColorFilter;
|
||||
private SerializedProperty _edgeColor;
|
||||
private SerializedProperty _edgeShinyWidth;
|
||||
private SerializedProperty _edgeShinyAutoPlaySpeed;
|
||||
private SerializedProperty _patternArea;
|
||||
|
||||
private bool _expandOthers = true;
|
||||
private SerializedProperty _allowToModifyMeshShape;
|
||||
|
||||
private void OnEnable()
|
||||
@@ -77,7 +101,6 @@ namespace Coffee.UIEffects.Editors
|
||||
|
||||
_toneFilter = serializedObject.FindProperty("m_ToneFilter");
|
||||
_toneIntensity = serializedObject.FindProperty("m_ToneIntensity");
|
||||
var toneParams = serializedObject.FindProperty("m_ToneParams");
|
||||
|
||||
_colorFilter = serializedObject.FindProperty("m_ColorFilter");
|
||||
_color = serializedObject.FindProperty("m_Color");
|
||||
@@ -86,6 +109,7 @@ namespace Coffee.UIEffects.Editors
|
||||
|
||||
_samplingFilter = serializedObject.FindProperty("m_SamplingFilter");
|
||||
_samplingIntensity = serializedObject.FindProperty("m_SamplingIntensity");
|
||||
_samplingWidth = serializedObject.FindProperty("m_SamplingWidth");
|
||||
_samplingScale = serializedObject.FindProperty("m_SamplingScale");
|
||||
|
||||
_transitionFilter = serializedObject.FindProperty("m_TransitionFilter");
|
||||
@@ -98,9 +122,12 @@ namespace Coffee.UIEffects.Editors
|
||||
_transitionKeepAspectRatio = serializedObject.FindProperty("m_TransitionKeepAspectRatio");
|
||||
_transitionWidth = serializedObject.FindProperty("m_TransitionWidth");
|
||||
_transitionSoftness = serializedObject.FindProperty("m_TransitionSoftness");
|
||||
_transitionRange = serializedObject.FindProperty("m_TransitionRange");
|
||||
_transitionColorFilter = serializedObject.FindProperty("m_TransitionColorFilter");
|
||||
_transitionColor = serializedObject.FindProperty("m_TransitionColor");
|
||||
_transitionColorGlow = serializedObject.FindProperty("m_TransitionColorGlow");
|
||||
_transitionPatternReverse = serializedObject.FindProperty("m_TransitionPatternReverse");
|
||||
_transitionAutoPlaySpeed = serializedObject.FindProperty("m_TransitionAutoPlaySpeed");
|
||||
|
||||
_targetMode = serializedObject.FindProperty("m_TargetMode");
|
||||
_targetColor = serializedObject.FindProperty("m_TargetColor");
|
||||
@@ -123,6 +150,14 @@ namespace Coffee.UIEffects.Editors
|
||||
_shadowColor = serializedObject.FindProperty("m_ShadowColor");
|
||||
_shadowColorGlow = serializedObject.FindProperty("m_ShadowColorGlow");
|
||||
|
||||
_edgeMode = serializedObject.FindProperty("m_EdgeMode");
|
||||
_edgeWidth = serializedObject.FindProperty("m_EdgeWidth");
|
||||
_edgeColorFilter = serializedObject.FindProperty("m_EdgeColorFilter");
|
||||
_edgeColor = serializedObject.FindProperty("m_EdgeColor");
|
||||
_edgeShinyWidth = serializedObject.FindProperty("m_EdgeShinyWidth");
|
||||
_edgeShinyAutoPlaySpeed = serializedObject.FindProperty("m_EdgeShinyAutoPlaySpeed");
|
||||
_patternArea = serializedObject.FindProperty("m_PatternArea");
|
||||
|
||||
_gradationMode = serializedObject.FindProperty("m_GradationMode");
|
||||
_gradationColor1 = serializedObject.FindProperty("m_GradationColor1");
|
||||
_gradationColor2 = serializedObject.FindProperty("m_GradationColor2");
|
||||
@@ -162,7 +197,7 @@ namespace Coffee.UIEffects.Editors
|
||||
{
|
||||
EditorGUI.indentLevel++;
|
||||
EditorGUILayout.PropertyField(_colorIntensity);
|
||||
DrawColor(_colorFilter, _color, prevColorFilter);
|
||||
DrawColor(_color, (ColorFilter)_colorFilter.intValue, prevColorFilter, false);
|
||||
EditorGUILayout.PropertyField(_colorGlow);
|
||||
EditorGUI.indentLevel--;
|
||||
}
|
||||
@@ -175,7 +210,12 @@ namespace Coffee.UIEffects.Editors
|
||||
{
|
||||
EditorGUI.indentLevel++;
|
||||
EditorGUILayout.PropertyField(_samplingIntensity);
|
||||
EditorGUILayout.PropertyField(_samplingScale);
|
||||
if (_samplingFilter.intValue == (int)SamplingFilter.EdgeAlpha
|
||||
|| _samplingFilter.intValue == (int)SamplingFilter.EdgeLuminance)
|
||||
{
|
||||
EditorGUILayout.PropertyField(_samplingWidth);
|
||||
}
|
||||
|
||||
EditorGUI.indentLevel--;
|
||||
}
|
||||
|
||||
@@ -195,14 +235,25 @@ namespace Coffee.UIEffects.Editors
|
||||
EditorGUILayout.PropertyField(_transitionReverse, EditorGUIUtility.TrTempContent("Reverse"));
|
||||
EditorGUI.indentLevel--;
|
||||
|
||||
if (2 < _transitionFilter.intValue)
|
||||
if (_transitionFilter.intValue == (int)TransitionFilter.Pattern)
|
||||
{
|
||||
EditorGUILayout.PropertyField(_transitionWidth, EditorGUIUtility.TrTempContent("Pattern Size"));
|
||||
EditorGUILayout.PropertyField(_transitionRange, EditorGUIUtility.TrTempContent("Pattern Range"));
|
||||
EditorGUILayout.PropertyField(_transitionPatternReverse,
|
||||
EditorGUIUtility.TrTempContent("Pattern Reverse"));
|
||||
DrawColor(_transitionColorFilter, _transitionColor, null);
|
||||
}
|
||||
else if (2 < _transitionFilter.intValue)
|
||||
{
|
||||
EditorGUILayout.PropertyField(_transitionWidth);
|
||||
EditorGUILayout.PropertyField(_transitionSoftness);
|
||||
prevColorFilter = (ColorFilter)_transitionColorFilter.intValue;
|
||||
EditorGUILayout.PropertyField(_transitionColorFilter);
|
||||
DrawColor(_transitionColorFilter, _transitionColor, prevColorFilter);
|
||||
EditorGUILayout.PropertyField(_transitionColorGlow);
|
||||
DrawColor(_transitionColorFilter, _transitionColor, _transitionColorGlow);
|
||||
}
|
||||
|
||||
EditorGUILayout.PropertyField(_transitionAutoPlaySpeed);
|
||||
if (0 < _transitionFilter.intValue && !Mathf.Approximately(0, _transitionAutoPlaySpeed.floatValue))
|
||||
{
|
||||
EditorApplication.QueuePlayerLoopUpdate();
|
||||
}
|
||||
|
||||
EditorGUI.indentLevel--;
|
||||
@@ -246,6 +297,7 @@ namespace Coffee.UIEffects.Editors
|
||||
EditorGUILayout.Slider(_shadowDistanceX, 0, 1, "Reflection");
|
||||
EditorGUILayout.PropertyField(_shadowDistanceY, EditorGUIUtility.TrTempContent("Offset"));
|
||||
EditorGUILayout.PropertyField(_shadowMirrorScale);
|
||||
EditorGUILayout.PropertyField(_shadowFade);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -257,13 +309,11 @@ namespace Coffee.UIEffects.Editors
|
||||
|
||||
EditorGUILayout.PropertyField(_shadowDistance);
|
||||
EditorGUILayout.PropertyField(_shadowIteration);
|
||||
DrawColor(_shadowColorFilter, _shadowColor, _shadowColorGlow, false);
|
||||
EditorGUILayout.PropertyField(_shadowFade);
|
||||
}
|
||||
|
||||
EditorGUILayout.PropertyField(_shadowColorFilter);
|
||||
EditorGUILayout.PropertyField(_shadowColor);
|
||||
EditorGUILayout.PropertyField(_shadowColorGlow);
|
||||
EditorGUILayout.PropertyField(_shadowFade);
|
||||
|
||||
// Shadow blur intensity
|
||||
switch ((SamplingFilter)_samplingFilter.intValue)
|
||||
{
|
||||
case SamplingFilter.BlurFast:
|
||||
@@ -286,15 +336,16 @@ namespace Coffee.UIEffects.Editors
|
||||
case GradationMode.HorizontalGradient:
|
||||
case GradationMode.VerticalGradient:
|
||||
case GradationMode.AngleGradient:
|
||||
EditorGUILayout.PropertyField(_gradationGradient);
|
||||
DrawGradientField(_gradationGradient);
|
||||
break;
|
||||
default:
|
||||
EditorGUILayout.PropertyField(_gradationColor1);
|
||||
DrawColorPickerField(_gradationColor1);
|
||||
var r = EditorGUILayout.GetControlRect();
|
||||
r.width -= 20;
|
||||
EditorGUI.PropertyField(r, _gradationColor2);
|
||||
r.width -= 24;
|
||||
r.height = EditorGUIUtility.singleLineHeight;
|
||||
DrawColorPickerField(r, _gradationColor2);
|
||||
|
||||
r.x += r.width;
|
||||
r.x += r.width + 4;
|
||||
r.width = 20;
|
||||
// Swap colors
|
||||
if (GUI.Button(r, EditorGUIUtility.IconContent("preaudioloopoff"), "iconbutton"))
|
||||
@@ -318,20 +369,85 @@ namespace Coffee.UIEffects.Editors
|
||||
EditorGUI.indentLevel--;
|
||||
}
|
||||
|
||||
// Edge Mode
|
||||
DrawSeparator();
|
||||
if (DrawHeaderPopup(_edgeMode))
|
||||
{
|
||||
EditorGUILayout.PropertyField(_edgeWidth);
|
||||
DrawColor(_edgeColorFilter, _edgeColor, null);
|
||||
|
||||
if ((EdgeMode)_edgeMode.intValue == EdgeMode.Shiny)
|
||||
{
|
||||
EditorGUILayout.PropertyField(_edgeShinyWidth);
|
||||
EditorGUILayout.PropertyField(_edgeShinyAutoPlaySpeed);
|
||||
|
||||
if (!Mathf.Approximately(0, _edgeShinyAutoPlaySpeed.floatValue))
|
||||
{
|
||||
EditorApplication.QueuePlayerLoopUpdate();
|
||||
}
|
||||
}
|
||||
|
||||
if (_transitionFilter.intValue == (int)TransitionFilter.Pattern)
|
||||
{
|
||||
EditorGUILayout.PropertyField(_patternArea);
|
||||
}
|
||||
}
|
||||
|
||||
DrawSeparator();
|
||||
_expandOthers = EditorGUILayout.BeginFoldoutHeaderGroup(_expandOthers, "Others");
|
||||
if (_expandOthers)
|
||||
{
|
||||
EditorGUILayout.PropertyField(_samplingScale);
|
||||
EditorGUILayout.PropertyField(_allowToModifyMeshShape);
|
||||
}
|
||||
}
|
||||
|
||||
private static void DrawColor(SerializedProperty filter, SerializedProperty color, ColorFilter prevFilter)
|
||||
private static void DrawColorPickerField(SerializedProperty color, bool showAlpha = true)
|
||||
{
|
||||
if (filter.intValue == (int)ColorFilter.None)
|
||||
var r = EditorGUILayout.GetControlRect();
|
||||
r.height = EditorGUIUtility.singleLineHeight;
|
||||
DrawColorPickerField(r, color, showAlpha);
|
||||
}
|
||||
|
||||
private static void DrawColorPickerField(Rect rect, SerializedProperty color, bool showAlpha = true)
|
||||
{
|
||||
var label = EditorGUIUtility.TrTempContent(color.displayName);
|
||||
label.tooltip = color.tooltip;
|
||||
var hdr = UIEffectProjectSettings.useHdrColorPicker;
|
||||
EditorGUI.showMixedValue = color.hasMultipleDifferentValues;
|
||||
|
||||
EditorGUI.BeginChangeCheck();
|
||||
var colorValue = EditorGUI.ColorField(rect, label, color.colorValue, true, showAlpha, hdr);
|
||||
if (EditorGUI.EndChangeCheck())
|
||||
{
|
||||
color.colorValue = colorValue;
|
||||
}
|
||||
else if (filter.intValue == (int)ColorFilter.HsvModifier)
|
||||
}
|
||||
|
||||
private static void DrawGradientField(SerializedProperty gradient)
|
||||
{
|
||||
var r = EditorGUILayout.GetControlRect();
|
||||
r.height = EditorGUIUtility.singleLineHeight;
|
||||
|
||||
var label = EditorGUIUtility.TrTempContent(gradient.displayName);
|
||||
label.tooltip = gradient.tooltip;
|
||||
var hdr = UIEffectProjectSettings.useHdrColorPicker;
|
||||
EditorGUI.showMixedValue = gradient.hasMultipleDifferentValues;
|
||||
|
||||
EditorGUI.BeginChangeCheck();
|
||||
var gradientValue = EditorGUI.GradientField(r, label, s_GetGradient(gradient), hdr);
|
||||
if (EditorGUI.EndChangeCheck())
|
||||
{
|
||||
s_SetGradient(gradient, gradientValue);
|
||||
}
|
||||
}
|
||||
|
||||
private static void DrawColor(SerializedProperty color, ColorFilter filter, ColorFilter prevFilter,
|
||||
bool showAlpha = true)
|
||||
{
|
||||
if (filter == ColorFilter.None) return;
|
||||
|
||||
if (filter == ColorFilter.HsvModifier)
|
||||
{
|
||||
if (prevFilter != ColorFilter.HsvModifier)
|
||||
{
|
||||
@@ -343,7 +459,7 @@ namespace Coffee.UIEffects.Editors
|
||||
EditorGUILayout.Slider(color.FindPropertyRelative("b"), -1f, 1f, "Value");
|
||||
EditorGUILayout.Slider(color.FindPropertyRelative("a"), 0, 1, "Alpha");
|
||||
}
|
||||
else if (filter.intValue == (int)ColorFilter.Contrast)
|
||||
else if (filter == ColorFilter.Contrast)
|
||||
{
|
||||
if (prevFilter != ColorFilter.Contrast)
|
||||
{
|
||||
@@ -361,10 +477,28 @@ namespace Coffee.UIEffects.Editors
|
||||
color.colorValue = Color.white;
|
||||
}
|
||||
|
||||
EditorGUILayout.PropertyField(color);
|
||||
DrawColorPickerField(color, showAlpha);
|
||||
}
|
||||
}
|
||||
|
||||
private static void DrawColor(SerializedProperty filter, SerializedProperty color, SerializedProperty glow,
|
||||
bool showAlpha = true)
|
||||
{
|
||||
var prevFilter = (ColorFilter)filter.intValue;
|
||||
EditorGUILayout.PropertyField(filter);
|
||||
if (filter.intValue == (int)ColorFilter.None) return;
|
||||
|
||||
EditorGUI.indentLevel++;
|
||||
DrawColor(color, (ColorFilter)filter.intValue, prevFilter, showAlpha);
|
||||
|
||||
if (glow != null)
|
||||
{
|
||||
EditorGUILayout.PropertyField(glow);
|
||||
}
|
||||
|
||||
EditorGUI.indentLevel--;
|
||||
}
|
||||
|
||||
private static bool DrawHeaderPopup(SerializedProperty sp)
|
||||
{
|
||||
var r = EditorGUILayout.GetControlRect();
|
||||
@@ -404,7 +538,10 @@ namespace Coffee.UIEffects.Editors
|
||||
r.x += r.width;
|
||||
if (GUI.Button(r, EditorGUIUtility.TrTempContent("Save As New"), "MiniButton"))
|
||||
{
|
||||
UIEffectProjectSettings.SaveAsNewPreset(targets.OfType<UIEffect>().FirstOrDefault());
|
||||
EditorApplication.delayCall += () =>
|
||||
{
|
||||
UIEffectProjectSettings.SaveAsNewPreset(targets.OfType<UIEffect>().FirstOrDefault());
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace Coffee.UIEffects.Editors
|
||||
public class UIEffectProjectSettingsEditor : Editor
|
||||
{
|
||||
private ReorderableList _reorderableList;
|
||||
private SerializedProperty _useHDRColorPicker;
|
||||
private SerializedProperty _transformSensitivity;
|
||||
private bool _isInitialized;
|
||||
private ShaderVariantRegistryEditor _shaderVariantRegistryEditor;
|
||||
@@ -18,6 +19,7 @@ namespace Coffee.UIEffects.Editors
|
||||
if (_isInitialized) return;
|
||||
|
||||
_transformSensitivity = serializedObject.FindProperty("m_TransformSensitivity");
|
||||
_useHDRColorPicker = serializedObject.FindProperty("m_UseHDRColorPicker");
|
||||
var runtimePresets = serializedObject.FindProperty("m_RuntimePresets");
|
||||
_reorderableList = new ReorderableList(serializedObject, runtimePresets, true, true, true, true);
|
||||
_reorderableList.drawHeaderCallback = rect => EditorGUI.LabelField(rect, "Runtime Presets");
|
||||
@@ -63,9 +65,17 @@ namespace Coffee.UIEffects.Editors
|
||||
InitializeIfNeeded();
|
||||
|
||||
// Settings
|
||||
// Transform sensitivity.
|
||||
EditorGUILayout.PropertyField(_transformSensitivity);
|
||||
|
||||
// Runtime Presets
|
||||
_reorderableList.DoLayoutList();
|
||||
|
||||
// Editor
|
||||
// Use HDR color pickers.
|
||||
EditorGUILayout.PropertyField(_useHDRColorPicker);
|
||||
|
||||
// Shader
|
||||
// Shader registry
|
||||
EditorGUILayout.Space();
|
||||
EditorGUILayout.LabelField("Shader", EditorStyles.boldLabel);
|
||||
|
||||
@@ -12,6 +12,7 @@ namespace Coffee.UIEffects.Editors
|
||||
private SerializedProperty _target;
|
||||
private SerializedProperty _useTargetTransform;
|
||||
private SerializedProperty _samplingScale;
|
||||
private SerializedProperty _allowToModifyMeshShape;
|
||||
private Editor _uiEffectEditor;
|
||||
|
||||
private void OnEnable()
|
||||
@@ -19,6 +20,7 @@ namespace Coffee.UIEffects.Editors
|
||||
_target = serializedObject.FindProperty("m_Target");
|
||||
_useTargetTransform = serializedObject.FindProperty("m_UseTargetTransform");
|
||||
_samplingScale = serializedObject.FindProperty("m_SamplingScale");
|
||||
_allowToModifyMeshShape = serializedObject.FindProperty("m_AllowToModifyMeshShape");
|
||||
}
|
||||
|
||||
public override void OnInspectorGUI()
|
||||
@@ -27,6 +29,7 @@ namespace Coffee.UIEffects.Editors
|
||||
EditorGUILayout.PropertyField(_target);
|
||||
EditorGUILayout.PropertyField(_useTargetTransform);
|
||||
EditorGUILayout.PropertyField(_samplingScale);
|
||||
EditorGUILayout.PropertyField(_allowToModifyMeshShape);
|
||||
|
||||
if (_target.objectReferenceValue)
|
||||
{
|
||||
|
||||
@@ -16,6 +16,7 @@ namespace Coffee.UIEffects.Editors
|
||||
private SerializedProperty _duration;
|
||||
private SerializedProperty _interval;
|
||||
private SerializedProperty _playOnEnable;
|
||||
private SerializedProperty _resetTimeOnEnable;
|
||||
private SerializedProperty _updateMode;
|
||||
private SerializedProperty _wrapMode;
|
||||
private SerializedProperty _onComplete;
|
||||
@@ -28,6 +29,7 @@ namespace Coffee.UIEffects.Editors
|
||||
_direction = serializedObject.FindProperty("m_Direction");
|
||||
_curve = serializedObject.FindProperty("m_Curve");
|
||||
_playOnEnable = serializedObject.FindProperty("m_PlayOnEnable");
|
||||
_resetTimeOnEnable = serializedObject.FindProperty("m_ResetTimeOnEnable");
|
||||
_delay = serializedObject.FindProperty("m_Delay");
|
||||
_duration = serializedObject.FindProperty("m_Duration");
|
||||
_interval = serializedObject.FindProperty("m_Interval");
|
||||
@@ -54,6 +56,7 @@ namespace Coffee.UIEffects.Editors
|
||||
EditorGUILayout.PropertyField(_duration);
|
||||
EditorGUILayout.PropertyField(_interval);
|
||||
EditorGUILayout.PropertyField(_playOnEnable);
|
||||
EditorGUILayout.PropertyField(_resetTimeOnEnable);
|
||||
EditorGUILayout.PropertyField(_wrapMode);
|
||||
EditorGUILayout.PropertyField(_updateMode);
|
||||
EditorGUILayout.PropertyField(_onComplete);
|
||||
|
||||
@@ -73,8 +73,9 @@ Combine various filters, such as grayscale, blur, and dissolve, to decorate your
|
||||
|
||||
## 🎮 Demo
|
||||
|
||||

|
||||

|
||||

|
||||

|
||||

|
||||
|
||||
[WebGL Demo](https://mob-sakai.github.io/UIEffect/)
|
||||
|
||||
@@ -94,7 +95,7 @@ _This package requires **Unity 2020.3 or later**._
|
||||
```
|
||||
- To update the package, use Package Manager UI (`Window > Package Manager`) or run the following command with `@{version}`:
|
||||
```
|
||||
openupm add com.coffee.ui-effect@5.0.0
|
||||
openupm add com.coffee.ui-effect@5.3.0
|
||||
```
|
||||
|
||||
### Install via UPM (with Package Manager UI)
|
||||
@@ -103,7 +104,7 @@ _This package requires **Unity 2020.3 or later**._
|
||||
- Click `+ > Add package from git URL...` and input the repository URL: `https://github.com/mob-sakai/UIEffect.git?path=Packages/src`
|
||||

|
||||
- To update the package, change suffix `#{version}` to the target version.
|
||||
- e.g. `https://github.com/mob-sakai/UIEffect.git?path=Packages/src#5.0.0`
|
||||
- e.g. `https://github.com/mob-sakai/UIEffect.git?path=Packages/src#5.3.0`
|
||||
|
||||
### Install via UPM (Manually)
|
||||
|
||||
@@ -118,7 +119,7 @@ _This package requires **Unity 2020.3 or later**._
|
||||
```
|
||||
|
||||
- To update the package, change suffix `#{version}` to the target version.
|
||||
- e.g. `"com.coffee.ui-effect": "https://github.com/mob-sakai/UIEffect.git?path=Packages/src#5.0.0",`
|
||||
- e.g. `"com.coffee.ui-effect": "https://github.com/mob-sakai/UIEffect.git?path=Packages/src#5.3.0",`
|
||||
|
||||
### Install as Embedded Package
|
||||
|
||||
@@ -183,7 +184,7 @@ If upgrading from UIEffect v4 to v5, note the following breaking changes:
|
||||
|
||||
### Component: UIEffect
|
||||
|
||||

|
||||

|
||||
|
||||
The `UIEffect` component applies visual effects to UI elements, allowing various effects to be achieved by combining multiple filters.
|
||||
|
||||
@@ -202,18 +203,21 @@ The `UIEffect` component applies visual effects to UI elements, allowing various
|
||||
|
||||
- **Sampling Filter**: `None`, `Blur Fast`, `Blur Medium`, `Blur Detail`, `Pixelation`, `Rgb Shift`, `Edge Luminescence`, `Edge Alpha`
|
||||
- **Sampling Intensity**: 0.0 (no effect) - 1.0 (full effect).
|
||||
- **Sampling Scale**: The referencing scale during sampling.
|
||||
- Larger values are suitable for high-resolution textures.
|
||||
- **Sampling Width**: The width of the sampling effect.
|
||||
|
||||
#### Transition Filter
|
||||
|
||||
- **Transition Filter**: `None`, `Fade`, `Cutoff`, `Dissolve`, `Shiny`, `Mask`, `Melt`, `Burn`
|
||||
- **Transition Filter**: `None`, `Fade`, `Cutoff`, `Dissolve`, `Shiny`, `Mask`, `Melt`, `Burn`, `Pattern`
|
||||
- **Transition Rate**: 0.0 (no effect) - 1.0 (full effect).
|
||||
- **Transition Tex**: The texture used for the transition filter.- **Transition Width**: The width where the transition color is applied.
|
||||
- **Transition Width**: The width where the transition color is applied.
|
||||
- **Transition Pattern Range**: The range of the pattern.
|
||||
- **Transition Pattern Reverse**: Reverse the pattern.
|
||||
- **Transition Softness**: The softness of the boundary for the transition color.
|
||||
- **Transition Color Filter**: Specifies the transition color.
|
||||
- **Transition Color**: The color of the transition.
|
||||
- **Transition Color Glow**: Set the transition color to glow.
|
||||
- **Transition Auto Play Speed**: The speed of the transition animation. You can use this property to loop the `TransitionRate` without tweener or animation.
|
||||
|
||||
#### Target Mode
|
||||
|
||||
@@ -243,7 +247,7 @@ The `UIEffect` component applies visual effects to UI elements, allowing various
|
||||
|
||||
#### Gradation Mode
|
||||
|
||||
- **Gradation Mode**: `None`, `Horizontal Gradient`, `Horizontal`, `Vertical Gradient`, `Vertical`, `Radial Fast`, `Radial Detail`, `Diagonal To Right Bottom`, `Diagonal To Right Top`, `Diagonal To Left Bottom`, `Angle`, `Angle Gradient`
|
||||
- **Gradation Mode**: `None`, `Plain`, `Shiny`
|
||||
- **Gradation Gradient**: The gradient of the gradation.
|
||||
- **Gradation Color 1**: The first color of the gradation.
|
||||
- **Gradation Color 2**: The second color of the gradation.
|
||||
@@ -255,17 +259,29 @@ The `UIEffect` component applies visual effects to UI elements, allowing various
|
||||
> `Horizontal Gradient` and `Vertical Gradient` divide the mesh horizontally or vertically and apply a gradient.
|
||||
> This is very fast but only supports Full Rect.
|
||||
> `Angle Gradient` divides the mesh at the specified angle and applies a gradient.
|
||||
> It can be applied to meshes other than Full Rect because it applies the gradient according to the original mesh shape.
|
||||
> It can be applied to meshes other than Full Rect because it applies the gradient according to the original mesh shape.
|
||||
> `Gradation Gradient` has two modes, `Blend` and `Fixed`.
|
||||
|
||||
#### Edge Mode
|
||||
|
||||
- **Edge Mode**: `None`, `Plain`, `Shiny`
|
||||
- **Edge Width**: The width of the edge.
|
||||
- **Edge Color Filter**: Specifies the edge color.
|
||||
- **Edge Color**: The color of the edge.
|
||||
- **Edge Shiny Width**: The width of the edge shiny.
|
||||
- **Edge Shiny Auto Play Speed**: The speed of the edge shiny.
|
||||
|
||||
#### Others
|
||||
|
||||
- **Sampling Scale**: The referencing scale during sampling.
|
||||
- Larger values are suitable for high-resolution textures.
|
||||
- **Allow To Modify Mesh Shape**: If enabled, the mesh shape can be modified.
|
||||
|
||||
<br><br>
|
||||
|
||||
### Component: UIEffectTweener
|
||||
|
||||

|
||||

|
||||
|
||||
The `UIEffectTweener` component animates the effect, enabling easy control over effect animations without the need for an `AnimationClip`.
|
||||
|
||||
@@ -278,6 +294,7 @@ The `UIEffectTweener` component animates the effect, enabling easy control over
|
||||
- **Play On Enable**: `None`, `Forward`, `Reverse`, `Keep Direction`
|
||||
- Play the animation automatically when the component is enabled.
|
||||
- If `None` is selected, the animation will not play automatically. You can play it using the `Play`, `PlayForward` or `PlayReverse` method.
|
||||
- **Reset Time On Enable**: Reset the tweening time when the component is enabled.
|
||||
- **Wrap Mode**: `Once`, `Loop`, `PingPongOnce`, `PingPongLoop`
|
||||
- **Update Mode**: `Normal`, `UnscaledTime`, `Manual`
|
||||
- **On Complete**: A event that is triggered when the animation is completed.
|
||||
@@ -288,13 +305,14 @@ You can preview the animation using the seek bar and play button.
|
||||
|
||||
### Component: UIEffectReplica
|
||||
|
||||

|
||||

|
||||
|
||||
The `UIEffectReplica` component applies visual effects to UI elements by replicating the settings of another `UIEffect` component. This allows the same effect to be applied across multiple UI elements simultaneously.
|
||||
|
||||
- **Target**: The target `UIEffect` component to replicate.
|
||||
- **Use Target Transform**: Use the target's transform for some effects.
|
||||
- **Sampling Scale**: Override the sampling scale.
|
||||
- **Sampling Scale**: Override the sampling scale.
|
||||
- **Allow To Modify Mesh Shape**: If enabled, the mesh shape can be modified.
|
||||

|
||||
|
||||
<br><br>
|
||||
@@ -321,6 +339,10 @@ Alternatively, you can manually import the resources by following these steps:
|
||||
4. Add the `UIEffect` component to a TextMeshProUGUI element and adjust the effect settings. The `<font>` and `<sprite>` tags are also supported.
|
||||

|
||||
|
||||
> [!TIP]
|
||||
> `TextMeshPro Support` may change with updates to the UIEffect package.
|
||||
> If issues occur, try importing it again.
|
||||
|
||||
<br><br>
|
||||
|
||||
### Runtime/Editor Preset for UIEffect
|
||||
@@ -333,6 +355,10 @@ You can create and use presets for `UIEffect` components.
|
||||
- In the [Project Settings](#project-settings), you can register saved editor presets as runtime presets.
|
||||
- Runtime presets can be loaded using the `UIEffect.LoadPreset(presetName)` method.
|
||||
|
||||
> [!TIP]
|
||||
> Editor presets are saved in the `UIEffectPresets` directory.
|
||||
> You can also create subdirectories to customize the preset menu.
|
||||
|
||||
<br><br>
|
||||
|
||||
### Usage with Code
|
||||
@@ -362,13 +388,22 @@ UIEffectProjectSettings.shaderVariantCollection.WarmUp();
|
||||
|
||||
### Project Settings
|
||||
|
||||

|
||||

|
||||
|
||||
You can adjust the project-wide settings for UIEffect. (`Edit > Project Settings > UI > UIEffect`)
|
||||
|
||||
#### Settings
|
||||
|
||||
- **Transform Sensitivity**: `Low`, `Medium`, `High`
|
||||
- Set the sensitivity of the transformation when `Use Target Transform` is enabled in `UIEffectReplica` component.
|
||||
- **Runtime Presets**: A list of presets that can be loaded at runtime. Load them using `UIEffect.LoadPreset(presetName)` method.
|
||||
|
||||
#### Editor
|
||||
|
||||
- **Use HDR Color Picker**: If enabled, the HDR color picker will be used in the inspector.
|
||||
|
||||
#### Shader
|
||||
|
||||
- **Optional Shaders (UIEffect)**: A list of shaders that will be prioritized when a ui-effect shader is
|
||||
requested.
|
||||
- If the shader is included in the list, that shader will be used.
|
||||
@@ -392,6 +427,8 @@ Here are the limitations of UIEffect:
|
||||
- Shader variants used at runtime must be registered in the [Project Settings](#project-settings).
|
||||
- When using UIEffect with TextMeshProUGUI, `SamplingFilter.BlurMedium` and `SamplingFilter.BlurDetail` are not supported due to performance considerations.
|
||||
- These will automatically fall back to `SamplingFilter.BlurFast`.
|
||||
- UIEffect supports default UI components (`Image`, `RawImage`, `Text`) and `TextMeshProUGUI`.
|
||||
- If you want to use UIEffect with other components, create a issue or pull request.
|
||||
|
||||
<br><br>
|
||||
|
||||
|
||||
@@ -46,7 +46,8 @@ namespace Coffee.UIEffects
|
||||
Shiny = 4,
|
||||
Mask = 5,
|
||||
Melt = 6,
|
||||
Burn = 7
|
||||
Burn = 7,
|
||||
Pattern = 8
|
||||
}
|
||||
|
||||
public enum BlendType
|
||||
@@ -76,6 +77,20 @@ namespace Coffee.UIEffects
|
||||
Mirror
|
||||
}
|
||||
|
||||
public enum EdgeMode
|
||||
{
|
||||
None = 0,
|
||||
Plain,
|
||||
Shiny
|
||||
}
|
||||
|
||||
public enum PatternArea
|
||||
{
|
||||
All = 0,
|
||||
Inner = 1,
|
||||
Edge = 2
|
||||
}
|
||||
|
||||
public enum GradationMode
|
||||
{
|
||||
None = 0,
|
||||
|
||||
@@ -0,0 +1,144 @@
|
||||
using System;
|
||||
using UnityEditor;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Coffee.UIEffectInternal
|
||||
{
|
||||
[Serializable]
|
||||
public struct MinMax01
|
||||
{
|
||||
[SerializeField]
|
||||
private float m_Min;
|
||||
|
||||
[SerializeField]
|
||||
private float m_Max;
|
||||
|
||||
public MinMax01(float min, float max)
|
||||
{
|
||||
m_Min = Mathf.Clamp01(Mathf.Min(min, max));
|
||||
m_Max = Mathf.Clamp01(Mathf.Max(min, max));
|
||||
}
|
||||
|
||||
public float min
|
||||
{
|
||||
get => m_Min;
|
||||
set
|
||||
{
|
||||
m_Min = Mathf.Clamp01(value);
|
||||
m_Max = Mathf.Max(value, m_Max);
|
||||
}
|
||||
}
|
||||
|
||||
public float max
|
||||
{
|
||||
get => m_Max;
|
||||
set
|
||||
{
|
||||
m_Max = Mathf.Clamp01(value);
|
||||
m_Min = Mathf.Min(value, m_Min);
|
||||
}
|
||||
}
|
||||
|
||||
public float average => (m_Max + m_Min) * 0.5f;
|
||||
|
||||
public bool Approximately(MinMax01 other)
|
||||
{
|
||||
return Mathf.Approximately(m_Min, other.m_Min) && Mathf.Approximately(m_Max, other.m_Max);
|
||||
}
|
||||
}
|
||||
|
||||
#if UNITY_EDITOR
|
||||
[CustomPropertyDrawer(typeof(MinMax01))]
|
||||
public class MinMaxRangeDrawer : PropertyDrawer
|
||||
{
|
||||
private const float k_NumWidth = 50;
|
||||
private const float k_Space = 5;
|
||||
private SerializedProperty _max;
|
||||
private SerializedProperty _min;
|
||||
|
||||
private static bool IsSingleLine(GUIContent label)
|
||||
{
|
||||
return EditorGUIUtility.wideMode || label == null || string.IsNullOrEmpty(label.text);
|
||||
}
|
||||
|
||||
public override float GetPropertyHeight(SerializedProperty property, GUIContent label)
|
||||
{
|
||||
return IsSingleLine(label) ? 18 : 36;
|
||||
}
|
||||
|
||||
public override void OnGUI(Rect position, SerializedProperty prop, GUIContent label)
|
||||
{
|
||||
EditorGUI.BeginProperty(position, label, prop);
|
||||
|
||||
if (_min == null)
|
||||
{
|
||||
prop.Next(true);
|
||||
_min = prop.Copy();
|
||||
prop.Next(true);
|
||||
_max = prop.Copy();
|
||||
}
|
||||
|
||||
if (IsSingleLine(label))
|
||||
{
|
||||
position = EditorGUI.PrefixLabel(position, GUIUtility.GetControlID(FocusType.Passive), label);
|
||||
}
|
||||
else
|
||||
{
|
||||
EditorGUI.PrefixLabel(position, GUIUtility.GetControlID(FocusType.Passive), label);
|
||||
var indent = (EditorGUI.indentLevel + 1) * 15f;
|
||||
position = new Rect(position.x + indent, position.y + 18, position.width - indent, 16);
|
||||
}
|
||||
|
||||
var min = _min.floatValue;
|
||||
var max = _max.floatValue;
|
||||
if (Draw(position, ref min, ref max))
|
||||
{
|
||||
_min.floatValue = min;
|
||||
_max.floatValue = max;
|
||||
}
|
||||
|
||||
EditorGUI.EndProperty();
|
||||
}
|
||||
|
||||
public static bool Draw(Rect position, ref float minValue, ref float maxValue)
|
||||
{
|
||||
var indentLevel = EditorGUI.indentLevel;
|
||||
EditorGUI.indentLevel = 0;
|
||||
EditorGUI.BeginChangeCheck();
|
||||
|
||||
var rect = new Rect(position.x, position.y, k_NumWidth, position.height);
|
||||
minValue = Mathf.Clamp(EditorGUI.FloatField(rect, minValue), 0, maxValue);
|
||||
|
||||
rect.x += rect.width + k_Space;
|
||||
rect.width = position.width - k_NumWidth * 2 - k_Space * 2;
|
||||
EditorGUI.MinMaxSlider(rect, ref minValue, ref maxValue, 0, 1);
|
||||
|
||||
rect.x += rect.width + k_Space;
|
||||
rect.width = k_NumWidth;
|
||||
maxValue = Mathf.Clamp(EditorGUI.FloatField(rect, maxValue), minValue, 1);
|
||||
|
||||
EditorGUI.indentLevel = indentLevel;
|
||||
return EditorGUI.EndChangeCheck();
|
||||
}
|
||||
|
||||
public static bool DrawLayout(GUIContent label, ref float minValue, ref float maxValue)
|
||||
{
|
||||
Rect position;
|
||||
if (IsSingleLine(label))
|
||||
{
|
||||
position = EditorGUILayout.GetControlRect(true, 18f);
|
||||
position = EditorGUI.PrefixLabel(position, GUIUtility.GetControlID(FocusType.Passive), label);
|
||||
}
|
||||
else
|
||||
{
|
||||
position = EditorGUILayout.GetControlRect(true, 36f);
|
||||
EditorGUI.PrefixLabel(position, GUIUtility.GetControlID(FocusType.Passive), label);
|
||||
var indent = (EditorGUI.indentLevel + 1) * 15f;
|
||||
position = new Rect(position.x + indent, position.y + 18, position.width - indent, 16);
|
||||
}
|
||||
|
||||
return Draw(position, ref minValue, ref maxValue);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: dacf9fb8cdb9a4a62a74b629d84cabd3
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -26,7 +26,6 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
protected float m_ColorIntensity = 1;
|
||||
|
||||
[ColorUsage(false, true)]
|
||||
[SerializeField]
|
||||
protected Color m_Color = Color.white;
|
||||
|
||||
@@ -40,6 +39,10 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
protected float m_SamplingIntensity = 0.5f;
|
||||
|
||||
[Range(0.5f, 10f)]
|
||||
[SerializeField]
|
||||
protected float m_SamplingWidth = 1;
|
||||
|
||||
[PowerRange(0.01f, 100f, 10f)]
|
||||
[SerializeField]
|
||||
protected float m_SamplingScale = 1f;
|
||||
@@ -78,20 +81,28 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
protected float m_TransitionSoftness = 0.2f;
|
||||
|
||||
[SerializeField]
|
||||
protected MinMax01 m_TransitionRange = new MinMax01(0, 1);
|
||||
|
||||
[SerializeField]
|
||||
protected ColorFilter m_TransitionColorFilter = ColorFilter.MultiplyAdditive;
|
||||
|
||||
[ColorUsage(true, true)]
|
||||
[SerializeField]
|
||||
protected Color m_TransitionColor = new Color(0f, 0.5f, 1.0f, 1.0f);
|
||||
|
||||
[SerializeField]
|
||||
protected bool m_TransitionColorGlow = false;
|
||||
|
||||
[SerializeField]
|
||||
protected bool m_TransitionPatternReverse = false;
|
||||
|
||||
[Range(-5, 5)]
|
||||
[SerializeField]
|
||||
protected float m_TransitionAutoPlaySpeed = 0f;
|
||||
|
||||
[SerializeField]
|
||||
protected TargetMode m_TargetMode = TargetMode.None;
|
||||
|
||||
[ColorUsage(false, false)]
|
||||
[SerializeField]
|
||||
protected Color m_TargetColor = Color.white;
|
||||
|
||||
@@ -137,7 +148,6 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
protected ColorFilter m_ShadowColorFilter = ColorFilter.Replace;
|
||||
|
||||
[ColorUsage(false, true)]
|
||||
[SerializeField]
|
||||
protected Color m_ShadowColor = Color.white;
|
||||
|
||||
@@ -148,11 +158,9 @@ namespace Coffee.UIEffects
|
||||
protected GradationMode m_GradationMode = GradationMode.None;
|
||||
|
||||
[SerializeField]
|
||||
[ColorUsage(true, true)]
|
||||
protected Color m_GradationColor1 = Color.white;
|
||||
|
||||
[SerializeField]
|
||||
[ColorUsage(true, true)]
|
||||
protected Color m_GradationColor2 = Color.white;
|
||||
|
||||
[SerializeField]
|
||||
@@ -173,6 +181,30 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
protected bool m_AllowToModifyMeshShape = true;
|
||||
|
||||
[SerializeField]
|
||||
protected EdgeMode m_EdgeMode = EdgeMode.None;
|
||||
|
||||
[Range(0, 1)]
|
||||
[SerializeField]
|
||||
protected float m_EdgeWidth = 0.5f;
|
||||
|
||||
[SerializeField]
|
||||
protected ColorFilter m_EdgeColorFilter = ColorFilter.Replace;
|
||||
|
||||
[SerializeField]
|
||||
protected Color m_EdgeColor = Color.white;
|
||||
|
||||
[Range(0, 1)]
|
||||
[SerializeField]
|
||||
protected float m_EdgeShinyWidth = 0.5f;
|
||||
|
||||
[Range(-5, 5)]
|
||||
[SerializeField]
|
||||
protected float m_EdgeShinyAutoPlaySpeed = 1f;
|
||||
|
||||
[SerializeField]
|
||||
protected PatternArea m_PatternArea = PatternArea.Inner;
|
||||
|
||||
/// <summary>
|
||||
/// Tone filter for rendering.
|
||||
/// </summary>
|
||||
@@ -183,7 +215,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_ToneFilter == value) return;
|
||||
context.toneFilter = m_ToneFilter = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -198,7 +230,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_ToneIntensity, value)) return;
|
||||
context.toneIntensity = m_ToneIntensity = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -212,7 +244,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_ColorFilter == value) return;
|
||||
context.colorFilter = m_ColorFilter = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -227,7 +259,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_ColorIntensity, value)) return;
|
||||
context.colorIntensity = m_ColorIntensity = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -239,7 +271,7 @@ namespace Coffee.UIEffects
|
||||
m_Color.a = 1;
|
||||
if (m_Color == value) return;
|
||||
context.color = m_Color = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -250,7 +282,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_ColorGlow == value) return;
|
||||
context.colorGlow = m_ColorGlow = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -265,7 +297,7 @@ namespace Coffee.UIEffects
|
||||
if (m_SamplingFilter == value) return;
|
||||
context.samplingFilter = m_SamplingFilter = value;
|
||||
SetVerticesDirty();
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -280,7 +312,19 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_SamplingIntensity, value)) return;
|
||||
context.samplingIntensity = m_SamplingIntensity = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public float samplingWidth
|
||||
{
|
||||
get => m_SamplingWidth;
|
||||
set
|
||||
{
|
||||
value = Mathf.Clamp(value, 0.5f, 10);
|
||||
if (Mathf.Approximately(m_SamplingWidth, value)) return;
|
||||
context.samplingWidth = m_SamplingWidth = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -292,13 +336,13 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0.01f, 100);
|
||||
if (Mathf.Approximately(m_SamplingScale, value)) return;
|
||||
m_SamplingScale = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public override float actualSamplingScale => samplingFilter != SamplingFilter.None
|
||||
? Mathf.Clamp(m_SamplingScale, 0.01f, 100)
|
||||
: 1;
|
||||
public override float actualSamplingScale => Mathf.Clamp(m_SamplingScale, 0.01f, 100);
|
||||
|
||||
public override bool canModifyShape => m_AllowToModifyMeshShape;
|
||||
|
||||
/// <summary>
|
||||
/// Transition filter for rendering.
|
||||
@@ -311,7 +355,7 @@ namespace Coffee.UIEffects
|
||||
if (m_TransitionFilter == value) return;
|
||||
context.transitionFilter = m_TransitionFilter = value;
|
||||
SetVerticesDirty();
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -326,7 +370,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_TransitionRate, value)) return;
|
||||
context.transitionRate = m_TransitionRate = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -337,7 +381,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionReverse == value) return;
|
||||
context.transitionReverse = m_TransitionReverse = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -348,7 +392,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionTex == value) return;
|
||||
context.transitionTex = m_TransitionTex = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -359,7 +403,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionTexScale == value) return;
|
||||
context.transitionTexScale = m_TransitionTexScale = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -370,7 +414,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionTexOffset == value) return;
|
||||
context.transitionTexOffset = m_TransitionTexOffset = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -404,7 +448,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_TransitionWidth, value)) return;
|
||||
context.transitionWidth = m_TransitionWidth = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -416,7 +460,18 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_TransitionSoftness, value)) return;
|
||||
context.transitionSoftness = m_TransitionSoftness = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public MinMax01 transitionRange
|
||||
{
|
||||
get => m_TransitionRange;
|
||||
set
|
||||
{
|
||||
if (m_TransitionRange.Approximately(value)) return;
|
||||
context.transitionRange = m_TransitionRange = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -427,7 +482,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionColorFilter == value) return;
|
||||
context.transitionColorFilter = m_TransitionColorFilter = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -438,7 +493,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionColor == value) return;
|
||||
context.transitionColor = m_TransitionColor = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -449,7 +504,30 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TransitionColorGlow == value) return;
|
||||
context.transitionColorGlow = m_TransitionColorGlow = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public bool transitionPatternReverse
|
||||
{
|
||||
get => m_TransitionPatternReverse;
|
||||
set
|
||||
{
|
||||
if (m_TransitionPatternReverse == value) return;
|
||||
context.transitionPatternReverse = m_TransitionPatternReverse = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public float transitionAutoPlaySpeed
|
||||
{
|
||||
get => m_TransitionAutoPlaySpeed;
|
||||
set
|
||||
{
|
||||
value = Mathf.Clamp(value, -5, 5);
|
||||
if (Mathf.Approximately(m_TransitionAutoPlaySpeed, value)) return;
|
||||
context.transitionAutoPlaySpeed = m_TransitionAutoPlaySpeed = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -460,7 +538,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TargetMode == value) return;
|
||||
context.targetMode = m_TargetMode = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -471,7 +549,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_TargetColor == value) return;
|
||||
context.targetColor = m_TargetColor = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -483,7 +561,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_TargetRange, value)) return;
|
||||
context.targetRange = m_TargetRange = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -495,7 +573,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_TargetSoftness, value)) return;
|
||||
context.targetSoftness = m_TargetSoftness = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -508,7 +586,7 @@ namespace Coffee.UIEffects
|
||||
(m_SrcBlendMode, m_DstBlendMode) = (m_BlendType, m_SrcBlendMode, m_DstBlendMode).Convert();
|
||||
context.srcBlendMode = m_SrcBlendMode;
|
||||
context.dstBlendMode = m_DstBlendMode;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -524,7 +602,7 @@ namespace Coffee.UIEffects
|
||||
if (m_SrcBlendMode == value) return;
|
||||
context.srcBlendMode = m_SrcBlendMode = value;
|
||||
m_BlendType = (m_SrcBlendMode, m_DstBlendMode).Convert();
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -540,7 +618,7 @@ namespace Coffee.UIEffects
|
||||
if (m_DstBlendMode == value) return;
|
||||
context.dstBlendMode = m_DstBlendMode = value;
|
||||
m_BlendType = (m_SrcBlendMode, m_DstBlendMode).Convert();
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -610,7 +688,7 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_ShadowBlurIntensity, value)) return;
|
||||
context.shadowBlurIntensity = m_ShadowBlurIntensity = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -621,7 +699,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_ShadowColorFilter == value) return;
|
||||
context.shadowColorFilter = m_ShadowColorFilter = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -632,7 +710,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_ShadowColor == value) return;
|
||||
context.shadowColor = m_ShadowColor = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -643,7 +721,87 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (m_ShadowColorGlow == value) return;
|
||||
context.shadowColorGlow = m_ShadowColorGlow = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public EdgeMode edgeMode
|
||||
{
|
||||
get => m_EdgeMode;
|
||||
set
|
||||
{
|
||||
if (m_EdgeMode == value) return;
|
||||
context.edgeMode = m_EdgeMode = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public float edgeWidth
|
||||
{
|
||||
get => m_EdgeWidth;
|
||||
set
|
||||
{
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_EdgeWidth, value)) return;
|
||||
context.edgeWidth = m_EdgeWidth = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public ColorFilter edgeColorFilter
|
||||
{
|
||||
get => m_EdgeColorFilter;
|
||||
set
|
||||
{
|
||||
if (m_EdgeColorFilter == value) return;
|
||||
context.edgeColorFilter = m_EdgeColorFilter = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public Color edgeColor
|
||||
{
|
||||
get => m_EdgeColor;
|
||||
set
|
||||
{
|
||||
if (m_EdgeColor == value) return;
|
||||
context.edgeColor = m_EdgeColor = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public float edgeShinyWidth
|
||||
{
|
||||
get => m_EdgeShinyWidth;
|
||||
set
|
||||
{
|
||||
value = Mathf.Clamp(value, 0, 1);
|
||||
if (Mathf.Approximately(m_EdgeShinyWidth, value)) return;
|
||||
context.edgeShinyWidth = m_EdgeShinyWidth = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public float edgeShinyAutoPlaySpeed
|
||||
{
|
||||
get => m_EdgeShinyAutoPlaySpeed;
|
||||
set
|
||||
{
|
||||
value = Mathf.Clamp(value, -5, 5);
|
||||
if (Mathf.Approximately(m_EdgeShinyAutoPlaySpeed, value)) return;
|
||||
context.edgeShinyAutoPlaySpeed = m_EdgeShinyAutoPlaySpeed = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public PatternArea patternArea
|
||||
{
|
||||
get => m_PatternArea;
|
||||
set
|
||||
{
|
||||
if (m_PatternArea == value) return;
|
||||
context.patternArea = m_PatternArea = value;
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -720,7 +878,7 @@ namespace Coffee.UIEffects
|
||||
set
|
||||
{
|
||||
if (m_AllowToModifyMeshShape == value) return;
|
||||
context.allowToModifyMeshShape = m_AllowToModifyMeshShape = value;
|
||||
m_AllowToModifyMeshShape = value;
|
||||
SetVerticesDirty();
|
||||
}
|
||||
}
|
||||
@@ -732,13 +890,13 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
(m_SrcBlendMode, m_DstBlendMode) = (m_BlendType, m_SrcBlendMode, m_DstBlendMode).Convert();
|
||||
base.OnEnable();
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
|
||||
protected override void OnDisable()
|
||||
{
|
||||
base.OnDisable();
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
|
||||
protected override void OnDestroy()
|
||||
@@ -798,6 +956,7 @@ namespace Coffee.UIEffects
|
||||
|
||||
c.samplingFilter = m_SamplingFilter;
|
||||
c.samplingIntensity = m_SamplingIntensity;
|
||||
c.samplingWidth = m_SamplingWidth;
|
||||
|
||||
c.transitionFilter = m_TransitionFilter;
|
||||
c.transitionRate = m_TransitionRate;
|
||||
@@ -809,9 +968,12 @@ namespace Coffee.UIEffects
|
||||
c.transitionKeepAspectRatio = m_TransitionKeepAspectRatio;
|
||||
c.transitionWidth = m_TransitionWidth;
|
||||
c.transitionSoftness = m_TransitionSoftness;
|
||||
c.transitionRange = m_TransitionRange;
|
||||
c.transitionColorFilter = m_TransitionColorFilter;
|
||||
c.transitionColor = m_TransitionColor;
|
||||
c.transitionColorGlow = m_TransitionColorGlow;
|
||||
c.transitionPatternReverse = m_TransitionPatternReverse;
|
||||
c.transitionAutoPlaySpeed = m_TransitionAutoPlaySpeed;
|
||||
|
||||
c.targetMode = m_TargetMode;
|
||||
c.targetColor = m_TargetColor;
|
||||
@@ -831,6 +993,14 @@ namespace Coffee.UIEffects
|
||||
c.shadowColor = m_ShadowColor;
|
||||
c.shadowColorGlow = m_ShadowColorGlow;
|
||||
|
||||
c.edgeMode = m_EdgeMode;
|
||||
c.edgeWidth = m_EdgeWidth;
|
||||
c.edgeColorFilter = m_EdgeColorFilter;
|
||||
c.edgeColor = m_EdgeColor;
|
||||
c.edgeShinyWidth = m_EdgeShinyWidth;
|
||||
c.edgeShinyAutoPlaySpeed = m_EdgeShinyAutoPlaySpeed;
|
||||
c.patternArea = m_PatternArea;
|
||||
|
||||
c.gradationMode = m_GradationMode;
|
||||
c.gradationColor1 = m_GradationColor1;
|
||||
c.gradationColor2 = m_GradationColor2;
|
||||
@@ -838,8 +1008,6 @@ namespace Coffee.UIEffects
|
||||
c.gradationOffset = m_GradationOffset;
|
||||
c.gradationScale = m_GradationScale;
|
||||
c.gradationRotation = m_GradationRotation;
|
||||
|
||||
c.allowToModifyMeshShape = m_AllowToModifyMeshShape;
|
||||
}
|
||||
|
||||
public override void ApplyContextToMaterial()
|
||||
@@ -893,6 +1061,7 @@ namespace Coffee.UIEffects
|
||||
case TransitionFilter.None:
|
||||
case TransitionFilter.Shiny:
|
||||
case TransitionFilter.Mask:
|
||||
case TransitionFilter.Pattern:
|
||||
return true;
|
||||
default:
|
||||
return transitionRate < 1;
|
||||
@@ -925,7 +1094,7 @@ namespace Coffee.UIEffects
|
||||
|
||||
m_SamplingFilter = preset.m_SamplingFilter;
|
||||
m_SamplingIntensity = preset.m_SamplingIntensity;
|
||||
m_SamplingScale = preset.m_SamplingScale;
|
||||
m_SamplingWidth = preset.m_SamplingWidth;
|
||||
|
||||
m_TransitionFilter = preset.m_TransitionFilter;
|
||||
m_TransitionRate = preset.m_TransitionRate;
|
||||
@@ -937,9 +1106,12 @@ namespace Coffee.UIEffects
|
||||
m_TransitionKeepAspectRatio = preset.m_TransitionKeepAspectRatio;
|
||||
m_TransitionWidth = preset.m_TransitionWidth;
|
||||
m_TransitionSoftness = preset.m_TransitionSoftness;
|
||||
m_TransitionRange = preset.m_TransitionRange;
|
||||
m_TransitionColorFilter = preset.m_TransitionColorFilter;
|
||||
m_TransitionColor = preset.m_TransitionColor;
|
||||
m_TransitionColorGlow = preset.m_TransitionColorGlow;
|
||||
m_TransitionPatternReverse = preset.m_TransitionPatternReverse;
|
||||
m_TransitionAutoPlaySpeed = preset.m_TransitionAutoPlaySpeed;
|
||||
|
||||
m_TargetMode = preset.m_TargetMode;
|
||||
m_TargetColor = preset.m_TargetColor;
|
||||
@@ -959,8 +1131,24 @@ namespace Coffee.UIEffects
|
||||
m_ShadowColor = preset.m_ShadowColor;
|
||||
m_ShadowColorGlow = preset.m_ShadowColorGlow;
|
||||
|
||||
m_EdgeMode = preset.m_EdgeMode;
|
||||
m_EdgeWidth = preset.m_EdgeWidth;
|
||||
m_EdgeColorFilter = preset.m_EdgeColorFilter;
|
||||
m_EdgeColor = preset.m_EdgeColor;
|
||||
m_EdgeShinyWidth = preset.m_EdgeShinyWidth;
|
||||
m_EdgeShinyAutoPlaySpeed = preset.m_EdgeShinyAutoPlaySpeed;
|
||||
m_PatternArea = preset.m_PatternArea;
|
||||
|
||||
m_GradationMode = preset.m_GradationMode;
|
||||
m_GradationColor1 = preset.m_GradationColor1;
|
||||
m_GradationColor2 = preset.m_GradationColor2;
|
||||
m_GradationGradient = new Gradient();
|
||||
m_GradationGradient.SetKeys(preset.m_GradationGradient.colorKeys, preset.m_GradationGradient.alphaKeys);
|
||||
m_GradationOffset = preset.m_GradationOffset;
|
||||
m_GradationScale = preset.m_GradationScale;
|
||||
m_GradationRotation = preset.m_GradationRotation;
|
||||
|
||||
UpdateContext(context);
|
||||
ApplyContextToMaterial();
|
||||
SetVerticesDirty();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
@@ -978,6 +1166,7 @@ namespace Coffee.UIEffects
|
||||
|
||||
m_SamplingFilter = c.samplingFilter;
|
||||
m_SamplingIntensity = c.samplingIntensity;
|
||||
m_SamplingWidth = c.samplingWidth;
|
||||
|
||||
m_TransitionFilter = c.transitionFilter;
|
||||
m_TransitionRate = c.transitionRate;
|
||||
@@ -989,9 +1178,12 @@ namespace Coffee.UIEffects
|
||||
m_TransitionKeepAspectRatio = c.transitionKeepAspectRatio;
|
||||
m_TransitionWidth = c.transitionWidth;
|
||||
m_TransitionSoftness = c.transitionSoftness;
|
||||
m_TransitionRange = c.transitionRange;
|
||||
m_TransitionColorFilter = c.transitionColorFilter;
|
||||
m_TransitionColor = c.transitionColor;
|
||||
m_TransitionColorGlow = c.transitionColorGlow;
|
||||
m_TransitionPatternReverse = c.transitionPatternReverse;
|
||||
m_TransitionAutoPlaySpeed = c.transitionAutoPlaySpeed;
|
||||
|
||||
m_TargetMode = c.targetMode;
|
||||
m_TargetColor = c.targetColor;
|
||||
@@ -1012,18 +1204,24 @@ namespace Coffee.UIEffects
|
||||
m_ShadowColor = c.shadowColor;
|
||||
m_ShadowColorGlow = c.shadowColorGlow;
|
||||
|
||||
m_EdgeMode = c.edgeMode;
|
||||
m_EdgeWidth = c.edgeWidth;
|
||||
m_EdgeColorFilter = c.edgeColorFilter;
|
||||
m_EdgeColor = c.edgeColor;
|
||||
m_EdgeShinyWidth = c.edgeShinyWidth;
|
||||
m_EdgeShinyAutoPlaySpeed = c.edgeShinyAutoPlaySpeed;
|
||||
m_PatternArea = c.patternArea;
|
||||
|
||||
m_GradationMode = c.gradationMode;
|
||||
m_GradationColor1 = c.gradationColor1;
|
||||
m_GradationColor2 = c.gradationColor2;
|
||||
m_GradationGradient = c.gradationGradient;
|
||||
m_GradationGradient = new Gradient();
|
||||
m_GradationGradient.SetKeys(c.gradationGradient.colorKeys, c.gradationGradient.alphaKeys);
|
||||
m_GradationOffset = c.gradationOffset;
|
||||
m_GradationScale = c.gradationScale;
|
||||
m_GradationRotation = c.gradationRotation;
|
||||
|
||||
m_AllowToModifyMeshShape = c.allowToModifyMeshShape;
|
||||
|
||||
UpdateContext(context);
|
||||
ApplyContextToMaterial();
|
||||
SetVerticesDirty();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.CompilerServices;
|
||||
using Coffee.UIEffectInternal;
|
||||
using UnityEngine;
|
||||
@@ -6,9 +5,6 @@ using UnityEngine.EventSystems;
|
||||
using UnityEngine.Profiling;
|
||||
using UnityEngine.UI;
|
||||
using UnityEditor;
|
||||
#if TMP_ENABLE
|
||||
using TMPro;
|
||||
#endif
|
||||
|
||||
[assembly: InternalsVisibleTo("UIEffect")]
|
||||
[assembly: InternalsVisibleTo("Coffee.UIEffect.Editor")]
|
||||
@@ -19,9 +15,6 @@ namespace Coffee.UIEffects
|
||||
[DisallowMultipleComponent]
|
||||
public abstract class UIEffectBase : UIBehaviour, IMeshModifier, IMaterialModifier, ICanvasRaycastFilter
|
||||
{
|
||||
private static readonly VertexHelper s_VertexHelper = new VertexHelper();
|
||||
private static Mesh s_Mesh;
|
||||
|
||||
private static readonly InternalObjectPool<UIEffectContext> s_ContextPool =
|
||||
new InternalObjectPool<UIEffectContext>(() => new UIEffectContext(), x => true, x => x.Reset());
|
||||
|
||||
@@ -32,6 +25,7 @@ namespace Coffee.UIEffects
|
||||
public Graphic graphic => _graphic ? _graphic : _graphic = GetComponent<Graphic>();
|
||||
public virtual uint effectId => (uint)GetInstanceID();
|
||||
public virtual float actualSamplingScale => 1;
|
||||
public virtual bool canModifyShape => true;
|
||||
|
||||
public virtual UIEffectContext context
|
||||
{
|
||||
@@ -51,15 +45,6 @@ namespace Coffee.UIEffects
|
||||
|
||||
protected override void OnEnable()
|
||||
{
|
||||
#if TMP_ENABLE
|
||||
if (graphic is TextMeshProUGUI)
|
||||
{
|
||||
_prevLossyScaleY = transform.lossyScale.y;
|
||||
UIExtraCallbacks.onAfterCanvasRebuild += CheckSDFScaleForTMP;
|
||||
UIExtraCallbacks.onScreenSizeChanged += SetVerticesDirtyForTMP;
|
||||
}
|
||||
#endif
|
||||
|
||||
UpdateContext(context);
|
||||
SetMaterialDirty();
|
||||
SetVerticesDirty();
|
||||
@@ -67,11 +52,6 @@ namespace Coffee.UIEffects
|
||||
|
||||
protected override void OnDisable()
|
||||
{
|
||||
#if TMP_ENABLE
|
||||
UIExtraCallbacks.onScreenSizeChanged -= SetVerticesDirtyForTMP;
|
||||
UIExtraCallbacks.onAfterCanvasRebuild -= CheckSDFScaleForTMP;
|
||||
#endif
|
||||
|
||||
MaterialRepository.Release(ref _material);
|
||||
SetMaterialDirty();
|
||||
SetVerticesDirty();
|
||||
@@ -90,7 +70,7 @@ namespace Coffee.UIEffects
|
||||
{
|
||||
if (!isActiveAndEnabled || context == null) return;
|
||||
|
||||
context.ModifyMesh(graphic, transitionRoot, vh);
|
||||
context.ModifyMesh(graphic, transitionRoot, vh, canModifyShape);
|
||||
}
|
||||
|
||||
public virtual Material GetModifiedMaterial(Material baseMaterial)
|
||||
@@ -152,39 +132,19 @@ namespace Coffee.UIEffects
|
||||
protected override void OnDidApplyAnimationProperties()
|
||||
{
|
||||
UpdateContext(context);
|
||||
ApplyContextToMaterial();
|
||||
SetVerticesDirty();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
|
||||
public virtual void SetVerticesDirty()
|
||||
{
|
||||
#if TMP_ENABLE
|
||||
if (graphic is TextMeshProUGUI textMeshProUGUI && textMeshProUGUI.isActiveAndEnabled)
|
||||
{
|
||||
if (isActiveAndEnabled)
|
||||
{
|
||||
OnTMPChanged(textMeshProUGUI);
|
||||
var canvas = graphic.canvas;
|
||||
if (canvas && graphic.isActiveAndEnabled)
|
||||
{
|
||||
canvas.additionalShaderChannels |= AdditionalCanvasShaderChannels.TexCoord2;
|
||||
}
|
||||
}
|
||||
else if (0 < textMeshProUGUI.textInfo?.meshInfo?.Length
|
||||
&& 0 < textMeshProUGUI.textInfo.meshInfo[0].vertexCount)
|
||||
{
|
||||
textMeshProUGUI.UpdateVertexData();
|
||||
}
|
||||
}
|
||||
else
|
||||
#endif
|
||||
if (graphic)
|
||||
{
|
||||
graphic.SetVerticesDirty();
|
||||
var canvas = graphic.canvas;
|
||||
if (canvas && graphic.isActiveAndEnabled)
|
||||
{
|
||||
canvas.additionalShaderChannels |= AdditionalCanvasShaderChannels.TexCoord1;
|
||||
}
|
||||
GraphicProxy.Find(graphic).SetVerticesDirty(graphic);
|
||||
#if UNITY_EDITOR
|
||||
EditorApplication.QueuePlayerLoopUpdate();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
@@ -193,6 +153,9 @@ namespace Coffee.UIEffects
|
||||
if (graphic)
|
||||
{
|
||||
graphic.SetMaterialDirty();
|
||||
#if UNITY_EDITOR
|
||||
EditorApplication.QueuePlayerLoopUpdate();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
@@ -213,120 +176,6 @@ namespace Coffee.UIEffects
|
||||
#endif
|
||||
}
|
||||
|
||||
#if TMP_ENABLE
|
||||
#if UNITY_EDITOR
|
||||
[InitializeOnLoadMethod]
|
||||
#else
|
||||
[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.BeforeSceneLoad)]
|
||||
#endif
|
||||
private static void InitializeOnLoad()
|
||||
{
|
||||
TMPro_EventManager.TEXT_CHANGED_EVENT.Add(obj =>
|
||||
{
|
||||
if (obj is TextMeshProUGUI textMeshProUGUI)
|
||||
{
|
||||
OnTMPChanged(textMeshProUGUI);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private static void OnTMPChanged(TextMeshProUGUI textMeshProUGUI)
|
||||
{
|
||||
if (!textMeshProUGUI.TryGetComponent<UIEffectBase>(out var effect)) return;
|
||||
if (!effect || !effect.isActiveAndEnabled) return;
|
||||
|
||||
if (!s_Mesh)
|
||||
{
|
||||
s_Mesh = new Mesh();
|
||||
s_Mesh.MarkDynamic();
|
||||
}
|
||||
|
||||
var target = effect is UIEffect uiEffect
|
||||
? uiEffect
|
||||
: effect is UIEffectReplica parentReplica
|
||||
? parentReplica.target
|
||||
: null;
|
||||
var subMeshes = InternalListPool<TMP_SubMeshUI>.Rent();
|
||||
var modifiers = InternalListPool<IMeshModifier>.Rent();
|
||||
textMeshProUGUI.GetComponentsInChildren(subMeshes, 1);
|
||||
for (var i = 0; i < textMeshProUGUI.textInfo.meshInfo.Length; i++)
|
||||
{
|
||||
var meshInfo = textMeshProUGUI.textInfo.meshInfo[i];
|
||||
s_VertexHelper.Clear();
|
||||
meshInfo.mesh.CopyTo(s_VertexHelper, meshInfo.vertexCount, meshInfo.vertexCount * 6 / 4);
|
||||
if (i == 0)
|
||||
{
|
||||
textMeshProUGUI.GetComponents(modifiers);
|
||||
foreach (var modifier in modifiers)
|
||||
{
|
||||
modifier.ModifyMesh(s_VertexHelper);
|
||||
}
|
||||
|
||||
s_VertexHelper.FillMesh(s_Mesh);
|
||||
textMeshProUGUI.canvasRenderer.SetMesh(s_Mesh);
|
||||
}
|
||||
else if (i - 1 < subMeshes.Count)
|
||||
{
|
||||
var subMeshUI = GetSubMeshUI(subMeshes, meshInfo.material);
|
||||
if (!target || !subMeshUI) break;
|
||||
|
||||
var replica = subMeshUI.GetOrAddComponent<UIEffectReplica>();
|
||||
replica.target = target;
|
||||
|
||||
subMeshUI.GetComponents(modifiers);
|
||||
foreach (var modifier in modifiers)
|
||||
{
|
||||
modifier.ModifyMesh(s_VertexHelper);
|
||||
}
|
||||
|
||||
s_VertexHelper.FillMesh(s_Mesh);
|
||||
replica.ApplyContextToMaterial();
|
||||
subMeshUI.canvasRenderer.SetMesh(s_Mesh);
|
||||
}
|
||||
else
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
InternalListPool<IMeshModifier>.Return(ref modifiers);
|
||||
InternalListPool<TMP_SubMeshUI>.Return(ref subMeshes);
|
||||
s_Mesh.Clear(false);
|
||||
}
|
||||
|
||||
private static TMP_SubMeshUI GetSubMeshUI(List<TMP_SubMeshUI> subMeshes, Material material)
|
||||
{
|
||||
for (var j = 0; j < subMeshes.Count; j++)
|
||||
{
|
||||
if (subMeshes[j].sharedMaterial == material) return subMeshes[j];
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
private void SetVerticesDirtyForTMP()
|
||||
{
|
||||
if (graphic && graphic.isActiveAndEnabled)
|
||||
{
|
||||
graphic.SetVerticesDirty();
|
||||
}
|
||||
}
|
||||
|
||||
private void CheckSDFScaleForTMP()
|
||||
{
|
||||
var lossyScaleY = transform.lossyScale.y;
|
||||
if (Mathf.Approximately(_prevLossyScaleY, lossyScaleY)) return;
|
||||
|
||||
_prevLossyScaleY = lossyScaleY;
|
||||
if (graphic is TextMeshProUGUI textMeshProUGUI && graphic.isActiveAndEnabled)
|
||||
{
|
||||
OnTMPChanged(textMeshProUGUI);
|
||||
}
|
||||
}
|
||||
|
||||
private float _prevLossyScaleY;
|
||||
#endif
|
||||
|
||||
public abstract void SetRate(float rate, UIEffectTweener.CullingMask cullingMask);
|
||||
public abstract bool IsRaycastLocationValid(Vector2 sp, Camera eventCamera);
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ namespace Coffee.UIEffects
|
||||
private static readonly int s_ColorIntensity = Shader.PropertyToID("_ColorIntensity");
|
||||
private static readonly int s_ColorGlow = Shader.PropertyToID("_ColorGlow");
|
||||
private static readonly int s_SamplingIntensity = Shader.PropertyToID("_SamplingIntensity");
|
||||
private static readonly int s_SamplingWidth = Shader.PropertyToID("_SamplingWidth");
|
||||
private static readonly int s_SamplingScale = Shader.PropertyToID("_SamplingScale");
|
||||
private static readonly int s_TransitionRate = Shader.PropertyToID("_TransitionRate");
|
||||
private static readonly int s_TransitionReverse = Shader.PropertyToID("_TransitionReverse");
|
||||
@@ -27,15 +28,23 @@ namespace Coffee.UIEffects
|
||||
private static readonly int s_TransitionTex_ST = Shader.PropertyToID("_TransitionTex_ST");
|
||||
private static readonly int s_TransitionWidth = Shader.PropertyToID("_TransitionWidth");
|
||||
private static readonly int s_TransitionSoftness = Shader.PropertyToID("_TransitionSoftness");
|
||||
private static readonly int s_TransitionRange = Shader.PropertyToID("_TransitionRange");
|
||||
private static readonly int s_TransitionColorFilter = Shader.PropertyToID("_TransitionColorFilter");
|
||||
private static readonly int s_TransitionColor = Shader.PropertyToID("_TransitionColor");
|
||||
private static readonly int s_TransitionColorGlow = Shader.PropertyToID("_TransitionColorGlow");
|
||||
private static readonly int s_TransitionPatternReverse = Shader.PropertyToID("_TransitionPatternReverse");
|
||||
private static readonly int s_TransitionAutoPlaySpeed = Shader.PropertyToID("_TransitionAutoPlaySpeed");
|
||||
private static readonly int s_TargetColor = Shader.PropertyToID("_TargetColor");
|
||||
private static readonly int s_TargetRange = Shader.PropertyToID("_TargetRange");
|
||||
private static readonly int s_TargetSoftness = Shader.PropertyToID("_TargetSoftness");
|
||||
private static readonly int s_ShadowColor = Shader.PropertyToID("_ShadowColor");
|
||||
private static readonly int s_ShadowBlurIntensity = Shader.PropertyToID("_ShadowBlurIntensity");
|
||||
private static readonly int s_ShadowColorGlow = Shader.PropertyToID("_ShadowColorGlow");
|
||||
private static readonly int s_EdgeWidth = Shader.PropertyToID("_EdgeWidth");
|
||||
private static readonly int s_EdgeColor = Shader.PropertyToID("_EdgeColor");
|
||||
private static readonly int s_EdgeShinyAutoPlaySpeed = Shader.PropertyToID("_EdgeShinyAutoPlaySpeed");
|
||||
private static readonly int s_EdgeShinyWidth = Shader.PropertyToID("_EdgeShinyWidth");
|
||||
private static readonly int s_PatternArea = Shader.PropertyToID("_PatternArea");
|
||||
|
||||
private static readonly string[] s_ToneKeywords =
|
||||
{
|
||||
@@ -81,7 +90,8 @@ namespace Coffee.UIEffects
|
||||
"TRANSITION_SHINY",
|
||||
"TRANSITION_MASK",
|
||||
"TRANSITION_MELT",
|
||||
"TRANSITION_BURN"
|
||||
"TRANSITION_BURN",
|
||||
"TRANSITION_PATTERN"
|
||||
};
|
||||
|
||||
private static readonly string[] s_TransitionColorKeywords =
|
||||
@@ -117,6 +127,26 @@ namespace Coffee.UIEffects
|
||||
"SHADOW_COLOR_CONTRAST"
|
||||
};
|
||||
|
||||
private static readonly string[] s_EdgeKeywords =
|
||||
{
|
||||
"",
|
||||
"EDGE_PLAIN",
|
||||
"EDGE_SHINY"
|
||||
};
|
||||
|
||||
private static readonly string[] s_EdgeColorKeywords =
|
||||
{
|
||||
"",
|
||||
"EDGE_COLOR_MULTIPLY",
|
||||
"EDGE_COLOR_ADDITIVE",
|
||||
"EDGE_COLOR_SUBTRACTIVE",
|
||||
"EDGE_COLOR_REPLACE",
|
||||
"EDGE_COLOR_MULTIPLY_LUMINANCE",
|
||||
"EDGE_COLOR_MULTIPLY_ADDITIVE",
|
||||
"EDGE_COLOR_HSV_MODIFIER",
|
||||
"EDGE_COLOR_CONTRAST"
|
||||
};
|
||||
|
||||
private static readonly Vector2[][] s_ShadowVectors = new[]
|
||||
{
|
||||
Array.Empty<Vector2>(), // None
|
||||
@@ -142,6 +172,7 @@ namespace Coffee.UIEffects
|
||||
|
||||
public SamplingFilter samplingFilter = SamplingFilter.None;
|
||||
public float samplingIntensity = 0.5f;
|
||||
public float samplingWidth;
|
||||
|
||||
public TransitionFilter transitionFilter = TransitionFilter.None;
|
||||
public float transitionRate = 0.5f;
|
||||
@@ -153,9 +184,12 @@ namespace Coffee.UIEffects
|
||||
public bool transitionKeepAspectRatio = true;
|
||||
public float transitionWidth = 0.2f;
|
||||
public float transitionSoftness = 0.2f;
|
||||
public MinMax01 transitionRange = new MinMax01(0, 1);
|
||||
public ColorFilter transitionColorFilter = ColorFilter.MultiplyAdditive;
|
||||
public Color transitionColor = new Color(0f, 0.5f, 1.0f, 1.0f);
|
||||
public bool transitionColorGlow;
|
||||
public bool transitionPatternReverse;
|
||||
public float transitionAutoPlaySpeed;
|
||||
|
||||
public TargetMode targetMode = TargetMode.None;
|
||||
public Color targetColor = Color.white;
|
||||
@@ -175,6 +209,14 @@ namespace Coffee.UIEffects
|
||||
public Color shadowColor;
|
||||
public bool shadowColorGlow;
|
||||
|
||||
public EdgeMode edgeMode;
|
||||
public float edgeWidth;
|
||||
public ColorFilter edgeColorFilter;
|
||||
public Color edgeColor;
|
||||
public float edgeShinyWidth;
|
||||
public float edgeShinyAutoPlaySpeed;
|
||||
public PatternArea patternArea;
|
||||
|
||||
public GradationMode gradationMode;
|
||||
public Color gradationColor1;
|
||||
public Color gradationColor2;
|
||||
@@ -184,16 +226,14 @@ namespace Coffee.UIEffects
|
||||
public float gradationRotation;
|
||||
private List<float> _keyTimes;
|
||||
|
||||
public bool allowToModifyMeshShape;
|
||||
|
||||
|
||||
public bool willModifyMaterial => samplingFilter != SamplingFilter.None
|
||||
|| transitionFilter != TransitionFilter.None
|
||||
|| toneFilter != ToneFilter.None
|
||||
|| colorFilter != ColorFilter.None
|
||||
|| srcBlendMode != BlendMode.One
|
||||
|| dstBlendMode != BlendMode.OneMinusSrcAlpha
|
||||
|| shadowMode != ShadowMode.None;
|
||||
|| shadowMode != ShadowMode.None
|
||||
|| edgeMode != EdgeMode.None;
|
||||
|
||||
public void Reset()
|
||||
{
|
||||
@@ -214,6 +254,7 @@ namespace Coffee.UIEffects
|
||||
|
||||
samplingFilter = preset.samplingFilter;
|
||||
samplingIntensity = preset.samplingIntensity;
|
||||
samplingWidth = preset.samplingWidth;
|
||||
|
||||
transitionFilter = preset.transitionFilter;
|
||||
transitionRate = preset.transitionRate;
|
||||
@@ -225,9 +266,12 @@ namespace Coffee.UIEffects
|
||||
transitionRotation = preset.transitionRotation;
|
||||
transitionWidth = preset.transitionWidth;
|
||||
transitionSoftness = preset.transitionSoftness;
|
||||
transitionRange = preset.transitionRange;
|
||||
transitionColor = preset.transitionColor;
|
||||
transitionColorFilter = preset.transitionColorFilter;
|
||||
transitionColorGlow = preset.transitionColorGlow;
|
||||
transitionPatternReverse = preset.transitionPatternReverse;
|
||||
transitionAutoPlaySpeed = preset.transitionAutoPlaySpeed;
|
||||
|
||||
targetMode = preset.targetMode;
|
||||
targetColor = preset.targetColor;
|
||||
@@ -247,6 +291,14 @@ namespace Coffee.UIEffects
|
||||
shadowColor = preset.shadowColor;
|
||||
shadowColorGlow = preset.shadowColorGlow;
|
||||
|
||||
edgeMode = preset.edgeMode;
|
||||
edgeWidth = preset.edgeWidth;
|
||||
edgeColorFilter = preset.edgeColorFilter;
|
||||
edgeColor = preset.edgeColor;
|
||||
edgeShinyAutoPlaySpeed = preset.edgeShinyAutoPlaySpeed;
|
||||
edgeShinyWidth = preset.edgeShinyWidth;
|
||||
patternArea = preset.patternArea;
|
||||
|
||||
gradationMode = preset.gradationMode;
|
||||
gradationColor1 = preset.gradationColor1;
|
||||
gradationColor2 = preset.gradationColor2;
|
||||
@@ -254,8 +306,6 @@ namespace Coffee.UIEffects
|
||||
gradationOffset = preset.gradationOffset;
|
||||
gradationScale = preset.gradationScale;
|
||||
gradationRotation = preset.gradationRotation;
|
||||
|
||||
allowToModifyMeshShape = preset.allowToModifyMeshShape;
|
||||
}
|
||||
|
||||
public void SetGradationDirty()
|
||||
@@ -280,6 +330,7 @@ namespace Coffee.UIEffects
|
||||
material.SetInt(s_ColorGlow, colorGlow ? 1 : 0);
|
||||
|
||||
material.SetFloat(s_SamplingIntensity, Mathf.Clamp01(samplingIntensity));
|
||||
material.SetFloat(s_SamplingWidth, samplingWidth);
|
||||
material.SetFloat(s_SamplingScale, actualSamplingScale);
|
||||
|
||||
material.SetFloat(s_TransitionRate, Mathf.Clamp01(transitionRate));
|
||||
@@ -290,9 +341,12 @@ namespace Coffee.UIEffects
|
||||
transitionTexOffset.x, transitionTexOffset.y));
|
||||
material.SetFloat(s_TransitionWidth, Mathf.Clamp01(transitionWidth));
|
||||
material.SetFloat(s_TransitionSoftness, Mathf.Clamp01(transitionSoftness));
|
||||
material.SetVector(s_TransitionRange, new Vector2(transitionRange.min, transitionRange.max));
|
||||
material.SetInt(s_TransitionColorFilter, (int)transitionColorFilter);
|
||||
material.SetColor(s_TransitionColor, transitionColor);
|
||||
material.SetInt(s_TransitionColorGlow, transitionColorGlow ? 1 : 0);
|
||||
material.SetInt(s_TransitionPatternReverse, transitionPatternReverse ? 1 : 0);
|
||||
material.SetFloat(s_TransitionAutoPlaySpeed, transitionAutoPlaySpeed);
|
||||
|
||||
material.SetColor(s_TargetColor, targetColor);
|
||||
material.SetFloat(s_TargetRange, Mathf.Clamp01(targetRange));
|
||||
@@ -313,6 +367,12 @@ namespace Coffee.UIEffects
|
||||
material.SetColor(s_ShadowColor, shadowColor);
|
||||
material.SetInt(s_ShadowColorGlow, shadowColorGlow ? 1 : 0);
|
||||
|
||||
material.SetFloat(s_EdgeWidth, Mathf.Clamp01(edgeWidth));
|
||||
material.SetColor(s_EdgeColor, edgeColor);
|
||||
material.SetFloat(s_EdgeShinyWidth, Mathf.Clamp01(edgeShinyWidth));
|
||||
material.SetFloat(s_EdgeShinyAutoPlaySpeed, edgeShinyAutoPlaySpeed);
|
||||
material.SetInt(s_PatternArea, edgeMode != EdgeMode.None ? (int)patternArea : 0);
|
||||
|
||||
SetKeyword(material, s_ToneKeywords, (int)toneFilter);
|
||||
SetKeyword(material, s_ColorKeywords, (int)colorFilter);
|
||||
SetKeyword(material, s_SamplingKeywords, (int)samplingFilter);
|
||||
@@ -324,11 +384,7 @@ namespace Coffee.UIEffects
|
||||
case TransitionFilter.Cutoff:
|
||||
SetKeyword(material, s_TransitionColorKeywords, (int)ColorFilter.None);
|
||||
break;
|
||||
case TransitionFilter.Dissolve:
|
||||
case TransitionFilter.Shiny:
|
||||
case TransitionFilter.Mask:
|
||||
case TransitionFilter.Melt:
|
||||
case TransitionFilter.Burn:
|
||||
default:
|
||||
SetKeyword(material, s_TransitionColorKeywords, (int)transitionColorFilter);
|
||||
break;
|
||||
}
|
||||
@@ -343,6 +399,19 @@ namespace Coffee.UIEffects
|
||||
break;
|
||||
}
|
||||
|
||||
SetKeyword(material, s_EdgeKeywords, (int)edgeMode);
|
||||
|
||||
switch (edgeMode)
|
||||
{
|
||||
case EdgeMode.None:
|
||||
SetKeyword(material, s_EdgeColorKeywords, (int)ColorFilter.None);
|
||||
break;
|
||||
default:
|
||||
SetKeyword(material, s_EdgeColorKeywords, (int)edgeColorFilter);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
SetKeyword(material, s_TargetKeywords, (int)targetMode);
|
||||
|
||||
Profiler.EndSample();
|
||||
@@ -363,14 +432,14 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
}
|
||||
|
||||
public void ModifyMesh(Graphic graphic, RectTransform transitionRoot, VertexHelper vh)
|
||||
public void ModifyMesh(Graphic graphic, RectTransform transitionRoot, VertexHelper vh, bool canModifyShape)
|
||||
{
|
||||
var processor = ContextProcessor.FindProcessor(graphic);
|
||||
var isText = processor.IsText(graphic);
|
||||
processor.OnPreModifyMesh(graphic);
|
||||
var effectProxy = GraphicProxy.Find(graphic);
|
||||
var isText = effectProxy.IsText(graphic);
|
||||
effectProxy.OnPreModifyMesh(graphic);
|
||||
|
||||
var verts = s_WorkingVertices;
|
||||
var expandSize = GetExpandSize();
|
||||
var expandSize = GetExpandSize(canModifyShape);
|
||||
var count = vh.currentIndexCount;
|
||||
|
||||
// Get the rectangle to calculate the normalized position.
|
||||
@@ -427,7 +496,7 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
|
||||
// Apply gradation.
|
||||
ApplyGradation(verts, transitionRoot.rect, rectMatrix);
|
||||
ApplyGradation(verts, transitionRoot.rect, rectMatrix, canModifyShape);
|
||||
|
||||
// Apply shadow.
|
||||
ApplyShadow(transitionRoot, verts);
|
||||
@@ -436,8 +505,10 @@ namespace Coffee.UIEffects
|
||||
vh.AddUIVertexTriangleStream(verts);
|
||||
}
|
||||
|
||||
private void ApplyGradation(List<UIVertex> verts, Rect rect, Matrix4x4 m)
|
||||
private void ApplyGradation(List<UIVertex> verts, Rect rect, Matrix4x4 m, bool canModifyShape)
|
||||
{
|
||||
if (gradationMode == GradationMode.None) return;
|
||||
|
||||
var a = gradationColor1;
|
||||
var b = gradationColor2;
|
||||
var offset = gradationOffset;
|
||||
@@ -465,6 +536,7 @@ namespace Coffee.UIEffects
|
||||
GradientUtil.DoRadialGradient(verts, a, b, offset, scale, rect, m, 12);
|
||||
break;
|
||||
case GradationMode.Angle:
|
||||
rect = GradientUtil.RotateRectAsNormalized(rect, rot);
|
||||
m = Matrix4x4.Rotate(Quaternion.Euler(0, 0, rot)) * m;
|
||||
GradientUtil.DoHorizontalGradient(verts, a, b, offset, scale, rect, m);
|
||||
break;
|
||||
@@ -476,7 +548,7 @@ namespace Coffee.UIEffects
|
||||
GradientUtil.GetKeyTimes(grad, _keyTimes);
|
||||
}
|
||||
|
||||
if (allowToModifyMeshShape)
|
||||
if (canModifyShape)
|
||||
{
|
||||
var splitTimes = InternalListPool<float>.Rent();
|
||||
GradientUtil.SplitKeyTimes(_keyTimes, splitTimes, offset, scale);
|
||||
@@ -498,7 +570,7 @@ namespace Coffee.UIEffects
|
||||
GradientUtil.GetKeyTimes(grad, _keyTimes);
|
||||
}
|
||||
|
||||
if (allowToModifyMeshShape)
|
||||
if (canModifyShape)
|
||||
{
|
||||
var splitTimes = InternalListPool<float>.Rent();
|
||||
GradientUtil.SplitKeyTimes(_keyTimes, splitTimes, offset, scale);
|
||||
@@ -520,8 +592,9 @@ namespace Coffee.UIEffects
|
||||
GradientUtil.GetKeyTimes(grad, _keyTimes);
|
||||
}
|
||||
|
||||
rect = GradientUtil.RotateRectAsNormalized(rect, rot);
|
||||
m = Matrix4x4.Rotate(Quaternion.Euler(0, 0, rot)) * m;
|
||||
if (allowToModifyMeshShape)
|
||||
if (canModifyShape)
|
||||
{
|
||||
var splitTimes = InternalListPool<float>.Rent();
|
||||
GradientUtil.SplitKeyTimes(_keyTimes, splitTimes, offset, scale);
|
||||
@@ -555,9 +628,9 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
}
|
||||
|
||||
private Vector2 GetExpandSize()
|
||||
private Vector2 GetExpandSize(bool canModifyShape)
|
||||
{
|
||||
if (!allowToModifyMeshShape) return Vector2.zero;
|
||||
if (!canModifyShape) return Vector2.zero;
|
||||
|
||||
var expandSize = Vector2.zero;
|
||||
switch (samplingFilter)
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
@@ -20,6 +19,10 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
internal List<UIEffect> m_RuntimePresets = new List<UIEffect>();
|
||||
|
||||
[Header("Editor")]
|
||||
[Tooltip("Use HDR color pickers on color fields.")]
|
||||
[SerializeField] private bool m_UseHDRColorPicker = true;
|
||||
|
||||
[HideInInspector]
|
||||
[SerializeField]
|
||||
internal ShaderVariantCollection m_ShaderVariantCollection;
|
||||
@@ -38,6 +41,12 @@ namespace Coffee.UIEffects
|
||||
set => instance.m_TransformSensitivity = value;
|
||||
}
|
||||
|
||||
public static bool useHdrColorPicker
|
||||
{
|
||||
get => instance.m_UseHDRColorPicker;
|
||||
set => instance.m_UseHDRColorPicker = value;
|
||||
}
|
||||
|
||||
public static void RegisterRuntimePreset(UIEffect effect)
|
||||
{
|
||||
// Already registered.
|
||||
|
||||
@@ -12,6 +12,9 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
protected float m_SamplingScale = 1f;
|
||||
|
||||
[SerializeField]
|
||||
protected bool m_AllowToModifyMeshShape = true;
|
||||
|
||||
private UIEffect _currentTarget;
|
||||
private Matrix4x4 _prevTransformHash;
|
||||
|
||||
@@ -47,13 +50,13 @@ namespace Coffee.UIEffects
|
||||
value = Mathf.Clamp(value, 0.01f, 100);
|
||||
if (Mathf.Approximately(m_SamplingScale, value)) return;
|
||||
m_SamplingScale = value;
|
||||
ApplyContextToMaterial();
|
||||
SetMaterialDirty();
|
||||
}
|
||||
}
|
||||
|
||||
public override float actualSamplingScale => target && target.samplingFilter != SamplingFilter.None
|
||||
? Mathf.Clamp(m_SamplingScale, 0.01f, 100)
|
||||
: 1;
|
||||
public override float actualSamplingScale => Mathf.Clamp(m_SamplingScale, 0.01f, 100);
|
||||
|
||||
public override bool canModifyShape => m_AllowToModifyMeshShape;
|
||||
|
||||
public override uint effectId => target ? target.effectId : 0;
|
||||
public override UIEffectContext context => target && target.isActiveAndEnabled ? target.context : null;
|
||||
|
||||
@@ -81,6 +81,10 @@ namespace Coffee.UIEffects
|
||||
[SerializeField]
|
||||
private PlayOnEnable m_PlayOnEnable = PlayOnEnable.Forward;
|
||||
|
||||
[Tooltip("Reset the tweening time when the component is enabled.")]
|
||||
[SerializeField]
|
||||
private bool m_ResetTimeOnEnable = true;
|
||||
|
||||
[Tooltip("The wrap mode of the tween.\n" +
|
||||
" Once: Clamp the tween value (not loop).\n" +
|
||||
" Loop: Loop the tween value.\n" +
|
||||
@@ -220,11 +224,13 @@ namespace Coffee.UIEffects
|
||||
set => m_PlayOnEnable = value;
|
||||
}
|
||||
|
||||
[Obsolete("UIEffectTweener.restartOnEnable has been deprecated. Use UIEffectTweener.playOnEnable instead")]
|
||||
public bool restartOnEnable
|
||||
/// <summary>
|
||||
/// Reset the tweening time when the component is enabled..
|
||||
/// </summary>
|
||||
public bool resetTimeOnEnable
|
||||
{
|
||||
get => m_PlayOnEnable != PlayOnEnable.Forward;
|
||||
set => m_PlayOnEnable = value ? PlayOnEnable.None : PlayOnEnable.Forward;
|
||||
get => m_ResetTimeOnEnable;
|
||||
set => m_ResetTimeOnEnable = value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -303,13 +309,13 @@ namespace Coffee.UIEffects
|
||||
switch (playOnEnable)
|
||||
{
|
||||
case PlayOnEnable.KeepDirection:
|
||||
Play();
|
||||
Play(resetTimeOnEnable);
|
||||
break;
|
||||
case PlayOnEnable.Forward:
|
||||
PlayForward();
|
||||
PlayForward(resetTimeOnEnable);
|
||||
break;
|
||||
case PlayOnEnable.Reverse:
|
||||
PlayReverse();
|
||||
PlayReverse(resetTimeOnEnable);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -339,6 +345,11 @@ namespace Coffee.UIEffects
|
||||
ResetTime();
|
||||
}
|
||||
|
||||
Play();
|
||||
}
|
||||
|
||||
public void Play()
|
||||
{
|
||||
_isPaused = false;
|
||||
|
||||
if (!isTweening)
|
||||
@@ -347,15 +358,14 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
}
|
||||
|
||||
public void Play()
|
||||
public void PlayForward(bool resetTime)
|
||||
{
|
||||
ResetTime();
|
||||
_isPaused = false;
|
||||
|
||||
if (!isTweening)
|
||||
if (resetTime)
|
||||
{
|
||||
m_OnComplete.Invoke();
|
||||
ResetTime();
|
||||
}
|
||||
|
||||
PlayForward();
|
||||
}
|
||||
|
||||
public void PlayForward()
|
||||
@@ -369,6 +379,16 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
}
|
||||
|
||||
public void PlayReverse(bool resetTime)
|
||||
{
|
||||
if (resetTime)
|
||||
{
|
||||
ResetTime();
|
||||
}
|
||||
|
||||
PlayReverse();
|
||||
}
|
||||
|
||||
public void PlayReverse()
|
||||
{
|
||||
direction = Direction.Reverse;
|
||||
|
||||
@@ -1,166 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
#if TMP_ENABLE
|
||||
using TMPro;
|
||||
#endif
|
||||
|
||||
|
||||
namespace Coffee.UIEffects
|
||||
{
|
||||
public class ContextProcessor
|
||||
{
|
||||
private static readonly List<ContextProcessor> s_Processors = new List<ContextProcessor>()
|
||||
{
|
||||
new ContextProcessor(),
|
||||
#if TMP_ENABLE
|
||||
new TmpContextProcessor(),
|
||||
#endif
|
||||
};
|
||||
|
||||
public static void RegisterProcessor(ContextProcessor processor)
|
||||
{
|
||||
// Register only once.
|
||||
foreach (var p in s_Processors)
|
||||
{
|
||||
if (p.GetType() == processor.GetType()) return;
|
||||
}
|
||||
|
||||
s_Processors.Add(processor);
|
||||
}
|
||||
|
||||
public static ContextProcessor FindProcessor(Graphic graphic)
|
||||
{
|
||||
for (var i = s_Processors.Count - 1; i >= 0; i--)
|
||||
{
|
||||
var p = s_Processors[i];
|
||||
if (p.IsValid(graphic)) return p;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Check if the graphic is valid for this processor.
|
||||
/// </summary>
|
||||
protected virtual bool IsValid(Graphic graphic)
|
||||
{
|
||||
return graphic;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Check if the graphic is a text.
|
||||
/// </summary>
|
||||
public virtual bool IsText(Graphic graphic)
|
||||
{
|
||||
return graphic is Text;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called before modifying the mesh.
|
||||
/// </summary>
|
||||
public virtual void OnPreModifyMesh(Graphic graphic)
|
||||
{
|
||||
UIVertexUtil.onLerpVertex = s_OnLerpVertex;
|
||||
ShadowUtil.onMarkAsShadow = s_OnMarkAsShadow;
|
||||
UIEffectContext.onModifyVertex = s_OnModifyVertex;
|
||||
}
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex, UIVertex, float, UIVertex> s_OnLerpVertex =
|
||||
null;
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex> s_OnMarkAsShadow =
|
||||
vt =>
|
||||
{
|
||||
vt.uv0.z -= 8;
|
||||
vt.uv0.w -= 8;
|
||||
return vt;
|
||||
};
|
||||
|
||||
private static readonly Func<UIVertex, Rect, float, float, UIVertex> s_OnModifyVertex =
|
||||
(vt, uvMask, normalizedX, normalizedY) =>
|
||||
{
|
||||
vt.uv0.z = normalizedX;
|
||||
vt.uv0.w = normalizedY;
|
||||
vt.uv1 = new Vector4(uvMask.xMin, uvMask.yMin, uvMask.xMax, uvMask.yMax);
|
||||
return vt;
|
||||
};
|
||||
}
|
||||
|
||||
#if TMP_ENABLE
|
||||
internal class TmpContextProcessor : ContextProcessor
|
||||
{
|
||||
protected override bool IsValid(Graphic graphic)
|
||||
{
|
||||
if (!graphic) return false;
|
||||
if (graphic is TextMeshProUGUI) return true;
|
||||
if (graphic is TMP_SubMeshUI sub)
|
||||
{
|
||||
// If TMP_SubMeshUI is used for text
|
||||
return !sub.spriteAsset
|
||||
|| sub.sharedMaterial != sub.spriteAsset.material;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Check if the graphic is a text.
|
||||
/// </summary>
|
||||
public override bool IsText(Graphic graphic)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called before modifying the mesh.
|
||||
/// </summary>
|
||||
public override void OnPreModifyMesh(Graphic graphic)
|
||||
{
|
||||
UIVertexUtil.onLerpVertex = s_OnLerpVertex;
|
||||
ShadowUtil.onMarkAsShadow = s_OnMarkAsShadow;
|
||||
UIEffectContext.onModifyVertex = s_OnModifyVertex;
|
||||
}
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex, UIVertex, float, UIVertex> s_OnLerpVertex =
|
||||
#if UNITY_2023_2_OR_NEWER
|
||||
null;
|
||||
#else
|
||||
(vt, a, b, t) =>
|
||||
{
|
||||
// TMP 3.x uses packed UV
|
||||
vt.uv1.x = PackUV(Vector2.Lerp(UnpackUV(a.uv1.x), UnpackUV(b.uv1.x), t));
|
||||
return vt;
|
||||
|
||||
static float PackUV(Vector2 input)
|
||||
{
|
||||
return (int)(input.x * 511) * 4096 + (int)(input.y * 511);
|
||||
}
|
||||
|
||||
static Vector2 UnpackUV(float input)
|
||||
{
|
||||
return new Vector2(input / 4096 / 511, input % 4096 / 511);
|
||||
}
|
||||
};
|
||||
#endif
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex> s_OnMarkAsShadow =
|
||||
vt =>
|
||||
{
|
||||
vt.uv1.z -= 8;
|
||||
vt.uv1.w -= 8;
|
||||
return vt;
|
||||
};
|
||||
|
||||
private static readonly Func<UIVertex, Rect, float, float, UIVertex> s_OnModifyVertex =
|
||||
(vt, uvMask, normalizedX, normalizedY) =>
|
||||
{
|
||||
vt.uv1.z = normalizedX;
|
||||
vt.uv1.w = normalizedY;
|
||||
vt.uv2 = new Vector4(uvMask.xMin, uvMask.yMin, uvMask.xMax, uvMask.yMax);
|
||||
return vt;
|
||||
};
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@@ -47,6 +47,34 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
}
|
||||
|
||||
public static void DoHorizontalGradientFixed(List<UIVertex> verts, Gradient gradient, float offset, float scale,
|
||||
Rect rect, Matrix4x4 m)
|
||||
{
|
||||
var count = verts.Count;
|
||||
for (var i = 0; i < count; i += 3)
|
||||
{
|
||||
var vt0 = verts[i + 0];
|
||||
var vt1 = verts[i + 1];
|
||||
var vt2 = verts[i + 2];
|
||||
var center = m.MultiplyPoint3x4((vt0.position + vt1.position + vt2.position) / 3).x;
|
||||
vt0.color *= Evaluate(gradient, rect, center, offset, scale);
|
||||
vt1.color *= Evaluate(gradient, rect, center, offset, scale);
|
||||
vt2.color *= Evaluate(gradient, rect, center, offset, scale);
|
||||
verts[i + 0] = vt0;
|
||||
verts[i + 1] = vt1;
|
||||
verts[i + 2] = vt2;
|
||||
}
|
||||
|
||||
return;
|
||||
|
||||
static Color Evaluate(Gradient gradient, Rect rect, float t, float offset, float scale)
|
||||
{
|
||||
t = Mathf.InverseLerp(rect.xMin, rect.xMax, t); // 0-1
|
||||
t = Mathf.Repeat((t - offset * scale - (1 - scale) / 2) / scale, 1); // Revert
|
||||
return gradient.Evaluate(t);
|
||||
}
|
||||
}
|
||||
|
||||
public static void DoHorizontalGradient(List<UIVertex> verts, Gradient gradient, float offset, float scale,
|
||||
Rect rect, Matrix4x4 m)
|
||||
{
|
||||
@@ -219,7 +247,14 @@ namespace Coffee.UIEffects
|
||||
float offset, float scale, Rect rect, Matrix4x4 m)
|
||||
{
|
||||
UIVertexUtil.SplitAngle(verts, splitTimes, rect, m);
|
||||
DoHorizontalGradient(verts, gradient, offset, scale, rect, m);
|
||||
if (gradient.mode == GradientMode.Fixed)
|
||||
{
|
||||
DoHorizontalGradientFixed(verts, gradient, offset, scale, rect, m);
|
||||
}
|
||||
else
|
||||
{
|
||||
DoHorizontalGradient(verts, gradient, offset, scale, rect, m);
|
||||
}
|
||||
}
|
||||
|
||||
public static void GetKeyTimes(Gradient gradient, List<float> results)
|
||||
@@ -283,9 +318,9 @@ namespace Coffee.UIEffects
|
||||
time -= scale;
|
||||
}
|
||||
|
||||
while (time < 1f)
|
||||
while (time <= 1f)
|
||||
{
|
||||
if (0 < time && !Contains(results, time))
|
||||
if (0 <= time && !Contains(results, time))
|
||||
{
|
||||
results.Add(time);
|
||||
}
|
||||
@@ -304,5 +339,41 @@ namespace Coffee.UIEffects
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public static Rect RotateRectAsNormalized(Rect rect, float rot)
|
||||
{
|
||||
var rad = -rot * Mathf.Deg2Rad;
|
||||
var cos = Mathf.Cos(rad);
|
||||
var sin = Mathf.Sin(rad);
|
||||
var dir = new Vector2(cos, sin);
|
||||
var center = rect.center;
|
||||
|
||||
if (Mathf.Abs(dir.x) < 0.0001f)
|
||||
{
|
||||
rect.width = rect.height;
|
||||
}
|
||||
else if (Mathf.Abs(dir.y) < 0.0001f)
|
||||
{
|
||||
rect.height = rect.width;
|
||||
}
|
||||
else
|
||||
{
|
||||
var d0 = GetPointToLineDistance(new Vector2(rect.xMin, rect.yMax), center, dir, out var p0);
|
||||
var d1 = GetPointToLineDistance(new Vector2(rect.xMin, rect.yMin), center, dir, out var p1);
|
||||
var closest = d0 < d1 ? p0 : p1;
|
||||
rect.width = rect.height = Vector2.Distance(center, closest) * 2;
|
||||
}
|
||||
|
||||
rect.center = new Vector2(Vector2.Dot(center, dir), 0);
|
||||
return rect;
|
||||
}
|
||||
|
||||
private static float GetPointToLineDistance(Vector2 point, Vector2 origin, Vector2 dir, out Vector2 closest)
|
||||
{
|
||||
var dirNormalized = dir.normalized;
|
||||
var time = Vector2.Dot(point - origin, dirNormalized);
|
||||
closest = origin + time * dirNormalized;
|
||||
return Vector2.Distance(point, closest);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,95 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
namespace Coffee.UIEffects
|
||||
{
|
||||
public class GraphicProxy
|
||||
{
|
||||
private static readonly List<GraphicProxy> s_Proxies = new List<GraphicProxy>()
|
||||
{
|
||||
new GraphicProxy()
|
||||
};
|
||||
|
||||
public static void Register(GraphicProxy proxy)
|
||||
{
|
||||
// Register only once.
|
||||
foreach (var p in s_Proxies)
|
||||
{
|
||||
if (p.GetType() == proxy.GetType()) return;
|
||||
}
|
||||
|
||||
s_Proxies.Add(proxy);
|
||||
}
|
||||
|
||||
public static GraphicProxy Find(Graphic graphic)
|
||||
{
|
||||
if (!graphic) return null;
|
||||
|
||||
for (var i = s_Proxies.Count - 1; i >= 0; i--)
|
||||
{
|
||||
var p = s_Proxies[i];
|
||||
if (p.IsValid(graphic)) return p;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Check if the graphic is valid for this proxy.
|
||||
/// </summary>
|
||||
protected virtual bool IsValid(Graphic graphic)
|
||||
{
|
||||
return graphic;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Check if the graphic is a text.
|
||||
/// </summary>
|
||||
public virtual bool IsText(Graphic graphic)
|
||||
{
|
||||
return graphic is Text;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called before modifying the mesh.
|
||||
/// </summary>
|
||||
public virtual void OnPreModifyMesh(Graphic graphic)
|
||||
{
|
||||
UIVertexUtil.onLerpVertex = s_OnLerpVertex;
|
||||
ShadowUtil.onMarkAsShadow = s_OnMarkAsShadow;
|
||||
UIEffectContext.onModifyVertex = s_OnModifyVertex;
|
||||
|
||||
var canvas = graphic.canvas;
|
||||
if (canvas)
|
||||
{
|
||||
canvas.additionalShaderChannels |= AdditionalCanvasShaderChannels.TexCoord1;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void SetVerticesDirty(Graphic graphic)
|
||||
{
|
||||
}
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex, UIVertex, float, UIVertex> s_OnLerpVertex =
|
||||
null;
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex> s_OnMarkAsShadow =
|
||||
vt =>
|
||||
{
|
||||
vt.uv0.z -= 8;
|
||||
vt.uv0.w -= 8;
|
||||
return vt;
|
||||
};
|
||||
|
||||
private static readonly Func<UIVertex, Rect, float, float, UIVertex> s_OnModifyVertex =
|
||||
(vt, uvMask, normalizedX, normalizedY) =>
|
||||
{
|
||||
vt.uv0.z = normalizedX;
|
||||
vt.uv0.w = normalizedY;
|
||||
vt.uv1 = new Vector4(uvMask.xMin, uvMask.yMin, uvMask.xMax, uvMask.yMax);
|
||||
return vt;
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c6f31259f929a47bf9cbd8f1b921327e
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -21,8 +21,8 @@ namespace Coffee.UIEffects
|
||||
for (var i = 0; i < iteration; i++)
|
||||
{
|
||||
d += distance / (i + 1);
|
||||
a *= 0.75f;
|
||||
ApplyShadow(verts, vectors, ref start, ref end, d, a);
|
||||
a *= 0.75f;
|
||||
}
|
||||
|
||||
// Mark as shadow vertices.
|
||||
|
||||
@@ -0,0 +1,254 @@
|
||||
#if TMP_ENABLE
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Coffee.UIEffectInternal;
|
||||
using UnityEditor;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
using TMPro;
|
||||
|
||||
namespace Coffee.UIEffects
|
||||
{
|
||||
internal class TmpProxy : GraphicProxy
|
||||
{
|
||||
/// <summary>
|
||||
/// Check if the graphic is valid for this proxy.
|
||||
/// </summary>
|
||||
protected override bool IsValid(Graphic graphic)
|
||||
{
|
||||
if (!graphic) return false;
|
||||
if (graphic is TextMeshProUGUI) return true;
|
||||
if (graphic is TMP_SubMeshUI sub)
|
||||
{
|
||||
// If TMP_SubMeshUI is used for text
|
||||
return !sub.spriteAsset
|
||||
|| sub.sharedMaterial != sub.spriteAsset.material;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Check if the graphic is a text.
|
||||
/// </summary>
|
||||
public override bool IsText(Graphic graphic)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Called before modifying the mesh.
|
||||
/// </summary>
|
||||
public override void OnPreModifyMesh(Graphic graphic)
|
||||
{
|
||||
UIVertexUtil.onLerpVertex = s_OnLerpVertex;
|
||||
ShadowUtil.onMarkAsShadow = s_OnMarkAsShadow;
|
||||
UIEffectContext.onModifyVertex = s_OnModifyVertex;
|
||||
|
||||
var canvas = graphic.canvas;
|
||||
if (canvas)
|
||||
{
|
||||
canvas.additionalShaderChannels |= AdditionalCanvasShaderChannels.TexCoord2;
|
||||
}
|
||||
}
|
||||
|
||||
public override void SetVerticesDirty(Graphic graphic)
|
||||
{
|
||||
if (graphic is TextMeshProUGUI textMeshProUGUI)
|
||||
{
|
||||
s_ChangedInstances.Add(textMeshProUGUI);
|
||||
}
|
||||
}
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex, UIVertex, float, UIVertex> s_OnLerpVertex =
|
||||
#if UNITY_2023_2_OR_NEWER
|
||||
null;
|
||||
#else
|
||||
(vt, a, b, t) =>
|
||||
{
|
||||
// TMP 3.x uses packed UV
|
||||
vt.uv1.x = PackUV(Vector2.Lerp(UnpackUV(a.uv1.x), UnpackUV(b.uv1.x), t));
|
||||
return vt;
|
||||
|
||||
static float PackUV(Vector2 input)
|
||||
{
|
||||
return (int)(input.x * 511) * 4096 + (int)(input.y * 511);
|
||||
}
|
||||
|
||||
static Vector2 UnpackUV(float input)
|
||||
{
|
||||
return new Vector2(input / 4096 / 511, input % 4096 / 511);
|
||||
}
|
||||
};
|
||||
#endif
|
||||
|
||||
private static readonly Func<UIVertex, UIVertex> s_OnMarkAsShadow =
|
||||
vt =>
|
||||
{
|
||||
vt.uv1.z -= 8;
|
||||
vt.uv1.w -= 8;
|
||||
return vt;
|
||||
};
|
||||
|
||||
private static readonly Func<UIVertex, Rect, float, float, UIVertex> s_OnModifyVertex =
|
||||
(vt, uvMask, normalizedX, normalizedY) =>
|
||||
{
|
||||
vt.uv1.z = normalizedX;
|
||||
vt.uv1.w = normalizedY;
|
||||
vt.uv2 = new Vector4(uvMask.xMin, uvMask.yMin, uvMask.xMax, uvMask.yMax);
|
||||
return vt;
|
||||
};
|
||||
|
||||
private static Mesh s_Mesh;
|
||||
private static readonly VertexHelper s_VertexHelper = new VertexHelper();
|
||||
private static readonly HashSet<TextMeshProUGUI> s_ChangedInstances = new HashSet<TextMeshProUGUI>();
|
||||
private static readonly HashSet<TextMeshProUGUI> s_RegisteredInstances = new HashSet<TextMeshProUGUI>();
|
||||
private static readonly Dictionary<int, float> s_SdfScaleCache = new Dictionary<int, float>();
|
||||
|
||||
#if UNITY_EDITOR
|
||||
[InitializeOnLoadMethod]
|
||||
#else
|
||||
[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.BeforeSceneLoad)]
|
||||
#endif
|
||||
private static void InitializeOnLoad()
|
||||
{
|
||||
Register(new TmpProxy());
|
||||
|
||||
// When the text is changed, add it to the changed list
|
||||
TMPro_EventManager.TEXT_CHANGED_EVENT.Add(obj =>
|
||||
{
|
||||
if (obj is TextMeshProUGUI textMeshProUGUI)
|
||||
{
|
||||
s_ChangedInstances.Add(textMeshProUGUI);
|
||||
}
|
||||
});
|
||||
|
||||
UIExtraCallbacks.onBeforeCanvasRebuild += () =>
|
||||
{
|
||||
// Check SDF scale (lossyScale.y) change
|
||||
var toRemove = InternalListPool<TextMeshProUGUI>.Rent();
|
||||
foreach (var textMeshProUGUI in s_RegisteredInstances)
|
||||
{
|
||||
if (textMeshProUGUI)
|
||||
{
|
||||
var id = textMeshProUGUI.GetHashCode();
|
||||
var lossyScaleY = textMeshProUGUI.transform.lossyScale.y;
|
||||
|
||||
// If the scale has changed, add to the changed list
|
||||
if (s_SdfScaleCache.TryGetValue(id, out var prev)
|
||||
&& !Mathf.Approximately(prev, lossyScaleY))
|
||||
{
|
||||
s_ChangedInstances.Add(textMeshProUGUI);
|
||||
}
|
||||
|
||||
// Update the scale cache
|
||||
s_SdfScaleCache[id] = textMeshProUGUI.transform.lossyScale.y;
|
||||
}
|
||||
// Remove destroyed objects later
|
||||
else if (!ReferenceEquals(textMeshProUGUI, null))
|
||||
{
|
||||
toRemove.Add(textMeshProUGUI);
|
||||
}
|
||||
}
|
||||
|
||||
// Remove destroyed objects
|
||||
foreach (var textMeshProUGUI in toRemove)
|
||||
{
|
||||
s_SdfScaleCache.Remove(textMeshProUGUI.GetHashCode());
|
||||
s_RegisteredInstances.Remove(textMeshProUGUI);
|
||||
}
|
||||
};
|
||||
|
||||
// Modify the changed TMP mesh
|
||||
UIExtraCallbacks.onAfterCanvasRebuild += () =>
|
||||
{
|
||||
foreach (var textMeshProUGUI in s_ChangedInstances)
|
||||
{
|
||||
if (!textMeshProUGUI || !textMeshProUGUI.isActiveAndEnabled) continue;
|
||||
ModifyMesh(textMeshProUGUI);
|
||||
}
|
||||
|
||||
s_ChangedInstances.Clear();
|
||||
};
|
||||
}
|
||||
|
||||
private static void ModifyMesh(TextMeshProUGUI textMeshProUGUI)
|
||||
{
|
||||
if (!textMeshProUGUI.TryGetComponent<UIEffectBase>(out var effect)) return;
|
||||
if (!effect || !effect.isActiveAndEnabled) return;
|
||||
|
||||
s_RegisteredInstances.Add(textMeshProUGUI);
|
||||
|
||||
if (!s_Mesh)
|
||||
{
|
||||
s_Mesh = new Mesh();
|
||||
s_Mesh.MarkDynamic();
|
||||
}
|
||||
|
||||
var target = effect is UIEffect uiEffect
|
||||
? uiEffect
|
||||
: effect is UIEffectReplica parentReplica
|
||||
? parentReplica.target
|
||||
: null;
|
||||
var subMeshes = InternalListPool<TMP_SubMeshUI>.Rent();
|
||||
var modifiers = InternalListPool<IMeshModifier>.Rent();
|
||||
textMeshProUGUI.GetComponentsInChildren(subMeshes, 1);
|
||||
for (var i = 0; i < textMeshProUGUI.textInfo.meshInfo.Length; i++)
|
||||
{
|
||||
var meshInfo = textMeshProUGUI.textInfo.meshInfo[i];
|
||||
s_VertexHelper.Clear();
|
||||
meshInfo.mesh.CopyTo(s_VertexHelper, meshInfo.vertexCount, meshInfo.vertexCount * 6 / 4);
|
||||
if (i == 0)
|
||||
{
|
||||
textMeshProUGUI.GetComponents(modifiers);
|
||||
foreach (var modifier in modifiers)
|
||||
{
|
||||
modifier.ModifyMesh(s_VertexHelper);
|
||||
}
|
||||
|
||||
s_VertexHelper.FillMesh(s_Mesh);
|
||||
textMeshProUGUI.canvasRenderer.SetMesh(s_Mesh);
|
||||
}
|
||||
else if (i - 1 < subMeshes.Count)
|
||||
{
|
||||
var subMeshUI = GetSubMeshUI(subMeshes, meshInfo.material, i - 1);
|
||||
if (!target || !subMeshUI) break;
|
||||
|
||||
var replica = subMeshUI.GetOrAddComponent<UIEffectReplica>();
|
||||
replica.target = target;
|
||||
|
||||
subMeshUI.GetComponents(modifiers);
|
||||
foreach (var modifier in modifiers)
|
||||
{
|
||||
modifier.ModifyMesh(s_VertexHelper);
|
||||
}
|
||||
|
||||
s_VertexHelper.FillMesh(s_Mesh);
|
||||
replica.ApplyContextToMaterial();
|
||||
subMeshUI.canvasRenderer.SetMesh(s_Mesh);
|
||||
}
|
||||
else
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
InternalListPool<IMeshModifier>.Return(ref modifiers);
|
||||
InternalListPool<TMP_SubMeshUI>.Return(ref subMeshes);
|
||||
s_Mesh.Clear(false);
|
||||
}
|
||||
|
||||
private static TMP_SubMeshUI GetSubMeshUI(List<TMP_SubMeshUI> subMeshes, Material material, int start)
|
||||
{
|
||||
var count = subMeshes.Count;
|
||||
for (var j = 0; j < count; j++)
|
||||
{
|
||||
var s = subMeshes[(j + start + count) % count];
|
||||
if (s.sharedMaterial == material) return s;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b2ffc93dc93f34027ad9bfdbfd61caae
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -31,6 +31,7 @@ RectTransform:
|
||||
- {fileID: 3451362614172717415}
|
||||
- {fileID: 5553160781519274839}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
@@ -70,6 +71,7 @@ RectTransform:
|
||||
m_ConstrainProportionsScale: 1
|
||||
m_Children: []
|
||||
m_Father: {fileID: 3775897659628443270}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
@@ -132,8 +134,11 @@ MonoBehaviour:
|
||||
m_ColorFilter: 0
|
||||
m_ColorIntensity: 1
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 0
|
||||
m_SamplingIntensity: 0.5
|
||||
m_SamplingWidth: 1
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 0
|
||||
m_TransitionRate: 0.5
|
||||
m_TransitionReverse: 0
|
||||
@@ -144,8 +149,14 @@ MonoBehaviour:
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.2
|
||||
m_TransitionSoftness: 0.2
|
||||
m_TransitionRange:
|
||||
m_Min: 0
|
||||
m_Max: 1
|
||||
m_TransitionColorFilter: 6
|
||||
m_TransitionColor: {r: 0, g: 0.5, b: 1, a: 1}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TransitionPatternReverse: 0
|
||||
m_TransitionAutoPlaySpeed: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TargetRange: 0.1
|
||||
@@ -157,8 +168,54 @@ MonoBehaviour:
|
||||
m_ShadowDistance: {x: 1, y: -1}
|
||||
m_ShadowIteration: 1
|
||||
m_ShadowFade: 0.9
|
||||
m_ShadowEffectOnOrigin: 0
|
||||
m_ShadowMirrorScale: 0.5
|
||||
m_ShadowBlurIntensity: 1
|
||||
m_ShadowColorFilter: 4
|
||||
m_ShadowColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_ShadowColorGlow: 0
|
||||
m_GradationMode: 0
|
||||
m_GradationColor1: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationColor2: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationGradient:
|
||||
serializedVersion: 2
|
||||
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||
ctime0: 0
|
||||
ctime1: 65535
|
||||
ctime2: 0
|
||||
ctime3: 0
|
||||
ctime4: 0
|
||||
ctime5: 0
|
||||
ctime6: 0
|
||||
ctime7: 0
|
||||
atime0: 0
|
||||
atime1: 65535
|
||||
atime2: 0
|
||||
atime3: 0
|
||||
atime4: 0
|
||||
atime5: 0
|
||||
atime6: 0
|
||||
atime7: 0
|
||||
m_Mode: 0
|
||||
m_NumColorKeys: 2
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: 0
|
||||
m_GradationScale: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
m_EdgeMode: 0
|
||||
m_EdgeWidth: 0.5
|
||||
m_EdgeColorFilter: 4
|
||||
m_EdgeColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_EdgeShinyWidth: 0.5
|
||||
m_EdgeShinyAutoPlaySpeed: 1
|
||||
m_PatternArea: 1
|
||||
--- !u!114 &5537784035359440648
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -200,9 +257,13 @@ MonoBehaviour:
|
||||
m_Delay: 0
|
||||
m_Duration: 1
|
||||
m_Interval: 0.5
|
||||
m_RestartOnEnable: 1
|
||||
m_PlayOnEnable: 1
|
||||
m_ResetTimeOnEnable: 1
|
||||
m_WrapMode: 3
|
||||
m_UpdateMode: 0
|
||||
m_OnComplete:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
--- !u!1 &6720690739041738997
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -216,7 +277,7 @@ GameObject:
|
||||
- component: {fileID: 603320123414190803}
|
||||
- component: {fileID: 3769011095332248825}
|
||||
m_Layer: 5
|
||||
m_Name: Label
|
||||
m_Name: TITLE
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
@@ -235,6 +296,7 @@ RectTransform:
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 3775897659628443270}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 0}
|
||||
|
||||
@@ -55,19 +55,21 @@ SubShader {
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct appdata_t
|
||||
{
|
||||
float4 vertex : POSITION;
|
||||
@@ -145,6 +147,7 @@ SubShader {
|
||||
v2f IN = _fragInput;
|
||||
float2 uvMove = uv - IN.texcoord0;
|
||||
fixed4 color = fixed4(IN.color.rgb, IN.color.a * tex2D(_MainTex, IN.texcoord0 + uvMove).a);
|
||||
color.rgb *= color.a;
|
||||
return color;
|
||||
}
|
||||
#define UIEFFECT_TEXTMESHPRO 1
|
||||
|
||||
@@ -54,19 +54,21 @@ SubShader{
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct appdata_t
|
||||
{
|
||||
float4 vertex : POSITION;
|
||||
@@ -151,6 +153,7 @@ SubShader{
|
||||
float2 uvMove = uv - IN.texcoord0;
|
||||
fixed4 color = tex2D(_MainTex, IN.texcoord0 + uvMove);
|
||||
color = fixed4 (tex2D(_FaceTex, IN.texcoord1).rgb * IN.color.rgb, IN.color.a * color.a);
|
||||
color.rgb *= color.a;
|
||||
return color;
|
||||
}
|
||||
#define UIEFFECT_TEXTMESHPRO 1
|
||||
|
||||
@@ -92,20 +92,23 @@ SubShader {
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro_Properties.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct vertex_t {
|
||||
UNITY_VERTEX_INPUT_INSTANCE_ID
|
||||
float4 vertex : POSITION;
|
||||
|
||||
@@ -124,20 +124,23 @@ SubShader {
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro_Properties.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct vertex_t
|
||||
{
|
||||
UNITY_VERTEX_INPUT_INSTANCE_ID
|
||||
|
||||
@@ -55,19 +55,20 @@ SubShader {
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct appdata_t {
|
||||
float4 vertex : POSITION;
|
||||
fixed4 color : COLOR;
|
||||
|
||||
@@ -54,19 +54,20 @@ SubShader{
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct appdata_t {
|
||||
float4 vertex : POSITION;
|
||||
fixed4 color : COLOR;
|
||||
|
||||
@@ -91,21 +91,23 @@ SubShader {
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro_Properties.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct vertex_t {
|
||||
UNITY_VERTEX_INPUT_INSTANCE_ID
|
||||
float4 vertex : POSITION;
|
||||
|
||||
@@ -124,21 +124,23 @@ SubShader {
|
||||
#pragma multi_compile __ UNITY_UI_CLIP_RECT
|
||||
#pragma multi_compile __ UNITY_UI_ALPHACLIP
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
#include "UnityCG.cginc"
|
||||
#include "UnityUI.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro_Properties.cginc"
|
||||
#include "Assets/TextMesh Pro/Shaders/TMPro.cginc"
|
||||
|
||||
// ==== UIEFFECT START ====
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
struct vertex_t {
|
||||
UNITY_VERTEX_INPUT_INSTANCE_ID
|
||||
float4 position : POSITION;
|
||||
|
||||
@@ -1,27 +1,36 @@
|
||||
#ifndef UI_EFFECT_INCLUDED
|
||||
#define UI_EFFECT_INCLUDED
|
||||
|
||||
uniform float4 _MainTex_TexelSize;
|
||||
uniform float _ToneIntensity;
|
||||
uniform half4 _ColorValue;
|
||||
uniform float _ColorIntensity;
|
||||
uniform int _ColorGlow;
|
||||
uniform float _SamplingIntensity;
|
||||
uniform float _SamplingScale;
|
||||
uniform sampler2D _TransitionTex;
|
||||
uniform float4 _TransitionTex_ST;
|
||||
uniform float _TransitionRate;
|
||||
uniform int _TransitionReverse;
|
||||
uniform half4 _TransitionColor;
|
||||
uniform int _TransitionColorGlow;
|
||||
uniform float _TransitionSoftness;
|
||||
uniform float _TransitionWidth;
|
||||
uniform fixed4 _TargetColor;
|
||||
uniform float _TargetRange;
|
||||
uniform float _TargetSoftness;
|
||||
uniform float _ShadowBlurIntensity;
|
||||
uniform half4 _ShadowColor;
|
||||
uniform int _ShadowColorGlow;
|
||||
uniform const float4 _MainTex_TexelSize;
|
||||
uniform const float _ToneIntensity;
|
||||
uniform const half4 _ColorValue;
|
||||
uniform const float _ColorIntensity;
|
||||
uniform const int _ColorGlow;
|
||||
uniform const float _SamplingIntensity;
|
||||
uniform const float _SamplingWidth;
|
||||
uniform const float _SamplingScale;
|
||||
uniform const sampler2D _TransitionTex;
|
||||
uniform const float4 _TransitionTex_ST;
|
||||
uniform const float _TransitionRate;
|
||||
uniform const int _TransitionReverse;
|
||||
uniform const half4 _TransitionColor;
|
||||
uniform const int _TransitionColorGlow;
|
||||
uniform const float _TransitionSoftness;
|
||||
uniform const float2 _TransitionRange;
|
||||
uniform const float _TransitionWidth;
|
||||
uniform const int _TransitionPatternReverse;
|
||||
uniform const float _TransitionAutoPlaySpeed;
|
||||
uniform const fixed4 _TargetColor;
|
||||
uniform const float _TargetRange;
|
||||
uniform const float _TargetSoftness;
|
||||
uniform const float _ShadowBlurIntensity;
|
||||
uniform const half4 _ShadowColor;
|
||||
uniform const int _ShadowColorGlow;
|
||||
uniform const float _EdgeWidth;
|
||||
uniform const float _EdgeShinyAutoPlaySpeed;
|
||||
uniform const float _EdgeShinyWidth;
|
||||
uniform const half4 _EdgeColor;
|
||||
uniform const int _PatternArea;
|
||||
|
||||
// For performance reasons, limit the sampling of blur in TextMeshPro.
|
||||
#ifdef UIEFFECT_TEXTMESHPRO
|
||||
@@ -36,20 +45,28 @@ uniform int _ShadowColorGlow;
|
||||
#endif
|
||||
|
||||
#define TONE_NONE (!TONE_GRAYSCALE && !TONE_SEPIA && !TONE_NEGATIVE && !TONE_RETRO && !TONE_POSTERIZE)
|
||||
#define SAMPLING_NONE (!SAMPLING_BLUR_FAST && !SAMPLING_BLUR_MEDIUM && !SAMPLING_BLUR_DETAIL && !SAMPLING_PIXELATION && !SAMPLING_RGB_SHIFT && !SAMPLING_EDGE)
|
||||
#define TRANSITION_NONE (!TRANSITION_FADE && !TRANSITION_CUTOFF && !TRANSITION_DISSOLVE && !TRANSITION_SHINY && !TRANSITION_MASK && !TRANSITION_MELT && !TRANSITION_BURN)
|
||||
#define SAMPLING_NONE (!SAMPLING_BLUR_FAST && !SAMPLING_BLUR_MEDIUM && !SAMPLING_BLUR_DETAIL && !SAMPLING_PIXELATION && !SAMPLING_RGB_SHIFT && !SAMPLING_EDGE_LUMINANCE && !SAMPLING_EDGE_ALPHA)
|
||||
#define TRANSITION_NONE (!TRANSITION_FADE && !TRANSITION_CUTOFF && !TRANSITION_DISSOLVE && !TRANSITION_SHINY && !TRANSITION_MASK && !TRANSITION_MELT && !TRANSITION_BURN && !TRANSITION_PATTERN)
|
||||
#define TARGET_NONE (!TARGET_HUE && !TARGET_LUMINANCE)
|
||||
|
||||
#define UIEFFECT_SAMPLE(uv) uieffect_frag(uv)
|
||||
#define UIEFFECT_SAMPLE_CLAMP(uv, uvMask) uieffect_frag(uv) \
|
||||
* step(uvMask.x, uv.x) * step(uv.x, uvMask.z) \
|
||||
* step(uvMask.y, uv.y) * step(uv.y, uvMask.w)
|
||||
#define TEX_SAMPLE_CLAMP(uv, uvMask) tex2D(_MainTex, uv) \
|
||||
* step(uvMask.x, uv.x) * step(uv.x, uvMask.z) \
|
||||
* step(uvMask.y, uv.y) * step(uv.y, uvMask.w)
|
||||
|
||||
float2 texel_size()
|
||||
{
|
||||
return _MainTex_TexelSize.xy * _SamplingScale;
|
||||
}
|
||||
|
||||
float transition_rate()
|
||||
{
|
||||
return frac(_TransitionAutoPlaySpeed * _Time.y + _TransitionRate);
|
||||
}
|
||||
|
||||
float3 rgb_to_hsv(float3 c)
|
||||
{
|
||||
const float4 K = float4(0.0, -1.0 / 3.0, 2.0 / 3.0, -1.0);
|
||||
@@ -74,13 +91,23 @@ float inv_lerp(const float from, const float to, const float value)
|
||||
|
||||
float transition_alpha(float2 uvLocal)
|
||||
{
|
||||
float2 uv;
|
||||
#if TRANSITION_NONE
|
||||
return 1;
|
||||
#elif TRANSITION_PATTERN
|
||||
{
|
||||
const half scale = lerp(100, 1, _TransitionWidth);
|
||||
const half2 time = half2(-transition_rate() * 2, 0);
|
||||
uv = uvLocal * _TransitionTex_ST.xy * scale + _TransitionTex_ST.zw + time;
|
||||
}
|
||||
#else
|
||||
{
|
||||
uv = uvLocal * _TransitionTex_ST.xy + _TransitionTex_ST.zw;
|
||||
}
|
||||
#endif
|
||||
|
||||
const float2 uv = uvLocal * _TransitionTex_ST.xy + _TransitionTex_ST.zw;
|
||||
const float alpha = tex2D(_TransitionTex, uv).a;
|
||||
return (1 - alpha) * _TransitionReverse + alpha * (1 - _TransitionReverse);
|
||||
return _TransitionReverse ? 1 - alpha : alpha;
|
||||
}
|
||||
|
||||
|
||||
@@ -287,6 +314,57 @@ half4 apply_shadow_color_filter(half4 color, const half4 factor, const float int
|
||||
return color;
|
||||
}
|
||||
|
||||
half4 apply_edge_color_filter(half4 color, const half4 factor, const float intensity)
|
||||
{
|
||||
const half4 inColor = color;
|
||||
#if EDGE_COLOR_NONE // Color.None
|
||||
{
|
||||
return color;
|
||||
}
|
||||
#elif EDGE_COLOR_MULTIPLY // Color.Multiply
|
||||
{
|
||||
color.rgb = color.rgb * factor.rgb;
|
||||
}
|
||||
#elif EDGE_COLOR_ADDITIVE // Color.Additive
|
||||
{
|
||||
color.rgb = color.rgb + factor.rgb * color.a;
|
||||
}
|
||||
#elif EDGE_COLOR_SUBTRACTIVE // Color.Subtractive
|
||||
{
|
||||
color.rgb = color.rgb - factor.rgb * color.a;
|
||||
}
|
||||
#elif EDGE_COLOR_REPLACE // Color.Replace
|
||||
{
|
||||
color.rgb = factor.rgb * color.a;
|
||||
}
|
||||
#elif EDGE_COLOR_MULTIPLY_LUMINANCE // Color.MultiplyLuminance
|
||||
{
|
||||
color.rgb = (1 + Luminance(color.rgb)) * factor.rgb / 2 * color.a;
|
||||
}
|
||||
#elif EDGE_COLOR_MULTIPLY_ADDITIVE // Color.MultiplyAdditive
|
||||
{
|
||||
color.rgb = color.rgb * (1 + factor.rgb);
|
||||
}
|
||||
#elif EDGE_COLOR_HSV_MODIFIER // Color.HsvModifier
|
||||
{
|
||||
const float3 hsv = rgb_to_hsv(color.rgb);
|
||||
color.rgb = hsv_to_rgb(hsv + factor.rgb) * color.a * factor.a;
|
||||
color.a = color.a * factor.a;
|
||||
}
|
||||
#elif EDGE_COLOR_CONTRAST // Color.Contrast
|
||||
{
|
||||
color.rgb = ((color.rgb - 0.5) * (factor.r + 1) + 0.5 + factor.g * 1.5) * color.a * factor.a;
|
||||
color.a = color.a * factor.a;
|
||||
}
|
||||
#else
|
||||
{
|
||||
return color;
|
||||
}
|
||||
#endif
|
||||
color = lerp(inColor, color, intensity);
|
||||
return color;
|
||||
}
|
||||
|
||||
half4 apply_sampling_filter(float2 uv, const float4 uvMask, const float2 uvLocal)
|
||||
{
|
||||
#if SAMPLING_BLUR_FAST || SAMPLING_BLUR_MEDIUM || SAMPLING_BLUR_DETAIL
|
||||
@@ -341,7 +419,7 @@ float2 move_transition_filter(const float4 uvMask, const float alpha)
|
||||
}
|
||||
#endif
|
||||
|
||||
const float factor = alpha - _TransitionRate * (1 + _TransitionWidth * 1.5) + _TransitionWidth;
|
||||
const float factor = alpha - transition_rate() * (1 + _TransitionWidth * 1.5) + _TransitionWidth;
|
||||
const float band = max(0, _TransitionWidth - factor);
|
||||
|
||||
#if TRANSITION_MELT
|
||||
@@ -357,20 +435,28 @@ float2 move_transition_filter(const float4 uvMask, const float alpha)
|
||||
return 0;
|
||||
}
|
||||
|
||||
half4 apply_transition_filter(half4 color, const float alpha)
|
||||
half4 apply_transition_filter(half4 color, const float alpha, const float2 uvLocal, float edgeFactor)
|
||||
{
|
||||
#if TRANSITION_FADE // Transition.Fade
|
||||
{
|
||||
color *= saturate(alpha + 1 - _TransitionRate * 2);
|
||||
color *= saturate(alpha + 1 - transition_rate() * 2);
|
||||
}
|
||||
#elif TRANSITION_CUTOFF // Transition.Cutoff
|
||||
{
|
||||
color *= step(0.001, alpha - _TransitionRate);
|
||||
color *= step(0.001, alpha - transition_rate());
|
||||
}
|
||||
#elif TRANSITION_PATTERN // Transition.Pattern
|
||||
{
|
||||
const half4 patternColor = apply_transition_color_filter(half4(color.rgb, 1), half4(_TransitionColor.rgb * color.a, 1), _TransitionColor.a);
|
||||
int isPattern = min(inv_lerp(_TransitionRange.x, _TransitionRange.y, uvLocal.x), 0.995) < (_TransitionPatternReverse ? alpha : 1 - alpha);
|
||||
isPattern = _TransitionPatternReverse ? isPattern : 1 - isPattern;
|
||||
const float patternFactor = _PatternArea == 0 ? 1 : _PatternArea == 1 ? 1 - edgeFactor : edgeFactor;
|
||||
color.rgb = lerp(color.rgb, patternColor.rgb, patternFactor * isPattern);
|
||||
}
|
||||
// Transition.Dissolve/Shiny/ShinyOnly/Melt
|
||||
#elif TRANSITION_DISSOLVE || TRANSITION_SHINY || TRANSITION_MASK || TRANSITION_MELT || TRANSITION_BURN
|
||||
{
|
||||
const float factor = alpha - _TransitionRate * (1 + _TransitionWidth) + _TransitionWidth;
|
||||
const float factor = alpha - transition_rate() * (1 + _TransitionWidth) + _TransitionWidth;
|
||||
const float softness = max(0.0001, _TransitionWidth * _TransitionSoftness);
|
||||
const fixed bandLerp = saturate((_TransitionWidth - factor) * 1 / softness);
|
||||
const fixed softLerp = saturate(factor * 2 / softness);
|
||||
@@ -423,24 +509,70 @@ half to_value(float4 c)
|
||||
return 0;
|
||||
}
|
||||
|
||||
float edge(float2 uv, const float4 uvMask, float width)
|
||||
{
|
||||
#if EDGE_PLAIN || EDGE_SHINY
|
||||
const float2 d = texel_size() * lerp(1, 20, width);
|
||||
float e = 1.0;
|
||||
|
||||
// Minimum alpha around the current pixel (12 neighbors)
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(1.0, 0.0)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(0.866025, 0.5)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(0.5, 0.866025)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(0.0, 1.0)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(-0.5, 0.866025)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(-0.866025, 0.5)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(-1.0, 0.0)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(-0.866025, -0.5)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(-0.5, -0.866025)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(0.0, -1.0)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(0.5, -0.866025)), uvMask)).a);
|
||||
e = min(e, (TEX_SAMPLE_CLAMP((uv + d * float2(0.866025, -0.5)), uvMask)).a);
|
||||
|
||||
return 1 - inv_lerp(0.15, 0.3, e);
|
||||
#else
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
int is_edge_shiny(const float2 uvLocal)
|
||||
{
|
||||
#if EDGE_SHINY
|
||||
const float deg = atan2(uvLocal.y - 0.5, uvLocal.x - 0.5) / UNITY_PI;
|
||||
return frac(_Time.y * _EdgeShinyAutoPlaySpeed + deg) < _EdgeShinyWidth;
|
||||
#else
|
||||
return 1;
|
||||
#endif
|
||||
}
|
||||
|
||||
half4 uieffect_internal(float2 uv, const float4 uvMask, const float2 uvLocal)
|
||||
{
|
||||
const half alpha = transition_alpha(uvLocal);
|
||||
const float edgeFactor = edge(uv, uvMask, _EdgeWidth);
|
||||
uv += move_transition_filter(uvMask, alpha);
|
||||
half4 color = apply_sampling_filter(uv, uvMask, uvLocal);
|
||||
color = apply_tone_filter(color);
|
||||
color = apply_transition_filter(color, alpha);
|
||||
color = apply_transition_filter(color, alpha, uvLocal, edgeFactor);
|
||||
|
||||
if (-4 <= uvLocal.x + uvLocal.y)
|
||||
{
|
||||
color = apply_color_filter(color, _ColorValue, _ColorIntensity);
|
||||
#if EDGE_PLAIN || EDGE_SHINY
|
||||
{
|
||||
color = apply_color_filter(color, _ColorValue, _ColorIntensity);
|
||||
const half4 edgeColor = apply_edge_color_filter(color, _EdgeColor, 1);
|
||||
const int isEdgeShiny = is_edge_shiny(uvLocal);
|
||||
return lerp(color, edgeColor, edgeFactor * isEdgeShiny);
|
||||
}
|
||||
#else
|
||||
{
|
||||
return apply_color_filter(color, _ColorValue, _ColorIntensity);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
color = apply_shadow_color_filter(color, _ShadowColor, 1);
|
||||
return apply_shadow_color_filter(color, _ShadowColor, 1);
|
||||
}
|
||||
|
||||
return color;
|
||||
}
|
||||
|
||||
half4 uieffect(float2 uv, const float4 uvMask, const float2 uvLocal)
|
||||
@@ -467,26 +599,17 @@ half4 uieffect(float2 uv, const float4 uvMask, const float2 uvLocal)
|
||||
#elif SAMPLING_EDGE_LUMINANCE || SAMPLING_EDGE_ALPHA
|
||||
{
|
||||
// Pixel size
|
||||
const float dx = texel_size().x;
|
||||
const float dy = texel_size().y;
|
||||
const float2 d = texel_size() * _SamplingWidth;
|
||||
|
||||
// Pixel values around the current pixel (3x3, 8 neighbors)
|
||||
const float2 uv00 = uv + half2(-dx, -dy);
|
||||
const half v00 = to_value(UIEFFECT_SAMPLE_CLAMP(uv00, uvMask));
|
||||
const float2 uv01 = uv + half2(-dx, 0.0);
|
||||
const half v01 = to_value(UIEFFECT_SAMPLE_CLAMP(uv01, uvMask));
|
||||
const float2 uv02 = uv + half2(-dx, +dy);
|
||||
const half v02 = to_value(UIEFFECT_SAMPLE_CLAMP(uv02, uvMask));
|
||||
const float2 uv10 = uv + half2(0.0, -dy);
|
||||
const half v10 = to_value(UIEFFECT_SAMPLE_CLAMP(uv10, uvMask));
|
||||
const float2 uv12 = uv + half2(0.0, +dy);
|
||||
const half v12 = to_value(UIEFFECT_SAMPLE_CLAMP(uv12, uvMask));
|
||||
const float2 uv20 = uv + half2(+dx, -dy);
|
||||
const half v20 = to_value(UIEFFECT_SAMPLE_CLAMP(uv20, uvMask));
|
||||
const float2 uv21 = uv + half2(+dx, 0.0);
|
||||
const half v21 = to_value(UIEFFECT_SAMPLE_CLAMP(uv21, uvMask));
|
||||
const float2 uv22 = uv + half2(+dx, +dy);
|
||||
const half v22 = to_value(UIEFFECT_SAMPLE_CLAMP(uv22, uvMask));
|
||||
const half v00 = to_value(TEX_SAMPLE_CLAMP((uv + half2(-d.x, -d.y)), uvMask));
|
||||
const half v01 = to_value(TEX_SAMPLE_CLAMP((uv + half2(-d.x, 0.0)), uvMask));
|
||||
const half v02 = to_value(TEX_SAMPLE_CLAMP((uv + half2(-d.x, +d.y)), uvMask));
|
||||
const half v10 = to_value(TEX_SAMPLE_CLAMP((uv + half2(0.0, -d.y)), uvMask));
|
||||
const half v12 = to_value(TEX_SAMPLE_CLAMP((uv + half2(0.0, +d.y)), uvMask));
|
||||
const half v20 = to_value(TEX_SAMPLE_CLAMP((uv + half2(+d.x, -d.y)), uvMask));
|
||||
const half v21 = to_value(TEX_SAMPLE_CLAMP((uv + half2(+d.x, 0.0)), uvMask));
|
||||
const half v22 = to_value(TEX_SAMPLE_CLAMP((uv + half2(+d.x, +d.y)), uvMask));
|
||||
|
||||
// Apply Sobel operator
|
||||
half sobel_h = v00 * -1.0 + v01 * -2.0 + v02 * -1.0 + v20 * 1.0 + v21 * 2.0 + v22 * 1.0;
|
||||
|
||||
@@ -60,9 +60,11 @@
|
||||
#pragma shader_feature_local_fragment _ TONE_GRAYSCALE TONE_SEPIA TONE_NEGATIVE TONE_RETRO TONE_POSTERIZE
|
||||
#pragma shader_feature_local_fragment _ COLOR_MULTIPLY COLOR_ADDITIVE COLOR_SUBTRACTIVE COLOR_REPLACE COLOR_MULTIPLY_LUMINANCE COLOR_MULTIPLY_ADDITIVE COLOR_HSV_MODIFIER COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SAMPLING_BLUR_FAST SAMPLING_BLUR_MEDIUM SAMPLING_BLUR_DETAIL SAMPLING_PIXELATION SAMPLING_RGB_SHIFT SAMPLING_EDGE_LUMINANCE SAMPLING_EDGE_ALPHA
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_FADE TRANSITION_CUTOFF TRANSITION_DISSOLVE TRANSITION_SHINY TRANSITION_MASK TRANSITION_MELT TRANSITION_BURN TRANSITION_PATTERN
|
||||
#pragma shader_feature_local_fragment _ TRANSITION_COLOR_MULTIPLY TRANSITION_COLOR_ADDITIVE TRANSITION_COLOR_SUBTRACTIVE TRANSITION_COLOR_REPLACE TRANSITION_COLOR_MULTIPLY_LUMINANCE TRANSITION_COLOR_MULTIPLY_ADDITIVE TRANSITION_COLOR_HSV_MODIFIER TRANSITION_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ SHADOW_COLOR_MULTIPLY SHADOW_COLOR_ADDITIVE SHADOW_COLOR_SUBTRACTIVE SHADOW_COLOR_REPLACE SHADOW_COLOR_MULTIPLY_LUMINANCE SHADOW_COLOR_MULTIPLY_ADDITIVE SHADOW_COLOR_HSV_MODIFIER SHADOW_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ EDGE_PLAIN EDGE_SHINY
|
||||
#pragma shader_feature_local_fragment _ EDGE_COLOR_MULTIPLY EDGE_COLOR_ADDITIVE EDGE_COLOR_SUBTRACTIVE EDGE_COLOR_REPLACE EDGE_COLOR_MULTIPLY_LUMINANCE EDGE_COLOR_MULTIPLY_ADDITIVE EDGE_COLOR_HSV_MODIFIER EDGE_COLOR_CONTRAST
|
||||
#pragma shader_feature_local_fragment _ TARGET_HUE TARGET_LUMINANCE
|
||||
// ==== UIEFFECT END ====
|
||||
|
||||
|
||||
@@ -0,0 +1,129 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &3884925358288914508
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5123527603865469805}
|
||||
- component: {fileID: 3240541677865467655}
|
||||
m_Layer: 0
|
||||
m_Name: Pattern - Dot
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
--- !u!4 &5123527603865469805
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &3240541677865467655
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 938fce054c42f40a3969e27a88d9bdd8, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_ToneFilter: 0
|
||||
m_ToneIntensity: 0.875
|
||||
m_ToneParams: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_ColorFilter: 0
|
||||
m_ColorIntensity: 0.213
|
||||
m_Color: {r: 0.16862746, g: 0, b: 0.12038653, a: 1}
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 0
|
||||
m_SamplingIntensity: 0.622
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 8
|
||||
m_TransitionRate: 0
|
||||
m_TransitionReverse: 0
|
||||
m_TransitionTex: {fileID: 2800000, guid: 51cf4ae69d327428fbac4ee73e8587fe, type: 3}
|
||||
m_TransitionTexScale: {x: 1, y: 1}
|
||||
m_TransitionTexOffset: {x: 0, y: 0}
|
||||
m_TransitionRotation: 45
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.5
|
||||
m_TransitionSoftness: 0.475
|
||||
m_TransitionRange:
|
||||
m_Min: 0.5
|
||||
m_Max: 0.85
|
||||
m_TransitionColorFilter: 1
|
||||
m_TransitionColor: {r: 0, g: 0, b: 0, a: 0.5019608}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TargetRange: 1
|
||||
m_TargetSoftness: 0.5
|
||||
m_BlendType: 1
|
||||
m_SrcBlendMode: 1
|
||||
m_DstBlendMode: 10
|
||||
m_ShadowMode: 0
|
||||
m_ShadowDistance: {x: 1, y: -1}
|
||||
m_ShadowIteration: 1
|
||||
m_ShadowFade: 0.9
|
||||
m_ShadowMirrorScale: 0.5
|
||||
m_ShadowBlurIntensity: 1
|
||||
m_ShadowColorFilter: 4
|
||||
m_ShadowColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_ShadowColorGlow: 0
|
||||
m_ShadowEdgeWidth: 0.5
|
||||
m_ShadowShinyDivide: 1
|
||||
m_ShadowShinyWidth: 0.5
|
||||
m_ShadowShinySpeed: 0.5
|
||||
m_ShadowPatternArea: 1
|
||||
m_GradationMode: 0
|
||||
m_GradationColor1: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationColor2: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationGradient:
|
||||
serializedVersion: 2
|
||||
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||
ctime0: 0
|
||||
ctime1: 65535
|
||||
ctime2: 0
|
||||
ctime3: 0
|
||||
ctime4: 0
|
||||
ctime5: 0
|
||||
ctime6: 0
|
||||
ctime7: 0
|
||||
atime0: 0
|
||||
atime1: 65535
|
||||
atime2: 0
|
||||
atime3: 0
|
||||
atime4: 0
|
||||
atime5: 0
|
||||
atime6: 0
|
||||
atime7: 0
|
||||
m_Mode: 0
|
||||
m_NumColorKeys: 2
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: 0
|
||||
m_GradationScale: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 177a6881273f54339b39e3e910d8af3b
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,129 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &3884925358288914508
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5123527603865469805}
|
||||
- component: {fileID: 3240541677865467655}
|
||||
m_Layer: 0
|
||||
m_Name: Pattern - Square
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
--- !u!4 &5123527603865469805
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &3240541677865467655
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 938fce054c42f40a3969e27a88d9bdd8, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_ToneFilter: 0
|
||||
m_ToneIntensity: 0.875
|
||||
m_ToneParams: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_ColorFilter: 0
|
||||
m_ColorIntensity: 0.213
|
||||
m_Color: {r: 0.16862746, g: 0, b: 0.12038653, a: 1}
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 0
|
||||
m_SamplingIntensity: 0.622
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 8
|
||||
m_TransitionRate: 0
|
||||
m_TransitionReverse: 0
|
||||
m_TransitionTex: {fileID: 2800000, guid: cc44bd7903939479d884303309530771, type: 3}
|
||||
m_TransitionTexScale: {x: 1, y: 1}
|
||||
m_TransitionTexOffset: {x: 0, y: 0}
|
||||
m_TransitionRotation: 45
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.5
|
||||
m_TransitionSoftness: 0.475
|
||||
m_TransitionRange:
|
||||
m_Min: 0.5
|
||||
m_Max: 0.85
|
||||
m_TransitionColorFilter: 1
|
||||
m_TransitionColor: {r: 0, g: 0, b: 0, a: 0.5019608}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TargetRange: 1
|
||||
m_TargetSoftness: 0.5
|
||||
m_BlendType: 1
|
||||
m_SrcBlendMode: 1
|
||||
m_DstBlendMode: 10
|
||||
m_ShadowMode: 0
|
||||
m_ShadowDistance: {x: 1, y: -1}
|
||||
m_ShadowIteration: 1
|
||||
m_ShadowFade: 0.9
|
||||
m_ShadowMirrorScale: 0.5
|
||||
m_ShadowBlurIntensity: 1
|
||||
m_ShadowColorFilter: 4
|
||||
m_ShadowColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_ShadowColorGlow: 0
|
||||
m_ShadowEdgeWidth: 0.5
|
||||
m_ShadowShinyDivide: 1
|
||||
m_ShadowShinyWidth: 0.5
|
||||
m_ShadowShinySpeed: 0.5
|
||||
m_ShadowPatternArea: 1
|
||||
m_GradationMode: 0
|
||||
m_GradationColor1: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationColor2: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationGradient:
|
||||
serializedVersion: 2
|
||||
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||
ctime0: 0
|
||||
ctime1: 65535
|
||||
ctime2: 0
|
||||
ctime3: 0
|
||||
ctime4: 0
|
||||
ctime5: 0
|
||||
ctime6: 0
|
||||
ctime7: 0
|
||||
atime0: 0
|
||||
atime1: 65535
|
||||
atime2: 0
|
||||
atime3: 0
|
||||
atime4: 0
|
||||
atime5: 0
|
||||
atime6: 0
|
||||
atime7: 0
|
||||
m_Mode: 0
|
||||
m_NumColorKeys: 2
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: 0
|
||||
m_GradationScale: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 312ff4f95d22a4ddba932b33b53e06d4
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,129 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &3884925358288914508
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5123527603865469805}
|
||||
- component: {fileID: 3240541677865467655}
|
||||
m_Layer: 0
|
||||
m_Name: Pattern - Star
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
--- !u!4 &5123527603865469805
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &3240541677865467655
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 938fce054c42f40a3969e27a88d9bdd8, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_ToneFilter: 0
|
||||
m_ToneIntensity: 0.875
|
||||
m_ToneParams: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_ColorFilter: 0
|
||||
m_ColorIntensity: 0.213
|
||||
m_Color: {r: 0.16862746, g: 0, b: 0.12038653, a: 1}
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 0
|
||||
m_SamplingIntensity: 0.622
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 8
|
||||
m_TransitionRate: 0
|
||||
m_TransitionReverse: 0
|
||||
m_TransitionTex: {fileID: 2800000, guid: 0ab909246f72242358deb093241bb627, type: 3}
|
||||
m_TransitionTexScale: {x: 1, y: 1}
|
||||
m_TransitionTexOffset: {x: 0, y: 0}
|
||||
m_TransitionRotation: 45
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.5
|
||||
m_TransitionSoftness: 0.475
|
||||
m_TransitionRange:
|
||||
m_Min: 0.5
|
||||
m_Max: 0.85
|
||||
m_TransitionColorFilter: 1
|
||||
m_TransitionColor: {r: 0, g: 0, b: 0, a: 0.5019608}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TargetRange: 1
|
||||
m_TargetSoftness: 0.5
|
||||
m_BlendType: 1
|
||||
m_SrcBlendMode: 1
|
||||
m_DstBlendMode: 10
|
||||
m_ShadowMode: 0
|
||||
m_ShadowDistance: {x: 1, y: -1}
|
||||
m_ShadowIteration: 1
|
||||
m_ShadowFade: 0.9
|
||||
m_ShadowMirrorScale: 0.5
|
||||
m_ShadowBlurIntensity: 1
|
||||
m_ShadowColorFilter: 4
|
||||
m_ShadowColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_ShadowColorGlow: 0
|
||||
m_ShadowEdgeWidth: 0.5
|
||||
m_ShadowShinyDivide: 1
|
||||
m_ShadowShinyWidth: 0.5
|
||||
m_ShadowShinySpeed: 0.5
|
||||
m_ShadowPatternArea: 1
|
||||
m_GradationMode: 0
|
||||
m_GradationColor1: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationColor2: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationGradient:
|
||||
serializedVersion: 2
|
||||
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||
ctime0: 0
|
||||
ctime1: 65535
|
||||
ctime2: 0
|
||||
ctime3: 0
|
||||
ctime4: 0
|
||||
ctime5: 0
|
||||
ctime6: 0
|
||||
ctime7: 0
|
||||
atime0: 0
|
||||
atime1: 65535
|
||||
atime2: 0
|
||||
atime3: 0
|
||||
atime4: 0
|
||||
atime5: 0
|
||||
atime6: 0
|
||||
atime7: 0
|
||||
m_Mode: 0
|
||||
m_NumColorKeys: 2
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: 0
|
||||
m_GradationScale: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 23ce00335d2f64744afca0ec961ad148
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,128 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &3884925358288914508
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5123527603865469805}
|
||||
- component: {fileID: 3240541677865467655}
|
||||
m_Layer: 0
|
||||
m_Name: Pattern - Stripe
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
--- !u!4 &5123527603865469805
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &3240541677865467655
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3884925358288914508}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 938fce054c42f40a3969e27a88d9bdd8, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_ToneFilter: 0
|
||||
m_ToneIntensity: 0.875
|
||||
m_ToneParams: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_ColorFilter: 0
|
||||
m_ColorIntensity: 0.213
|
||||
m_Color: {r: 0.16862746, g: 0, b: 0.12038653, a: 1}
|
||||
m_ColorGlow: 0
|
||||
m_SamplingFilter: 0
|
||||
m_SamplingIntensity: 0.622
|
||||
m_SamplingScale: 1
|
||||
m_TransitionFilter: 8
|
||||
m_TransitionRate: 0
|
||||
m_TransitionReverse: 0
|
||||
m_TransitionTex: {fileID: 2800000, guid: 40d1a96251dfd4353a7d28680e56c2e7, type: 3}
|
||||
m_TransitionTexScale: {x: 1, y: 1}
|
||||
m_TransitionTexOffset: {x: 0, y: 0}
|
||||
m_TransitionRotation: 45
|
||||
m_TransitionKeepAspectRatio: 1
|
||||
m_TransitionWidth: 0.85
|
||||
m_TransitionSoftness: 0.475
|
||||
m_TransitionRange:
|
||||
m_Min: 0
|
||||
m_Max: 1
|
||||
m_TransitionColorFilter: 1
|
||||
m_TransitionColor: {r: 0, g: 0, b: 0, a: 0.5019608}
|
||||
m_TransitionColorGlow: 0
|
||||
m_TargetMode: 0
|
||||
m_TargetColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TargetRange: 1
|
||||
m_TargetSoftness: 0.5
|
||||
m_BlendType: 1
|
||||
m_SrcBlendMode: 1
|
||||
m_DstBlendMode: 10
|
||||
m_ShadowMode: 0
|
||||
m_ShadowDistance: {x: 1, y: -1}
|
||||
m_ShadowIteration: 1
|
||||
m_ShadowFade: 0.9
|
||||
m_ShadowMirrorScale: 0.5
|
||||
m_ShadowBlurIntensity: 1
|
||||
m_ShadowColorFilter: 4
|
||||
m_ShadowColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_ShadowColorGlow: 0
|
||||
m_ShadowEdgeWidth: 0.5
|
||||
m_ShadowShinyWidth: 0.5
|
||||
m_ShadowShinySpeed: 0.5
|
||||
m_ShadowPatternArea: 1
|
||||
m_GradationMode: 0
|
||||
m_GradationColor1: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationColor2: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_GradationGradient:
|
||||
serializedVersion: 2
|
||||
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||
ctime0: 0
|
||||
ctime1: 65535
|
||||
ctime2: 0
|
||||
ctime3: 0
|
||||
ctime4: 0
|
||||
ctime5: 0
|
||||
ctime6: 0
|
||||
ctime7: 0
|
||||
atime0: 0
|
||||
atime1: 65535
|
||||
atime2: 0
|
||||
atime3: 0
|
||||
atime4: 0
|
||||
atime5: 0
|
||||
atime6: 0
|
||||
atime7: 0
|
||||
m_Mode: 0
|
||||
m_NumColorKeys: 2
|
||||
m_NumAlphaKeys: 2
|
||||
m_GradationOffset: 0
|
||||
m_GradationScale: 1
|
||||
m_GradationRotation: 0
|
||||
m_AllowToModifyMeshShape: 1
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 538655e7d09c24bd896fbc8d8008e6b8
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 31 KiB |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 51cf4ae69d327428fbac4ee73e8587fe
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 0
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 0
|
||||
wrapV: 0
|
||||
wrapW: 0
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 2
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 10
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 64
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID:
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 36 KiB |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: cc44bd7903939479d884303309530771
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 0
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 0
|
||||
wrapV: 0
|
||||
wrapW: 0
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 2
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 10
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 32
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID:
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 18 KiB |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0ab909246f72242358deb093241bb627
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 0
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 0
|
||||
wrapV: 0
|
||||
wrapW: 0
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 2
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 10
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 64
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID:
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
After Width: | Height: | Size: 72 B |
@@ -0,0 +1,159 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 40d1a96251dfd4353a7d28680e56c2e7
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 0
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMasterTextureLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 0
|
||||
wrapV: 0
|
||||
wrapW: 0
|
||||
nPOTScale: 1
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 0
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 2
|
||||
alphaIsTransparency: 0
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 10
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 32
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: WebGL
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: iPhone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Android
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Server
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID:
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -2,7 +2,7 @@
|
||||
"name": "com.coffee.ui-effect",
|
||||
"displayName": "UI Effect",
|
||||
"description": "UIEffect is an open-source package that allows you to intuitively apply rich UI effects directly from the Inspector or via code.\nCombine various filters, such as grayscale, blur, and dissolve, to decorate your UI with a unique visual style!",
|
||||
"version": "5.1.0",
|
||||
"version": "5.3.3",
|
||||
"unity": "2020.3",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
|
||||
@@ -26,4 +26,7 @@ EditorBuildSettings:
|
||||
- enabled: 0
|
||||
path: Assets/Demos/PerformanceTest/PerformanceTest.unity
|
||||
guid: 3a7d90cc463ac409fa50ecb46480ebc6
|
||||
- enabled: 1
|
||||
path: Assets/Demos/PatternAndEdge/PatternAndEdge.unity
|
||||
guid: 263e512bc0ad44038af0c3a4e37b6b33
|
||||
m_configObjects: {}
|
||||
|
||||