public static void Blit(ref RenderTexture main, ref RenderTexture swap, P3dBlendMode blendMode, Texture texture, Color color, float opacity, float minimum) { Instance.SetMaterial(blendMode, texture, color, opacity, minimum); Instance.Apply(main); P3dHelper.Blit(swap, Instance.Material); P3dHelper.Swap(ref main, ref swap); }
public static void Blit(ref RenderTexture main, ref RenderTexture swap, P3dBlendMode blendMode, Texture texture, Color color, float opacity, float minimum) { Instance.SetMaterial(blendMode, texture, color, opacity, minimum); Instance.Apply(); if (Instance.Double == true) { P3dCommandReplace.Blit(swap, main, Color.white); Instance.Material.SetTexture(P3dShader._Buffer, swap); Instance.Material.SetVector(P3dShader._BufferSize, new Vector2(swap.width, swap.height)); } P3dHelper.Blit(main, Instance.Material); }