Search Unity

  1. Unity 2020 LTS & Unity 2021.1 have been released.
    Dismiss Notice

Feedback Expose Unity's native component data (or header files) for use with DOTS/Burst

Discussion in 'Burst' started by TFlippy, Jul 14, 2020.

  1. TFlippy


    Nov 12, 2014
    Would it be possible to expose the native underlying structs for the Unity components (e.g. Transform, RigidBody2D, Collider2D, Joint2D) to be used with unsafe/unmanaged code (such as DOTS and Burst jobs)?

    I often have ECS components and Unity's components interacting with eachother, but due to the latter being a managed wrapper, I can't easily use it with Burst - for example, I'd like to read Transform's position inside a Burst job, but for that, I need to use a rather ugly workaround by using the native pointer to Transform's data and offset it to match the cached local position.

    (Also, please don't suggest the TransformAccessArray thing - it's slow and clumsy to work with.)