app.hypergames.hypersdk 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/.github/workflows/check-sync.yml +0 -2
  2. package/CHANGELOG.md +9 -0
  3. package/dev-hypersdk/Assets/Editor/HyperSDKSyncTool.cs +0 -1
  4. package/package.json +1 -1
  5. package/upm-hypersdk/app.hypergames.hypersdk/Resources/DOTweenSettings.asset +0 -54
  6. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Fonts/LiberationSans - OFL.txt +0 -46
  7. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Fonts/LiberationSans.ttf +0 -0
  8. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Drop Shadow.mat +0 -106
  9. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Fallback.asset +0 -348
  10. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF - Outline.mat +0 -104
  11. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/Fonts & Materials/LiberationSans SDF.asset +0 -7821
  12. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/LineBreaking Following Characters.txt +0 -1
  13. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/LineBreaking Leading Characters.txt +0 -1
  14. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/Sprite Assets/EmojiOne.asset +0 -659
  15. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/Style Sheets/Default Style Sheet.asset +0 -81
  16. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Resources/TMP Settings.asset +0 -52
  17. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/SDFFunctions.hlsl +0 -178
  18. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_Bitmap-Custom-Atlas.shader +0 -145
  19. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_Bitmap-Mobile.shader +0 -155
  20. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_Bitmap.shader +0 -145
  21. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF Overlay.shader +0 -326
  22. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF SSD.shader +0 -321
  23. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-HDRP LIT.shadergraph +0 -12074
  24. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-HDRP UNLIT.shadergraph +0 -11759
  25. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Mobile Masking.shader +0 -258
  26. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Mobile Overlay.shader +0 -252
  27. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Mobile SSD.shader +0 -106
  28. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Mobile-2-Pass.shader +0 -389
  29. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Mobile.shader +0 -250
  30. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Surface-Mobile.shader +0 -139
  31. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-Surface.shader +0 -159
  32. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-URP Lit.shadergraph +0 -11932
  33. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF-URP Unlit.shadergraph +0 -11629
  34. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_SDF.shader +0 -326
  35. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMP_Sprite.shader +0 -131
  36. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMPro.cginc +0 -84
  37. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMPro_Mobile.cginc +0 -165
  38. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMPro_Properties.cginc +0 -80
  39. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Shaders/TMPro_Surface.cginc +0 -99
  40. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Sprites/EmojiOne Attribution.txt +0 -3
  41. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Sprites/EmojiOne.json +0 -156
  42. package/upm-hypersdk/app.hypergames.hypersdk/Resources/TextMesh Pro/Sprites/EmojiOne.png +0 -0
@@ -1,321 +0,0 @@
1
- Shader "TextMeshPro/Distance Field SSD" {
2
-
3
- Properties {
4
- _FaceTex ("Face Texture", 2D) = "white" {}
5
- _FaceUVSpeedX ("Face UV Speed X", Range(-5, 5)) = 0.0
6
- _FaceUVSpeedY ("Face UV Speed Y", Range(-5, 5)) = 0.0
7
- _FaceColor ("Face Color", Color) = (1,1,1,1)
8
- _FaceDilate ("Face Dilate", Range(-1,1)) = 0
9
-
10
- _OutlineColor ("Outline Color", Color) = (0,0,0,1)
11
- _OutlineTex ("Outline Texture", 2D) = "white" {}
12
- _OutlineUVSpeedX ("Outline UV Speed X", Range(-5, 5)) = 0.0
13
- _OutlineUVSpeedY ("Outline UV Speed Y", Range(-5, 5)) = 0.0
14
- _OutlineWidth ("Outline Thickness", Range(0, 1)) = 0
15
- _OutlineSoftness ("Outline Softness", Range(0,1)) = 0
16
-
17
- _Bevel ("Bevel", Range(0,1)) = 0.5
18
- _BevelOffset ("Bevel Offset", Range(-0.5,0.5)) = 0
19
- _BevelWidth ("Bevel Width", Range(-.5,0.5)) = 0
20
- _BevelClamp ("Bevel Clamp", Range(0,1)) = 0
21
- _BevelRoundness ("Bevel Roundness", Range(0,1)) = 0
22
-
23
- _LightAngle ("Light Angle", Range(0.0, 6.2831853)) = 3.1416
24
- _SpecularColor ("Specular", Color) = (1,1,1,1)
25
- _SpecularPower ("Specular", Range(0,4)) = 2.0
26
- _Reflectivity ("Reflectivity", Range(5.0,15.0)) = 10
27
- _Diffuse ("Diffuse", Range(0,1)) = 0.5
28
- _Ambient ("Ambient", Range(1,0)) = 0.5
29
-
30
- _BumpMap ("Normal map", 2D) = "bump" {}
31
- _BumpOutline ("Bump Outline", Range(0,1)) = 0
32
- _BumpFace ("Bump Face", Range(0,1)) = 0
33
-
34
- _ReflectFaceColor ("Reflection Color", Color) = (0,0,0,1)
35
- _ReflectOutlineColor("Reflection Color", Color) = (0,0,0,1)
36
- _Cube ("Reflection Cubemap", Cube) = "black" { /* TexGen CubeReflect */ }
37
- _EnvMatrixRotation ("Texture Rotation", vector) = (0, 0, 0, 0)
38
-
39
-
40
- _UnderlayColor ("Border Color", Color) = (0,0,0, 0.5)
41
- _UnderlayOffsetX ("Border OffsetX", Range(-1,1)) = 0
42
- _UnderlayOffsetY ("Border OffsetY", Range(-1,1)) = 0
43
- _UnderlayDilate ("Border Dilate", Range(-1,1)) = 0
44
- _UnderlaySoftness ("Border Softness", Range(0,1)) = 0
45
-
46
- _GlowColor ("Color", Color) = (0, 1, 0, 0.5)
47
- _GlowOffset ("Offset", Range(-1,1)) = 0
48
- _GlowInner ("Inner", Range(0,1)) = 0.05
49
- _GlowOuter ("Outer", Range(0,1)) = 0.05
50
- _GlowPower ("Falloff", Range(1, 0)) = 0.75
51
-
52
- _WeightNormal ("Weight Normal", float) = 0
53
- _WeightBold ("Weight Bold", float) = 0.5
54
-
55
- _ShaderFlags ("Flags", float) = 0
56
- _ScaleRatioA ("Scale RatioA", float) = 1
57
- _ScaleRatioB ("Scale RatioB", float) = 1
58
- _ScaleRatioC ("Scale RatioC", float) = 1
59
-
60
- _MainTex ("Font Atlas", 2D) = "white" {}
61
- _TextureWidth ("Texture Width", float) = 512
62
- _TextureHeight ("Texture Height", float) = 512
63
- _GradientScale ("Gradient Scale", float) = 5.0
64
- _ScaleX ("Scale X", float) = 1.0
65
- _ScaleY ("Scale Y", float) = 1.0
66
- _PerspectiveFilter ("Perspective Correction", Range(0, 1)) = 0.875
67
- _Sharpness ("Sharpness", Range(-1,1)) = 0
68
-
69
- _VertexOffsetX ("Vertex OffsetX", float) = 0
70
- _VertexOffsetY ("Vertex OffsetY", float) = 0
71
-
72
- _MaskCoord ("Mask Coordinates", vector) = (0, 0, 32767, 32767)
73
- _ClipRect ("Clip Rect", vector) = (-32767, -32767, 32767, 32767)
74
- _MaskSoftnessX ("Mask SoftnessX", float) = 0
75
- _MaskSoftnessY ("Mask SoftnessY", float) = 0
76
-
77
- _StencilComp ("Stencil Comparison", Float) = 8
78
- _Stencil ("Stencil ID", Float) = 0
79
- _StencilOp ("Stencil Operation", Float) = 0
80
- _StencilWriteMask ("Stencil Write Mask", Float) = 255
81
- _StencilReadMask ("Stencil Read Mask", Float) = 255
82
-
83
- _CullMode ("Cull Mode", Float) = 0
84
- _ColorMask ("Color Mask", Float) = 15
85
- }
86
-
87
- SubShader {
88
- Tags
89
- {
90
- "Queue" = "Transparent"
91
- "IgnoreProjector" = "True"
92
- "RenderType" = "Transparent"
93
- }
94
-
95
- Stencil
96
- {
97
- Ref[_Stencil]
98
- Comp[_StencilComp]
99
- Pass[_StencilOp]
100
- ReadMask[_StencilReadMask]
101
- WriteMask[_StencilWriteMask]
102
- }
103
-
104
- Cull[_CullMode]
105
- ZWrite Off
106
- Lighting Off
107
- Fog { Mode Off }
108
- ZTest[unity_GUIZTestMode]
109
- Blend One OneMinusSrcAlpha
110
- ColorMask[_ColorMask]
111
-
112
- Pass
113
- {
114
- CGPROGRAM
115
- #pragma target 3.0
116
- #pragma vertex VertShader
117
- #pragma fragment PixShader
118
- #pragma shader_feature __ BEVEL_ON
119
- #pragma shader_feature __ UNDERLAY_ON UNDERLAY_INNER
120
- #pragma shader_feature __ GLOW_ON
121
- #pragma shader_feature __ FORCE_LINEAR
122
-
123
- #pragma multi_compile __ UNITY_UI_CLIP_RECT
124
- #pragma multi_compile __ UNITY_UI_ALPHACLIP
125
-
126
- #include "UnityCG.cginc"
127
- #include "UnityUI.cginc"
128
- #include "TMPro_Properties.cginc"
129
- #include "TMPro.cginc"
130
-
131
- struct vertex_t
132
- {
133
- UNITY_VERTEX_INPUT_INSTANCE_ID
134
- float4 position : POSITION;
135
- float3 normal : NORMAL;
136
- float4 color : COLOR;
137
- float4 texcoord0 : TEXCOORD0;
138
- float2 texcoord1 : TEXCOORD1;
139
- };
140
-
141
- struct pixel_t
142
- {
143
- UNITY_VERTEX_INPUT_INSTANCE_ID
144
- UNITY_VERTEX_OUTPUT_STEREO
145
- float4 position : SV_POSITION;
146
- float4 color : COLOR;
147
- float2 atlas : TEXCOORD0;
148
- float weight : TEXCOORD1;
149
- float2 mask : TEXCOORD2; // Position in object space(xy)
150
- float3 viewDir : TEXCOORD3;
151
-
152
- #if (UNDERLAY_ON || UNDERLAY_INNER)
153
- float2 texcoord2 : TEXCOORD4;
154
- float4 underlayColor : COLOR1;
155
- #endif
156
-
157
- float4 textures : TEXCOORD5;
158
- };
159
-
160
- // Used by Unity internally to handle Texture Tiling and Offset.
161
- float4 _FaceTex_ST;
162
- float4 _OutlineTex_ST;
163
- float _UIMaskSoftnessX;
164
- float _UIMaskSoftnessY;
165
- int _UIVertexColorAlwaysGammaSpace;
166
-
167
- float4 SRGBToLinear(float4 rgba)
168
- {
169
- return float4(lerp(rgba.rgb / 12.92f, pow((rgba.rgb + 0.055f) / 1.055f, 2.4f), step(0.04045f, rgba.rgb)), rgba.a);
170
- }
171
-
172
- pixel_t VertShader(vertex_t input)
173
- {
174
- pixel_t output;
175
-
176
- UNITY_INITIALIZE_OUTPUT(pixel_t, output);
177
- UNITY_SETUP_INSTANCE_ID(input);
178
- UNITY_TRANSFER_INSTANCE_ID(input,output);
179
- UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(output);
180
-
181
- float bold = step(input.texcoord0.w, 0);
182
-
183
- float4 vert = input.position;
184
- vert.x += _VertexOffsetX;
185
- vert.y += _VertexOffsetY;
186
-
187
- float4 vPosition = UnityObjectToClipPos(vert);
188
-
189
- float weight = lerp(_WeightNormal, _WeightBold, bold) / 4.0;
190
- weight = (weight + _FaceDilate) * _ScaleRatioA * 0.5;
191
-
192
- #if (UNDERLAY_ON || UNDERLAY_INNER)
193
- float4 underlayColor = _UnderlayColor;
194
- underlayColor.rgb *= underlayColor.a;
195
-
196
- float x = -(_UnderlayOffsetX * _ScaleRatioC) * _GradientScale / _TextureWidth;
197
- float y = -(_UnderlayOffsetY * _ScaleRatioC) * _GradientScale / _TextureHeight;
198
- float2 bOffset = float2(x, y);
199
- #endif
200
-
201
- // Generate UV for the Masking Texture
202
- float4 clampedRect = clamp(_ClipRect, -2e10, 2e10);
203
-
204
- // Support for texture tiling and offset
205
- float2 textureUV = input.texcoord1;
206
- float2 faceUV = TRANSFORM_TEX(textureUV, _FaceTex);
207
- float2 outlineUV = TRANSFORM_TEX(textureUV, _OutlineTex);
208
-
209
- if (_UIVertexColorAlwaysGammaSpace && !IsGammaSpace())
210
- {
211
- input.color.rgb = UIGammaToLinear(input.color.rgb);
212
- }
213
- float4 color = input.color;
214
- #if (FORCE_LINEAR && !UNITY_COLORSPACE_GAMMA)
215
- color = SRGBToLinear(input.color);
216
- #endif
217
-
218
- output.position = vPosition;
219
- output.color = color;
220
- output.atlas = input.texcoord0;
221
- output.weight = weight;
222
- output.mask = half2(vert.xy * 2 - clampedRect.xy - clampedRect.zw);
223
- output.viewDir = mul((float3x3)_EnvMatrix, _WorldSpaceCameraPos.xyz - mul(unity_ObjectToWorld, vert).xyz);
224
- #if (UNDERLAY_ON || UNDERLAY_INNER)
225
- output.texcoord2 = input.texcoord0 + bOffset;
226
- output.underlayColor = underlayColor;
227
- #endif
228
- output.textures = float4(faceUV, outlineUV);
229
-
230
- return output;
231
- }
232
-
233
-
234
- fixed4 PixShader(pixel_t input) : SV_Target
235
- {
236
- UNITY_SETUP_INSTANCE_ID(input);
237
-
238
- float c = tex2D(_MainTex, input.atlas).a;
239
-
240
- float pixelSize = abs(ddx(input.atlas.y)) + abs(ddy(input.atlas.y));
241
- pixelSize *= _TextureHeight * 0.75;
242
- float scale = 1 / pixelSize * _GradientScale * (_Sharpness + 1);
243
-
244
- float weight = input.weight;
245
- float bias = (.5 - weight) + (.5 / scale);
246
- float sd = (bias - c) * scale;
247
-
248
- float outline = (_OutlineWidth * _ScaleRatioA) * scale;
249
- float softness = (_OutlineSoftness * _ScaleRatioA) * scale;
250
-
251
- half4 faceColor = _FaceColor;
252
- half4 outlineColor = _OutlineColor;
253
-
254
- faceColor.rgb *= input.color.rgb;
255
-
256
- faceColor *= tex2D(_FaceTex, input.textures.xy + float2(_FaceUVSpeedX, _FaceUVSpeedY) * _Time.y);
257
- outlineColor *= tex2D(_OutlineTex, input.textures.zw + float2(_OutlineUVSpeedX, _OutlineUVSpeedY) * _Time.y);
258
-
259
- faceColor = GetColor(sd, faceColor, outlineColor, outline, softness);
260
-
261
- #if BEVEL_ON
262
- float3 dxy = float3(0.5 / _TextureWidth, 0.5 / _TextureHeight, 0);
263
- float3 n = GetSurfaceNormal(input.atlas, weight, dxy);
264
-
265
- float3 bump = UnpackNormal(tex2D(_BumpMap, input.textures.xy + float2(_FaceUVSpeedX, _FaceUVSpeedY) * _Time.y)).xyz;
266
- bump *= lerp(_BumpFace, _BumpOutline, saturate(sd + outline * 0.5));
267
- n = normalize(n - bump);
268
-
269
- float3 light = normalize(float3(sin(_LightAngle), cos(_LightAngle), -1.0));
270
-
271
- float3 col = GetSpecular(n, light);
272
- faceColor.rgb += col * faceColor.a;
273
- faceColor.rgb *= 1 - (dot(n, light) * _Diffuse);
274
- faceColor.rgb *= lerp(_Ambient, 1, n.z * n.z);
275
-
276
- fixed4 reflcol = texCUBE(_Cube, reflect(input.viewDir, -n));
277
- faceColor.rgb += reflcol.rgb * lerp(_ReflectFaceColor.rgb, _ReflectOutlineColor.rgb, saturate(sd + outline * 0.5)) * faceColor.a;
278
- #endif
279
-
280
- #if (UNDERLAY_ON || UNDERLAY_INNER)
281
- float bScale = scale;
282
- bScale /= 1 + ((_UnderlaySoftness * _ScaleRatioC) * bScale);
283
- float bBias = (0.5 - weight) * bScale - 0.5 - ((_UnderlayDilate * _ScaleRatioC) * 0.5 * bScale);
284
- #endif
285
-
286
- #if UNDERLAY_ON
287
- float d = tex2D(_MainTex, input.texcoord2.xy).a * bScale;
288
- faceColor += input.underlayColor * saturate(d - bBias) * (1 - faceColor.a);
289
- #endif
290
-
291
- #if UNDERLAY_INNER
292
- float d = tex2D(_MainTex, input.texcoord2.xy).a * bScale;
293
- faceColor += input.underlayColor * (1 - saturate(d - bBias)) * saturate(1 - sd) * (1 - faceColor.a);
294
- #endif
295
-
296
- #if GLOW_ON
297
- float4 glowColor = GetGlowColor(sd, scale);
298
- faceColor.rgb += glowColor.rgb * glowColor.a;
299
- #endif
300
-
301
- // Alternative implementation to UnityGet2DClipping with support for softness.
302
- #if UNITY_UI_CLIP_RECT
303
- half2 maskSoftness = half2(max(_UIMaskSoftnessX, _MaskSoftnessX), max(_UIMaskSoftnessY, _MaskSoftnessY));
304
- float2 maskZW = 0.25 / (0.25 * maskSoftness + 1 / scale);
305
- half2 m = saturate((_ClipRect.zw - _ClipRect.xy - abs(input.mask.xy)) * maskZW);
306
- faceColor *= m.x * m.y;
307
- #endif
308
-
309
- #if UNITY_UI_ALPHACLIP
310
- clip(faceColor.a - 0.001);
311
- #endif
312
-
313
- return faceColor * input.color.a;
314
- }
315
- ENDCG
316
- }
317
- }
318
-
319
- Fallback "TextMeshPro/Mobile/Distance Field"
320
- CustomEditor "TMPro.EditorUtilities.TMP_SDFShaderGUI"
321
- }