Search Results for

    Show / Hide Table of Contents

    Class GraphicsPresenter

    Application graphics presenter.

    Inheritance
    object
    IdentifiableObject
    DependencyObject
    AttachableObject
    Service
    UpdatableService
    GraphicsPresenter
    Implements
    IDependencyObject
    Inherited Members
    AttachableObject.AttachableStateChanged
    AttachableObject.IsEnabled
    AttachableObject.State
    AttachableObject.IsLoaded
    AttachableObject.IsAttached
    AttachableObject.IsActivated
    AttachableObject.IsStarted
    AttachableObject.IsDestroyed
    AttachableObject.Destroy()
    DependencyObject.Dependencies
    DependencyObject.OnDependencyRemoved
    IdentifiableObject.Id
    Namespace: Evergine.Framework.Services
    Assembly: Evergine.Framework.dll
    Syntax
    public sealed class GraphicsPresenter : UpdatableService, IDependencyObject

    Constructors

    GraphicsPresenter()

    Initializes a new instance of the GraphicsPresenter class.

    Declaration
    public GraphicsPresenter()

    Fields

    Displays

    Gets the display settings of the application.

    Declaration
    public Dictionary<int, Display> Displays
    Field Value
    Type Description
    Dictionary<int, Display>

    Properties

    CopyCommandQueue

    Gets the Copy Command Queue.

    Declaration
    public CommandQueue CopyCommandQueue { get; }
    Property Value
    Type Description
    CommandQueue

    FocusedDisplay

    Gets or sets the currently focused display.

    Declaration
    public Display FocusedDisplay { get; set; }
    Property Value
    Type Description
    Display

    GraphicsCommandQueue

    Gets the graphics command queue.

    Declaration
    public CommandQueue GraphicsCommandQueue { get; }
    Property Value
    Type Description
    CommandQueue

    Methods

    AddDisplay(string, Display)

    Adds a new display.

    Declaration
    public int AddDisplay(string tag, Display display)
    Parameters
    Type Name Description
    string tag

    The tag to reference the display.

    Display display

    The new display.

    Returns
    Type Description
    int

    Returns the display ID assigned to this display.

    InitFrame()

    Initializes the frame to render on all displays.

    Declaration
    public void InitFrame()

    OnAttached()

    Invoked when the object is attached to the system.

    Declaration
    protected override bool OnAttached()
    Returns
    Type Description
    bool

    True if everything is OK.

    Overrides
    Service.OnAttached()

    OnDetach()

    Invoked when the object is detached.

    Declaration
    protected override void OnDetach()
    Overrides
    Service.OnDetach()

    Prepare()

    Prepares all displays to be drawn.

    Declaration
    public void Prepare()

    Present()

    Displays all active displays in the application.

    Declaration
    public void Present()

    RemoveDisplay(int)

    Removes display by id.

    Declaration
    public Display RemoveDisplay(int id)
    Parameters
    Type Name Description
    int id

    Display ID.

    Returns
    Type Description
    Display

    The removed Display instance. Null if there is no Display with the given ID.

    RemoveDisplay(string)

    Removes a display by tag.

    Declaration
    public Display RemoveDisplay(string tag)
    Parameters
    Type Name Description
    string tag

    The display tag.

    Returns
    Type Description
    Display

    The removed Display instance. Null if there is no Display with the given tag.

    TryGetDisplay(int, out Display)

    Gets the Display associated with the specified display index.

    Declaration
    public bool TryGetDisplay(int displayId, out Display display)
    Parameters
    Type Name Description
    int displayId

    Display ID.

    Display display

    The display to return.

    Returns
    Type Description
    bool

    True if the display exists; otherwise, false.

    TryGetDisplay(string, out Display)

    Gets the Display associated with the specified display index.

    Declaration
    public bool TryGetDisplay(string displayTag, out Display display)
    Parameters
    Type Name Description
    string displayTag

    Display tag.

    Display display

    Returned Display.

    Returns
    Type Description
    bool

    True if the display exists; otherwise, false.

    TryGetDisplayId(string, out int)

    Gets the display ID by its tag.

    Declaration
    public bool TryGetDisplayId(string displayTag, out int displayId)
    Parameters
    Type Name Description
    string displayTag

    The display tag.

    int displayId

    The display ID.

    Returns
    Type Description
    bool

    True if a display with this tag exists.

    Update(TimeSpan)

    Updates this instance.

    Declaration
    public override void Update(TimeSpan gameTime)
    Parameters
    Type Name Description
    TimeSpan gameTime

    The elapsed game time since the last update.

    Overrides
    UpdatableService.Update(TimeSpan)

    Events

    OnPresented

    Event fired when all displays have been presented.

    Declaration
    public event EventHandler OnPresented
    Event Type
    Type Description
    EventHandler

    Implements

    IDependencyObject

    Extension Methods

    ReflectionHelper.GetMemberAssembly(object)
    ReflectionHelper.GetTypeName(object)
    In this article
    Back to top
    Generated by DocFX