Search Unity

Texture Streaming + Scenes in Asset Bundle

Discussion in 'General Graphics' started by BlitWorks, Oct 28, 2020.

  1. BlitWorks

    BlitWorks

    Joined:
    Jan 12, 2016
    Posts:
    14
    Hello,

    We have the following setup:

    - Unity 2018.4.28f1.
    - Project that uses Unity's Texture Streaming system.
    - Asset Bundle that includes several scenes (and their dependencies: textures with Streaming Mip Maps enabled), using Chunk Compression.

    We load the Asset Bundle, then load the scene and see that the dependent textures that are loaded with it do not use the Texture Streaming system.
    Meanwhile, if we modify the project to not use the Scenes Asset Bundle and instead include the scene in the Build and load this scene we see that textures properly use the Texture Streaming system.

    This issue is also reproducible if you modify Unity's Vikings Village project, include its scene in an Asset Bundle and load it from there.

    For the record:
    We load Asset Bundles using AssetBundle.LoadFromFileAsync and do not Unload them.

    - Is this a known issue / limitation?
    - If not, how do we configure Scene Asset Bundles for the included textures to use the Streaming System?

    Thanks!
     
  2. BartPieters

    BartPieters

    Unity Technologies

    Joined:
    Apr 12, 2019
    Posts:
    25
    Hi!

    I think you need the new Scriptable Build Pipeline to have streaming working with textures in a 'scene Assetbundle'. Alternatively, putting your streamable textures in a separate Assetbundle (so without scenes), should also work.
     
  3. BlitWorks

    BlitWorks

    Joined:
    Jan 12, 2016
    Posts:
    14
    Hello,

    Thanks BartPieters.

    I can confirm that using the Scriptable Build Pipeline, streaming works with textures loaded from a 'scenes Asset Bundle'.
     
    BartPieters likes this.