shaders innit

This commit is contained in:
Nathan Rashleigh committed 2025-10-23 17:43:57 +11:00
1 parent 7d8cdb8d6e
commit 177f7bbbba
87 files changed
+3072 -14

No files matched your search

BIN
View File
Binary file not shown.
View File
File mode changed.
BIN
View File
Binary file not shown.
+13
View File
@@ -93,6 +93,19 @@ TextureImporter:
ignorePlatformSupport: 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
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Server
maxTextureSize: 2048
+85
View File
@@ -0,0 +1,85 @@
Shader "Skybox/PsychedelicSkyboxURP_SineFlow"
{
Properties
{
_BaseColor ("Base Color", Color) = (0.05, 0.05, 0.08, 1)
_AccentColor ("Accent Color", Color) = (0.2, 0.8, 1.0, 1)
_SecondaryColor ("Secondary Color", Color) = (1.0, 0.6, 0.2, 1)
_Intensity ("Emission Intensity", Range(0, 10)) = 2.5
_Speed ("Animation Speed", Range(0.1, 5)) = 1.0
_WarpStrength ("Warp Strength", Range(0.0, 2.0)) = 0.6
}
SubShader
{
Tags { "RenderType"="Background" "Queue"="Background" "PreviewType"="Skybox" }
Cull Off ZWrite Off ZTest Always
Pass
{
Name "SkyboxPass"
Tags { "LightMode"="UniversalForward" }
HLSLPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
// === Properties ===
float4 _BaseColor;
float4 _AccentColor;
float4 _SecondaryColor;
float _Intensity;
float _Speed;
float _WarpStrength;
struct Attributes
{
float4 positionOS : POSITION;
};
struct Varyings
{
float4 positionCS : SV_POSITION;
float3 viewDirWS : TEXCOORD0;
};
Varyings vert(Attributes v)
{
Varyings o;
o.positionCS = TransformObjectToHClip(v.positionOS.xyz);
o.viewDirWS = GetSkyboxViewDirWS(v.positionOS.xyz);
return o;
}
half4 frag(Varyings i) : SV_Target
{
// Convert 3D direction to a 2D UV projection
float3 dir = normalize(i.viewDirWS);
float2 uv = dir.xy / max(1e-3, (1.0 + dir.z)); // spherical projection
float time = _Time.y * _Speed;
// --- Warping loop (GLSL style port) ---
float2 warped = uv;
[unroll(9)]
for (float j = 1.0; j < 10.0; j++)
{
warped.x += _WarpStrength / j * cos(j * 2.5 * warped.y + time);
warped.y += _WarpStrength / j * cos(j * 1.5 * warped.x + time);
}
float glow = 0.1 / abs(sin(time - warped.y - warped.x));
glow = saturate(glow * 5.0);
float3 col = lerp(_BaseColor.rgb, _AccentColor.rgb, glow);
col = lerp(col, _SecondaryColor.rgb, pow(glow, 3.0));
return half4(col * _Intensity, 1.0);
}
ENDHLSL
}
}
FallBack Off
}
+9
View File
@@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: b69140c2d2b33f242a02a99441d6f952
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:
+182
View File
@@ -0,0 +1,182 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-4147463417943901554
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 7
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: sfz_skybox_shader
m_Shader: {fileID: 4800000, guid: b69140c2d2b33f242a02a99441d6f952, type: 3}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords: []
m_InvalidKeywords: []
m_LightmapFlags: 4
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BackTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DownTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _FrontTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _GlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _LeftTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _RightTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _Tex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _UpTex:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _AlphaToMask: 0
- _Blend: 0
- _BlendModePreserveSpecular: 1
- _BumpScale: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DistortStrength: 0.6
- _DstBlend: 0
- _DstBlendAlpha: 0
- _EnvironmentReflections: 1
- _Exposure: 1
- _FlowSpeed: 1
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _Intensity: 0.78
- _Metallic: 0
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Rotation: 0
- _Scale: 4.94
- _Shininess: 0.078125
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _Speed: 0.073
- _SquashAmount: 1
- _SrcBlend: 1
- _SrcBlendAlpha: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 1
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _Color1: {r: 0.03137255, g: 0.027450982, b: 0.027450982, a: 1}
- _Color2: {r: 0.37647063, g: 0.6313726, b: 0.5568628, a: 1}
- _Color3: {r: 0.4666667, g: 0.34117648, b: 0.15686275, a: 1}
- _Color4: {r: 0.4, g: 0.7, b: 0.6, a: 1}
- _Color5: {r: 0.9, g: 0.95, b: 0.8, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SpecColor: {r: 0.2, g: 0.2, b: 0.2, a: 1}
- _StarColor: {r: 1, g: 0.85, b: 0.6, a: 1}
- _Tint: {r: 0.5, g: 0.5, b: 0.5, a: 0.5}
- _TreeInstanceColor: {r: 1, g: 1, b: 1, a: 1}
- _TreeInstanceScale: {r: 1, g: 1, b: 1, a: 1}
m_BuildTextureStacks: []
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8eea8031e6a079d4d9422691e64d4690
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:
View File
File mode changed.
+1 -1
View File
@@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 37d964cd6f6bb314bb1d5ca7f495aa2c
guid: e6a819a4c35b93f4cabfbc6fe6abb29d
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
Binary file not shown.
Binary file not shown.
@@ -9,7 +9,7 @@ LightingSettings:
m_Name: sr_star_fraenkel_zermelo
serializedVersion: 6
m_GIWorkflowMode: 1
m_EnableBakedLightmaps: 0
m_EnableBakedLightmaps: 1
m_EnableRealtimeLightmaps: 1
m_RealtimeEnvironmentLighting: 1
m_BounceScale: 1