|
|
|
|
|
|
public TextureDimension textureDimension { get; private set; } |
|
|
|
|
|
|
|
protected List<ShaderPassName> m_ShaderPassNames = new List<ShaderPassName>(); |
|
|
|
|
|
|
|
|
|
|
|
int samples; |
|
|
|
|
|
|
|
public ScriptableRenderPass(LightweightForwardRenderer renderer) |
|
|
|
|
|
|
RenderBufferStoreAction colorStoreAction, ClearFlag clearFlag, Color clearColor) |
|
|
|
{ |
|
|
|
if (textureDimension == TextureDimension.Tex2DArray) |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachmentHandle, clearFlag, clearColor, 0, CubemapFace.Unknown, -1); |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachment, clearFlag, clearColor, 0, CubemapFace.Unknown, -1); |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachmentHandle, colorLoadAction, colorStoreAction, clearFlag, clearColor); |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachment, colorLoadAction, colorStoreAction, clearFlag, clearColor); |
|
|
|
} |
|
|
|
|
|
|
|
public void SetRenderTarget(CommandBuffer cmd, RenderTargetIdentifier colorAttachment, RenderBufferLoadAction colorLoadAction, |
|
|
|
|
|
|
if (textureDimension == TextureDimension.Tex2DArray) |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachmentHandle, depthAttachmentHandle, |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachment, depthAttachment, |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachmentHandle, colorLoadAction, colorStoreAction, |
|
|
|
depthAttachmentHandle, depthLoadAction, depthStoreAction, clearFlag, clearColor); |
|
|
|
CoreUtils.SetRenderTarget(cmd, colorAttachment, colorLoadAction, colorStoreAction, |
|
|
|
depthAttachment, depthLoadAction, depthStoreAction, clearFlag, clearColor); |
|
|
|
} |
|
|
|
} |
|
|
|
} |