ArTrack

External data recording.

Summary

Typedefs

ArTrack typedef
struct ArTrack_
A track recording configuration struct of type data.

Functions

ArTrack_create(const ArSession *session, ArTrack **out_track)
void
Initializes an ArTrack.
ArTrack_destroy(ArTrack *track)
void
Releases memory used by the provided data track config object.
ArTrack_setId(const ArSession *session, ArTrack *track, const uint8_t *track_id_uuid_16)
void
Sets the Track Id.
ArTrack_setMetadata(const ArSession *session, ArTrack *track, const uint8_t *track_metadata_buffer, size_t track_metadata_buffer_size)
void
Sets the Track Metadata.
ArTrack_setMimeType(const ArSession *session, ArTrack *track, const char *mime_type)
void
Sets the MIME type for the Data Track.

Typedefs

ArTrack

struct ArTrack_ ArTrack

A track recording configuration struct of type data.

(value type).

Functions

ArTrack_create

void ArTrack_create(
  const ArSession *session,
  ArTrack **out_track
)

Initializes an ArTrack.

Details
Parameters
session
The ARCore session
out_track
Pointer to an ArTrack to receive the address of the newly allocated ArTrack

ArTrack_destroy

void ArTrack_destroy(
  ArTrack *track
)

Releases memory used by the provided data track config object.

Details
Parameters
track
The track config object to release

ArTrack_setId

void ArTrack_setId(
  const ArSession *session,
  ArTrack *track,
  const uint8_t *track_id_uuid_16
)

Sets the Track Id.

Details
Parameters
session
The ARCore session
track
The track object to change
track_id_uuid_16
The track ID as UUID as a byte array of 16 bytes in size

ArTrack_setMetadata

void ArTrack_setMetadata(
  const ArSession *session,
  ArTrack *track,
  const uint8_t *track_metadata_buffer,
  size_t track_metadata_buffer_size
)

Sets the Track Metadata.

Details
Parameters
session
The ARCore session
track
The external track object to change
track_metadata_buffer
bytes describing arbitrary data about the track.
track_metadata_buffer_size
size of the track_metadata_buffer

ArTrack_setMimeType

void ArTrack_setMimeType(
  const ArSession *session,
  ArTrack *track,
  const char *mime_type
)

Sets the MIME type for the Data Track.

Default value is "application/text".

Details
Parameters
session
The ARCore session
track
The track object to change
mime_type
The string representing the MIME type label as a null-terminated string in UTF-8 format. This will be the MIME type set on the additional stream created for this ArTrack, another convenient means of identification, particularly for applications that do not support UUID as a means of identification.