/// <summary> /// Mark resource group as used during this frame. /// </summary> /// <returns>True if state changed (object was not mark as used during this frame until now), otherwise false.</returns> public bool MarkAsUsed(RenderSystem renderSystem) { return(Interlocked.Exchange(ref LastFrameUsed, renderSystem.FrameCounter) != renderSystem.FrameCounter); }
public bool IsUsedDuringThisFrame(RenderSystem renderSystem) { return(LastFrameUsed == renderSystem.FrameCounter); }