Frequently Asked Questions
Missing GameObjects
Question
Data-Streaming is displaying geometry but there are no GameObjects in the scene. How do I access the streamed GameObjects?
Answer
Congratulations! You've managed to stream in your data, you see something, but
now you would like to interact with your scene. If you're a veteran Unity
developer, you're probably looking for GameObjects
. While the streaming
framework does generate GameObjects
, they are hidden by default and
shouldn't be referenced in any way unless you are trying to debug a specific
issue. These GameObjects
won't do you much good. They are highly optimized
batches triangles and no longer represent your original hierarchy. This allows
Data-Streaming
to be performant by default. However, you can still interact
with objects in your scene.
If you would like to perform simple actions such as selecting, hiding and
highlighting various Instances
in the scene, we would recommend you look into
using modifiers.
If you need to perform something more complex, you will need to use
modifiers to hide some instances in the streamed model
and, in addition, you'll want to use IModelStream.LoadGeometryAsync
to load
instances as GameObjects
that your application code will own and be able to
interact with.
If you want to see the GameObjects
for debugging purposes, you can do so by
toggling Edit > Display Data Streamer Game Object
in the Unity Editor. If you modify these objects in any way or rely on their structure, your code
will likely break with future updates of the streaming package.
Generating a Dataset Programatically
I am able to upload an asset to the Asset Manager, prepare it for streaming and view it. However, I'd like to perform this programmatically.
The asset manager can be manipulated through various SDKs, including the ability to upload and transform assets without using a web browser. In this instance, there are many ways of achieving the desired result and they will depend on the nature of your applications and the workflows you are implementing.
We would recommend exploring the following SDKs: