Component reference
Scene Composition components
Variant component
5min
description the variant component allows you to assign multiple 3d models to a single entity and switch between them based on certain conditions, known as heuristics this is useful for implementing features like level of detail (lod), device specific models, or manual model switching through trigger component docid\ nb3gi taxvolfxip idtj requirements an entity with a model component is required the variant component works in conjunction with the model component properties property description heuristic determines the method used to select which model variant to display options include distance , scene scale , manual , device , and budget distance this option switches models based on the user's distance from the entity each variant has minimum and maximum distance parameters scene scale as of v1 0 of the platform, scene scale is not working as intended manual allows manual control of the displayed model through triggers or scripts device selects models based on the user's device type (e g , desktop, mobile, xr headset) budget automatically manages model quality based on the performance budget, adjusting models to maintain optimal frame rates (note may require further testing to ensure proper functionality ) variants a list of model variant sources , each with its own source url and parameters depending on the heuristic usage notes distance heuristic useful for implementing lod, where high detail models are used when the user is close, and lower detail models when farther away manual heuristic allows you to change models in response to user interactions or triggers within the scene device heuristic ideal for optimizing performance across different devices by providing appropriate model qualities for various devices budget heuristic automatically adjusts model variants based on system performance, which can help maintain a smooth user experience important details when using the distance heuristic, overlapping distance ranges can cause unexpected behavior ensure that the minimum distance and maximum distance values for variants do not overlap the budget heuristic is advanced and may require testing to ensure it works as expected in your scene