- Home /
AssetBundle: how the files are ordered?
I'd like to implement a binary delta to update AssetBundles with a diff algorithm, but this would assume that the files should not change their relative positions.
Reading from here (3.2):
The header contains information about the AssetBundle, such as its identifier, compression type, and a manifest. The manifest is a lookup table keyed by an Object's name. Each entry provides a byte index that indicates where a given Object can be found within the AssetBundle's data segment. On most platforms, this lookup table is implemented as a balanced search tree. Specifically, Windows and OSX-derived platforms (including iOS) employ a red-black tree. Therefore, the time needed to construct the manifest will increase more than linearly as the number of Assets within an AssetBundle grows.
but it says nothing on the order the files are saved in the data segment. If they are saved in the order they are encoded in the lookup table, and if they are indexed by their GUID, or their hash, they should not change in position at least when not changed, but they are very big "if" that are not documented (or at least I was not able to find the relative documentation).
Write a delta algorithm that supports reordering whould be a lot more complex, so I'd avoid it if I can.
Your answer
Follow this Question
Related Questions
How to import the object from server to unity 2 Answers
AssetDatabase.LoadAllAssetsAtPath(...) Yields Mysterious Nameless Asset 1 Answer
DontDestroyOnLoad() assetbundle 1 Answer
Streaming Tutorial anywhere? 2 Answers
Runtime loaded assemblies 1 Answer