Skip to content

Commit

Permalink
v0.511
Browse files Browse the repository at this point in the history
- Rewritten camera controls
- Editor now render other LOD levels of props
- Fixed render distances of decals
- Increased performance of decals rendering
- Fixed performance issues when painting heightmap
- Fixed performance issues when painting stratum layers
- Increased performance of water reflections
- Some small UI fixes
  • Loading branch information
ozonexo3 committed Nov 22, 2017
1 parent e8a2fc6 commit 018d127
Show file tree
Hide file tree
Showing 13 changed files with 271 additions and 102 deletions.
Binary file modified Assets/GFX/Terrain/ScmapTerrain.asset
Binary file not shown.
4 changes: 2 additions & 2 deletions Assets/GFX/Terrain/TerrainShader.mat
Original file line number Diff line number Diff line change
Expand Up @@ -238,14 +238,14 @@ Material:
- _AreaX: 0.1
- _AreaY: 0
- _Brush: 0
- _BrushSize: 74
- _BrushSize: 0
- _BrushUvX: 0.2517518
- _BrushUvY: 0.14237186
- _DeepLevel: 1.675625
- _DepthLevel: 1.5
- _GeneratingNormal: 0
- _Grid: 0
- _GridCamDist: 0.57900214
- _GridCamDist: 1.6312336
- _GridScale: 102.4
- _HideSplat0: 0
- _HideSplat1: 0
Expand Down
74 changes: 43 additions & 31 deletions Assets/MapEditor.unity
Original file line number Diff line number Diff line change
Expand Up @@ -24046,7 +24046,7 @@ Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 984649133}
m_TransformParent: {fileID: 504156400}
m_Modifications:
- target: {fileID: 4967785522131834, guid: 43eabdd4b4b8fcd4eac3ac9da09251f3, type: 2}
propertyPath: m_LocalPosition.x
Expand Down Expand Up @@ -24078,7 +24078,7 @@ Prefab:
objectReference: {fileID: 0}
- target: {fileID: 4967785522131834, guid: 43eabdd4b4b8fcd4eac3ac9da09251f3, type: 2}
propertyPath: m_RootOrder
value: 4
value: 8
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: 43eabdd4b4b8fcd4eac3ac9da09251f3, type: 2}
Expand Down Expand Up @@ -30654,6 +30654,7 @@ Transform:
- {fileID: 653814190}
- {fileID: 91059456}
- {fileID: 710350080}
- {fileID: 848131180}
m_Father: {fileID: 1334852570}
m_RootOrder: 6
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
Expand Down Expand Up @@ -33783,7 +33784,7 @@ Camera:
serializedVersion: 2
m_Bits: 2560
m_RenderingPath: 1
m_TargetTexture: {fileID: 1012570925}
m_TargetTexture: {fileID: 2001820003}
m_TargetDisplay: 0
m_TargetEye: 3
m_HDR: 0
Expand Down Expand Up @@ -59458,7 +59459,6 @@ Transform:
- {fileID: 1035241564}
- {fileID: 124756883}
- {fileID: 396239992}
- {fileID: 848131180}
m_Father: {fileID: 0}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
Expand Down Expand Up @@ -60988,33 +60988,6 @@ CanvasRenderer:
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1012003633}
--- !u!84 &1012570925
RenderTexture:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name:
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_Width: 256
m_Height: 256
m_AntiAliasing: 1
m_DepthFormat: 1
m_ColorFormat: 0
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 0
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
--- !u!1 &1013408409
GameObject:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -93972,6 +93945,18 @@ LODGroup:
m_PrefabParentObject: {fileID: 205490010641979160, guid: 0f85931f0ee0c944283691a1b137c8fd,
type: 2}
m_PrefabInternal: {fileID: 710350079}
--- !u!65 &1591655016
BoxCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1591655014}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Size: {x: 1, y: 0.1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!1 &1595197613
GameObject:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -118824,6 +118809,33 @@ RectTransform:
m_AnchoredPosition: {x: 0, y: -157}
m_SizeDelta: {x: 0, y: -314}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!84 &2001820003
RenderTexture:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name:
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_Width: 256
m_Height: 256
m_AntiAliasing: 1
m_DepthFormat: 1
m_ColorFormat: 0
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 0
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
--- !u!1 &2002014685
GameObject:
m_ObjectHideFlags: 0
Expand Down
158 changes: 155 additions & 3 deletions Assets/Prefabs/Props/PropObject.prefab
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,66 @@ GameObject:
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!1 &1563596100311092
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
serializedVersion: 5
m_Component:
- component: {fileID: 4386413788422584}
- component: {fileID: 33553052104043552}
- component: {fileID: 23523681635756824}
m_Layer: 0
m_Name: LOD1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!1 &1620244698608136
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
serializedVersion: 5
m_Component:
- component: {fileID: 4003689555091716}
- component: {fileID: 33208272633177094}
- component: {fileID: 23030511613166020}
m_Layer: 0
m_Name: LOD2
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &4003689555091716
Transform:
m_ObjectHideFlags: 1
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1620244698608136}
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_Children: []
m_Father: {fileID: 4967785522131834}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &4386413788422584
Transform:
m_ObjectHideFlags: 1
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1563596100311092}
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_Children: []
m_Father: {fileID: 4967785522131834}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &4967785522131834
Transform:
m_ObjectHideFlags: 1
Expand All @@ -39,10 +99,44 @@ Transform:
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: -1000, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Children:
- {fileID: 4386413788422584}
- {fileID: 4003689555091716}
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!23 &23030511613166020
MeshRenderer:
m_ObjectHideFlags: 1
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1620244698608136}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_Materials:
- {fileID: 2100000, guid: 54b33e75a061b6441baa0b2d63fc58d2, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
--- !u!23 &23054565091136388
MeshRenderer:
m_ObjectHideFlags: 1
Expand Down Expand Up @@ -75,6 +169,52 @@ MeshRenderer:
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
--- !u!23 &23523681635756824
MeshRenderer:
m_ObjectHideFlags: 1
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1563596100311092}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_Materials:
- {fileID: 2100000, guid: 54b33e75a061b6441baa0b2d63fc58d2, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
--- !u!33 &33208272633177094
MeshFilter:
m_ObjectHideFlags: 1
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1620244698608136}
m_Mesh: {fileID: 4300000, guid: cec6c7026bd5dab479ab7875f0fc87e0, type: 3}
--- !u!33 &33553052104043552
MeshFilter:
m_ObjectHideFlags: 1
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1563596100311092}
m_Mesh: {fileID: 4300000, guid: cec6c7026bd5dab479ab7875f0fc87e0, type: 3}
--- !u!33 &33897611517579588
MeshFilter:
m_ObjectHideFlags: 1
Expand All @@ -95,6 +235,10 @@ MonoBehaviour:
m_EditorClassIdentifier:
Mf: {fileID: 33897611517579588}
Mr: {fileID: 23054565091136388}
Mf1: {fileID: 33553052104043552}
Mr1: {fileID: 23523681635756824}
Mf2: {fileID: 33208272633177094}
Mr2: {fileID: 23030511613166020}
Lodg: {fileID: 205018698824645386}
Tr: {fileID: 4967785522131834}
--- !u!205 &205018698824645386
Expand All @@ -104,13 +248,21 @@ LODGroup:
m_PrefabInternal: {fileID: 100100000}
m_GameObject: {fileID: 1063863845251086}
serializedVersion: 2
m_LocalReferencePoint: {x: 0, y: 0, z: 0}
m_Size: 1
m_LocalReferencePoint: {x: 0, y: 0.08852364, z: 0}
m_Size: 0.16488904
m_FadeMode: 0
m_AnimateCrossFading: 0
m_LODs:
- screenRelativeHeight: 0.7938056
fadeTransitionWidth: 0
renderers:
- renderer: {fileID: 23054565091136388}
- screenRelativeHeight: 0.5726735
fadeTransitionWidth: 0
renderers:
- renderer: {fileID: 23523681635756824}
- screenRelativeHeight: 0.34329697
fadeTransitionWidth: 0
renderers:
- renderer: {fileID: 23030511613166020}
m_Enabled: 1
3 changes: 1 addition & 2 deletions Assets/Scripts/GFX/OzoneDecals/Shader/DecalsCommon.cginc
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ float2 uv = i.uv.xy / i.uv.w; \
float depth = SAMPLE_DEPTH_TEXTURE(_CameraDepthTexture, uv); \
depth = Linear01Depth(depth); \
float CutoffDistance = UNITY_ACCESS_INSTANCED_PROP(_CutOffLOD) * 0.4; \
float blend = clamp((UNITY_ACCESS_INSTANCED_PROP(_CutOffLOD) - (depth)) / CutoffDistance, 0, 1 ); \
blend = smoothstep(UNITY_ACCESS_INSTANCED_PROP(_CutOffLOD) * 1.5, CutoffDistance, depth); \
float blend = smoothstep(UNITY_ACCESS_INSTANCED_PROP(_CutOffLOD), CutoffDistance, depth); \
CutoffDistance = UNITY_ACCESS_INSTANCED_PROP(_NearCutOffLOD); \
blend *= clamp((depth - CutoffDistance) / CutoffDistance, 0, 1 ); \
float4 vpos = float4(i.ray * depth,1); \
Expand Down
Loading

0 comments on commit 018d127

Please sign in to comment.