{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Class PhysicsDebugDisplaySystem | Unity Physics | 1.1.0-pre.3
docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class PhysicsDebugDisplaySystem

    A system which is responsible for drawing physics debug display data. Create a singleton entity with PhysicsDebugDisplayData and select what you want to be drawn.

    If you want custom debug draw, you need to:

    1. Create a system which updates before PhysicsDebugDisplaySystem.
    2. In OnUpdate() of that system, call GetSingleton PhysicsDebugDisplayData (even if you are not using it, it is important to do so to properly chain dependencies).
    3. Afterwards, in OnUpdate() or in scheduled jobs, call one of the exposed draw methods (Line, Arrow, Plane, Triangle, Cone, Box, ...).
      IMPORTANT: Drawing works only in the Editor.
    Inheritance
    object
    ComponentSystemBase
    SystemBase
    PhysicsDebugDisplaySystem
    PhysicsDebugDisplaySystem_Default
    PhysicsDebugDisplaySystem_Editor
    Inherited Members
    SystemBase.CompleteDependency()
    SystemBase.Update()
    SystemBase.GetComponent<T>(Entity)
    SystemBase.SetComponent<T>(Entity, T)
    SystemBase.HasComponent<T>(Entity)
    SystemBase.HasBuffer<T>(Entity)
    SystemBase.GetComponentLookup<T>(bool)
    SystemBase.GetComponentDataFromEntity<T>(bool)
    SystemBase.GetBuffer<T>(Entity, bool)
    SystemBase.GetBufferLookup<T>(bool)
    SystemBase.GetBufferFromEntity<T>(bool)
    SystemBase.GetEntityStorageInfoLookup()
    SystemBase.GetStorageInfoFromEntity()
    SystemBase.Exists(Entity)
    SystemBase.Dependency
    SystemBase.CheckedStateRef
    SystemBase.Entities
    SystemBase.Job
    ComponentSystemBase.ShouldRunSystem()
    ComponentSystemBase.GetComponentTypeHandle<T>(bool)
    ComponentSystemBase.GetDynamicComponentTypeHandle(ComponentType)
    ComponentSystemBase.GetBufferTypeHandle<T>(bool)
    ComponentSystemBase.GetSharedComponentTypeHandle<T>()
    ComponentSystemBase.GetDynamicSharedComponentTypeHandle(ComponentType)
    ComponentSystemBase.GetEntityTypeHandle()
    ComponentSystemBase.RequireForUpdate(EntityQuery)
    ComponentSystemBase.RequireAnyForUpdate(params EntityQuery[])
    ComponentSystemBase.RequireAnyForUpdate(NativeArray<EntityQuery>)
    ComponentSystemBase.RequireForUpdate<T>()
    ComponentSystemBase.RequireSingletonForUpdate<T>()
    ComponentSystemBase.HasSingleton<T>()
    ComponentSystemBase.GetSingleton<T>()
    ComponentSystemBase.GetSingletonRW<T>()
    ComponentSystemBase.GetSingletonBuffer<T>(bool)
    ComponentSystemBase.TryGetSingleton<T>(out T)
    ComponentSystemBase.TryGetSingletonBuffer<T>(out DynamicBuffer<T>)
    ComponentSystemBase.SetSingleton<T>(T)
    ComponentSystemBase.GetSingletonEntity<T>()
    ComponentSystemBase.TryGetSingletonEntity<T>(out Entity)
    ComponentSystemBase.GetEntityQuery(params ComponentType[])
    ComponentSystemBase.GetEntityQuery(NativeArray<ComponentType>)
    ComponentSystemBase.GetEntityQuery(params EntityQueryDesc[])
    ComponentSystemBase.GetEntityQuery(in EntityQueryBuilder)
    ComponentSystemBase.Enabled
    ComponentSystemBase.EntityQueries
    ComponentSystemBase.GlobalSystemVersion
    ComponentSystemBase.LastSystemVersion
    ComponentSystemBase.EntityManager
    ComponentSystemBase.World
    ComponentSystemBase.SystemHandle
    ComponentSystemBase.SystemHandleUntyped
    ComponentSystemBase.Time
    ComponentSystemBase.WorldUpdateAllocator
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Unity.Physics.Authoring
    Assembly: solution.dll
    Syntax
    public abstract class PhysicsDebugDisplaySystem : SystemBase

    Methods

    Name Description
    Arc(float3, float3, float3, float, ColorIndex)

    Draws an arc.

    Arrow(float3, float3, ColorIndex)

    Draws an arrow.

    Box(float3, float3, quaternion, ColorIndex)

    Draws a box.

    Cone(float3, float3, float, ColorIndex)

    Draws a cone.

    Line(float3, float3, ColorIndex)

    Draws a line between 2 points.

    Lines(in NativeArray<float3>, ColorIndex)
    Lines(in NativeList<float3>, ColorIndex)
    Lines(float3*, int, ColorIndex)
    Plane(float3, float3, ColorIndex)

    Draws a plane.

    Point(float3, float, ColorIndex)

    Draws a point.

    TriangleEdges(in NativeArray<float3>, in NativeArray<int>, ColorIndex)
    Triangles(in NativeArray<float3>, in NativeArray<int>, ColorIndex)
    Triangles(in NativeArray<float3>, ColorIndex)
    Triangles(in NativeList<float3>, ColorIndex)
    Triangles(float3*, int, ColorIndex)
    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)