API reference
API reference
Select your platform
No SDKs available
No versions available

AnchorPrefabGroup Struct

Extends IEquatable< AnchorPrefabGroup >
Represents a group of prefabs associated with specific scene labels, along with settings for how they should be spawned.
This struct encapsulates the necessary information for spawning prefabs based on anchor data.
When using ScalingMode.Custom, AlignMode.Custom, or SelectionMode.Custom the CustomPrefabScaling, CustomPrefabAlignment or CustomPrefabAlignment methods must be implemented in a custom class that extends either the AnchorPrfabSpawner or the ICustomPrefabAlignment interface directly.

Fields

Anchors to include.
Each anchor labeled with one of these labels will have a prefab spawned for it.
This list contains the prefabs that can be spawned for the specified labels.
The prefab will be chosen depending on the SelectionMode set for this group.
The logic that determines what prefab to choose when spawning the relative labels' game objects.
When enabled, the prefab will be rotated to try and match the aspect ratio of the volume as closely as possible.
This is most useful for long and thin volumes; keep this disabled for objects with an aspect ratio close to 1:1. Only applies to volumes.
When calculate facing direction is enabled, the prefab will be rotated to face away from the closest wall.
If match aspect ratio is also enabled, that will take precedence and it will be constrained to a choice between 2 directions only. Only applies to volumes.
Set what scaling mode to apply to the prefab.
By default, the prefab will be stretched to fit the size of the plane/volume. But in some cases, this may not be desirable and can be customized here.
Spawn new object at the center, top, or bottom of the anchor.
This setting determines the vertical alignment of the spawned prefab.
Don't analyze prefab, just assume a default scale of 1.
This setting simplifies the scaling process by using a default scale.
Did you find this page helpful?
Thumbs up icon
Thumbs down icon