37 lines
643 B
Text
37 lines
643 B
Text
Shader "CrispyPin/Raymarch2"
|
|
{
|
|
Properties
|
|
{
|
|
[Header(Raymarcher Properties)]
|
|
_MaxSteps ("Max steps", Integer) = 256
|
|
_MaxDist ("Max distance", Float) = 100
|
|
_SurfDist ("Surface distance threshold", Range(0.00001, 0.05)) = 0.001
|
|
}
|
|
SubShader
|
|
{
|
|
Tags { "RenderType"="Opaque" }
|
|
Cull Off
|
|
LOD 100
|
|
Pass
|
|
{
|
|
CGPROGRAM
|
|
#pragma vertex vertex
|
|
#pragma fragment fragment
|
|
|
|
#define IS_SECONDARY_SHAPE
|
|
#include "raymarcher.cginc"
|
|
|
|
v2f vertex (appdata v){
|
|
return vert(v);
|
|
}
|
|
|
|
fragOut fragment (v2f i) {
|
|
return frag(i);
|
|
// fragOut o = frag(i);
|
|
// o.col = 0.4f;
|
|
// return o;
|
|
}
|
|
ENDCG
|
|
}
|
|
}
|
|
}
|