还原水插件

This commit is contained in:
2026-03-05 00:14:42 +08:00
parent 0de35591e7
commit e82f2ea6b7
270 changed files with 2773 additions and 12445 deletions

View File

@@ -20,9 +20,6 @@ namespace WaveHarmonic.Crest
readonly System.Action<CommandBuffer> _CopyColorTexture;
readonly System.Action<CommandBuffer> _SetRenderTargetToBackBuffers;
bool _AllocatedColor;
GraphicsFormat _GraphicsFormat;
public UnderwaterEffectPass(UnderwaterRenderer renderer)
{
_Renderer = renderer;
@@ -43,8 +40,6 @@ namespace WaveHarmonic.Crest
public void Allocate(GraphicsFormat format)
{
_GraphicsFormat = format;
if (_Renderer.RenderBeforeTransparency && !_Renderer._NeedsColorTexture)
{
return;
@@ -62,8 +57,6 @@ namespace WaveHarmonic.Crest
wrapMode: TextureWrapMode.Clamp,
name: "_Crest_UnderwaterCameraColorTexture"
);
_AllocatedColor = true;
}
public void ReAllocate(RenderTextureDescriptor descriptor)
@@ -92,11 +85,6 @@ namespace WaveHarmonic.Crest
if (!_Renderer.RenderBeforeTransparency || _Renderer._NeedsColorTexture)
{
if (!_AllocatedColor)
{
Allocate(_GraphicsFormat);
}
buffer.SetGlobalTexture(UnderwaterRenderer.ShaderIDs.s_CameraColorTexture, _ColorTexture);
}