public override void Create() { ShaderProperties.Init(32); //hack for now blurAlgorithm = new ScalableBlur(); pass = new TranslucentImageBlurRenderPass(); tisCache.Clear(); }
public override void Create() { ShaderId.Init(32); //hack for now blurAlgorithm = new ScalableBlur(); pass = new TranslucentImageBlurRenderPass(); pass.renderPassEvent = RenderPassEvent.AfterRendering; tisCache.Clear(); }
void InitializeBlurAlgorithm() { switch (blurAlgorithmSelection) { case BlurAlgorithmType.ScalableBlur: blurAlgorithm = new ScalableBlur(); break; default: throw new ArgumentOutOfRangeException("BlurAlgorithmSelection"); } blurAlgorithm.Init(BlurConfig); }
public BlockingBlurController(View blurView, View rootView, Color overlayColor) { _blurView = blurView ?? throw new ArgumentNullException(nameof(blurView)); _rootView = rootView ?? throw new ArgumentNullException(nameof(rootView)); _overlayColor = overlayColor; _blurAlgorithm = new NoOpBlurAlgorithm(); int measuredWidth = blurView.MeasuredWidth; int measuredHeight = blurView.MeasuredHeight; if (IsZeroSized(measuredWidth, measuredHeight)) { DeferBitmapCreation(); return; } Init(measuredWidth, measuredHeight); }
protected override void Dispose(bool disposing) { if (!_disposed) { _disposed = true; if (disposing) { SetBlurAutoUpdateInternal(false); if (_blurAlgorithm != null) { _blurAlgorithm.Dispose(); _blurAlgorithm = null; } if (_internalBitmap != null) { _internalBitmap.Recycle(); _internalBitmap = null; } } } base.Dispose(disposing); }
public IBlurViewFacade SetBlurAlgorithm(IBlurAlgorithm algorithm) { _blurAlgorithm = algorithm; return(this); }
public BlurEffect(IBlurAlgorithm blurAlgorithm) { this.blurAlgorithm = blurAlgorithm; }