void UpdateSimpleCommandBuffer() { if (cam == null || simpleCB == null) { return; } else if (initSimpleCB) { CommonSet.ClearCommandBuffer(cam, ref simpleCB, CameraEvent.BeforeImageEffects); cam.AddCommandBuffer(CameraEvent.BeforeImageEffects, simpleCB); PrepareSimpleCB(simpleCB); initSimpleCB = false; } }
void UpdateOpaqueCommandBuffer() { if (cam == null || opaqueCB == null) { return; } else if (initOpaqueCB) { CommonSet.ClearCommandBuffer(cam, ref opaqueCB, CameraEvent.BeforeForwardAlpha); cam.AddCommandBuffer(CameraEvent.BeforeForwardAlpha, opaqueCB); PrepareOpaqueCB(opaqueCB); initOpaqueCB = false; } }
void OnDisable() { CommonSet.ClearCommandBuffer(cam, ref opaqueCB, CameraEvent.BeforeForwardAlpha); }
void OnDisable() { CommonSet.ClearCommandBuffer(cam, ref simpleCB, CameraEvent.BeforeImageEffects); }