pub unsafe extern "C" fn PxSerializationContext_registerReference_mut(
    self_: *mut PxSerializationContext,
    base: *mut PxBase,
    kind: u32,
    reference: usize
)
Expand description

Registers a reference value corresponding to a PxBase object.

This method is assumed to be called in the implementation of PxSerializer::registerReferences for serialized references that need to be resolved on deserialization.

A reference needs to be associated with exactly one PxBase object in either the collection or the external references collection.

Different kinds of references are supported and need to be specified. In the most common case (PX_SERIAL_REF_KIND_PXBASE) the PxBase object matches the reference value (which is the pointer to the PxBase object). Integer references maybe registered as well (used for internal material indices with PX_SERIAL_REF_KIND_MATERIAL_IDX). Other kinds could be added with the restriction that for pointer types the kind value needs to be marked with the PX_SERIAL_REF_KIND_PTR_TYPE_BIT.