public bool TryGetGraphicsPipeline(ref PipelineUid key, out Auto <DisposablePipeline> pipeline) { if (_graphicsPipelineCache == null) { pipeline = default; return(false); } return(_graphicsPipelineCache.TryGetValue(ref key, out pipeline)); }
public bool TryGetGraphicsPipeline(ref PipelineUid key, out Auto <DisposablePipeline> pipeline) { if (_graphicsPipelineCache == null) { pipeline = default; return(false); } if (!_graphicsPipelineCache.TryGetValue(ref key, out pipeline)) { if (_firstBackgroundUse) { Logger.Warning?.Print(LogClass.Gpu, "Background pipeline compile missed on draw - incorrect pipeline state?"); _firstBackgroundUse = false; } return(false); } _firstBackgroundUse = false; return(true); }
public void AddGraphicsPipeline(ref PipelineUid key, Auto <DisposablePipeline> pipeline) { (_graphicsPipelineCache ??= new()).Add(ref key, pipeline); }