Class ProfilerEventUtility

The ProfilerWindowNativeHelper class contains some simple helper methods meant to offload few of the most performance-heavy code sections to native code, mostly to prevent exaggerative interop.

Hierarchy

  • FrameworkObject
    • ProfilerEventUtility

Constructors

  • Plain constructor allowing to instantiate the class from TypeScript code in order to allow caching of resources.

    Parameters

    • OptionalisInternalConstructor: boolean

    Returns ProfilerEventUtility

Methods

  • Creates flamegraph canvas elements for all given event samples. The elements are added as children into the given parent canvas element on position affected by origin time.

    Parameters

    • indexEventSamples: ProfilerIndexEventSample[]

      Vector of event samples to create canvas elements for.

    • threadIdentifier: number

      Only event samples belonging to given thread will be processed, ignoring all event samples from other threads.

    • parentElement: Canvas2DElement

      Canvas element to be used as parent for created canvas elements.

    • originNanoseconds: number

      Time of values that are places in the origin of the parentElement.

    • flags: EnumValue<ProfilerFlamegraphFlags, number>

      Describe state of the flamegraph entry with which it should be regenerated, allowing for selection and other highlights.

    Returns void

  • Creates flamegraph canvas elements for all given event samples. The elements are added as children into the given parent canvas element on position affected by origin time.

    Parameters

    • indexEventSample: ProfilerIndexEventSample

      Vector of event samples to create canvas elements for.

    • parentElement: Canvas2DElement

      Canvas element to be used as parent for created canvas elements.

    • originNanoseconds: number

      Time of values that are places in the origin of the parentElement.

    • flags: EnumValue<ProfilerFlamegraphFlags, number>

      Describe state of the flamegraph entry with which it should be regenerated, allowing for selection and other highlights.

    Returns void

  • Generates a UI that displays times of all event samples belonging to given event, typically sorted.

    Parameters

    • state: ProfilerState

      Profiler state to be reflected in the output listing.

    • indexEvent: ProfilerIndexEvent

      Event that is being inspected, so all of its samples will be listed.

    • layout: UILayout

      Vertical layout that should be appended with labels.

    Returns void