Stride

OPEN / CLOSE
  • Features
  • Blog
  • Documentation
  • Community
(icon) Download

  • Discord
  • Facebook
  • Twitter
  • YouTube

LANGUAGE

OPEN / CLOSE
  • English
  • 日本語
    Show / Hide Table of Contents

    BokehBlur Class

    Namespace: Stride.Rendering.Images
    Assembly: Stride.Rendering.dll

    This class represents a blur to apply to a texture to create a bokeh effect. It's not supposed to be used as-is, rather you should use subclasses like GaussianBokeh, McIntoshBokeh or TripleRhombiBokeh... which do actually implement a blur technique leading to a particular bokeh shape (circular, hexagonal).

    System.Object → DisposeBase → ComponentBase → RendererCoreBase → RendererBase → DrawEffect → ImageEffect → BokehBlur
    Derived from BokehBlur: GaussianBokeh McIntoshBokeh TripleRhombiBokeh

    public abstract class BokehBlur : ImageEffect, IComponent, IReferencable, ICollectorHolder, IImageEffect, IGraphicsRenderer, IGraphicsRendererBase, IGraphicsRendererCore, IDisposable
    Name Description
    Constructors
    BokehBlur()

    Initializes a new instance of the BokehBlur class.

    Properties
    CoCStrength
    Radius

    Sets the radius of the blur. A child class can override it to do special processing when a new value is provided.

    Methods
    SetColorDepthInput(Texture, Texture)

    Provides a color buffer and a depth buffer to apply the blur to.

    | Improve this Doc View Source

    Constructors


    BokehBlur()

    Initializes a new instance of the BokehBlur class.

    protected BokehBlur()
    | Improve this Doc View Source

    Properties


    CoCStrength

    public float CoCStrength { get; set; }
    Property Value
    Type Description
    System.Single

    Radius

    Sets the radius of the blur. A child class can override it to do special processing when a new value is provided.

    public virtual float Radius { get; set; }
    Property Value
    Type Description
    System.Single
    | Improve this Doc View Source

    Methods


    SetColorDepthInput(Texture, Texture)

    Provides a color buffer and a depth buffer to apply the blur to.

    public void SetColorDepthInput(Texture colorBuffer, Texture depthBuffer)
    Parameters
    Type Name Description
    Texture colorBuffer

    A color buffer to process.

    Texture depthBuffer

    The depth buffer corresponding to the color buffer provided.


    Inherited Members

    ImageEffect.EnableSetRenderTargets
    ImageEffect.SetInput(Int32, Texture)
    ImageEffect.Reset()
    ImageEffect.SetOutput(Texture)
    ImageEffect.SetOutput(Texture[])
    ImageEffect.SetDepthOutput(Texture, Texture)
    ImageEffect.SetDepthOutput(Texture, Texture[])
    ImageEffect.SetViewport(Nullable<Viewport>)
    ImageEffect.PreDrawCore(RenderDrawContext)
    ImageEffect.SetRenderTargets(RenderDrawContext)
    ImageEffect.PostDrawCore(RenderDrawContext)
    ImageEffect.DisposeCreatedRenderTargetViews(RenderDrawContext)
    ImageEffect.InputCount
    ImageEffect.GetInput(Int32)
    ImageEffect.GetSafeInput(Int32)
    ImageEffect.DepthStencil
    ImageEffect.HasDepthStencilOutput
    ImageEffect.OutputCount
    ImageEffect.GetOutput(Int32)
    ImageEffect.GetSafeOutput(Int32)
    ImageEffect.NewScopedRenderTarget2D(TextureDescription)
    ImageEffect.NewScopedRenderTarget2D(Int32, Int32, PixelFormat, TextureFlags, Int32)
    ImageEffect.NewScopedRenderTarget2D(Int32, Int32, PixelFormat, MipMapCount, TextureFlags, Int32)
    DrawEffect.SamplingPattern
    DrawEffect.Parameters
    DrawEffect.Scaler
    DrawEffect.SetDefaultParameters()
    DrawEffect.Draw(RenderDrawContext, String)
    DrawEffect.Draw(RenderDrawContext, String, Object[])
    DrawEffect.ToString()
    RendererBase.DrawCore(RenderDrawContext)
    RendererBase.Draw(RenderDrawContext)
    RendererCoreBase.Enabled
    RendererCoreBase.Profiling
    RendererCoreBase.ProfilingKey
    RendererCoreBase.Context
    RendererCoreBase.Services
    RendererCoreBase.Content
    RendererCoreBase.GraphicsDevice
    RendererCoreBase.EffectSystem
    RendererCoreBase.Initialized
    RendererCoreBase.Initialize(RenderContext)
    RendererCoreBase.InitializeCore()
    RendererCoreBase.Unload()
    RendererCoreBase.NewScopedBuffer(BufferDescription, PixelFormat)
    RendererCoreBase.NewScopedTypedBuffer(Int32, PixelFormat, Boolean, GraphicsResourceUsage)
    RendererCoreBase.PushScopedResource<T>(T)
    RendererCoreBase.CheckIsInDrawCore()
    RendererCoreBase.Destroy()
    RendererCoreBase.ToLoadAndUnload<T>(T)
    RendererCoreBase.PreDrawCoreInternal(RenderDrawContext)
    RendererCoreBase.EnsureContext(RenderContext)
    RendererCoreBase.PostDrawCoreInternal(RenderDrawContext)
    ComponentBase.Tags
    ComponentBase.Name
    ComponentBase.ICollectorHolder.Collector
    ComponentBase.OnNameChanged()
    DisposeBase.Dispose()
    DisposeBase.IsDisposed
    DisposeBase.IReferencable.ReferenceCount
    DisposeBase.IReferencable.AddReference()
    DisposeBase.IReferencable.Release()
    DisposeBase.OnAddReference()
    DisposeBase.OnReleaseReference()

    Extension Methods

    ComponentBaseExtensions.DisposeBy<T>(T, ICollectorHolder)
    ComponentBaseExtensions.RemoveDisposeBy<T>(T, ICollectorHolder)
    ImageEffectExtensions.SetInput(IImageEffect, Texture)
    ImageEffectExtensions.SetInput(IImageEffect, Texture, Texture)
    ImageEffectExtensions.SetInput(IImageEffect, Texture, Texture, Texture)
    • Improve this Doc
    • View Source
    In This Article

    Back to top

    Copyright © 2019-2021 .NET Foundation and Contributors
    Supported by the .NET Foundation