Difference between revisions of "LayerData"
Jump to navigation
Jump to search
Cube Linden (talk | contribs) m |
|||
Line 1: | Line 1: | ||
{{ProtocolNav}} | {{ProtocolNav}} | ||
==Message Layout== | ==Message Layout== | ||
Line 18: | Line 17: | ||
</pre> | </pre> | ||
==Usage and Notes== | ==Usage and Notes== | ||
LayerData packets transmit terrain, wind, and cloud information using a custom IDCT routine similar to JPEG but with different coefficients. The data in these packets is stored in a proprietary format of 16x16 meter blocks that has been partially reverse engineered. | |||
Type: | |||
- 76 : LLSurface (terrain) | |||
- 55 : LLWind (wind) | |||
- 56 : LLCloudLayer (Cloud) | |||
Data: | |||
:[patchgroupSize] - uint8 | |||
:[unk] - uint8 | |||
:[patchHeader] | |||
::[patchSize] - uint8 | |||
::[unknown0] - uint32 | |||
::[unknown1] - uin16 | |||
::[unknown2] - 10 bit unsigned integer | |||
:[patchData] | |||
::[zeroCode] - One bit. If 0, the data is zerocoded | |||
::[hasData] - One bit, If 0, the entire patch is zeros. | |||
::[data] - has a size of (patchSize % 16) + 2 | |||
::[data] ... - repeat until patchSize has been read | |||
:[patchHeader] ... - repeat until patchgroupSize has been read | |||
::... | |||
The data then has to be decompressed, and I have no idea how this data is used. | |||
You may find some use from the psuedocode at [http://www.libsecondlife.org/wiki/LayerData LibSecondLife.org] | |||
[[Category:Messages]] | [[Category:Messages]] |
Revision as of 07:50, 29 March 2008
Message Layout
{ LayerData High Trusted Unencoded { LayerID Single { Type U8 } } { LayerData Single { Data Variable 2 } } }
Usage and Notes
LayerData packets transmit terrain, wind, and cloud information using a custom IDCT routine similar to JPEG but with different coefficients. The data in these packets is stored in a proprietary format of 16x16 meter blocks that has been partially reverse engineered.
Type:
- 76 : LLSurface (terrain) - 55 : LLWind (wind) - 56 : LLCloudLayer (Cloud)
Data:
- [patchgroupSize] - uint8
- [unk] - uint8
- [patchHeader]
- [patchSize] - uint8
- [unknown0] - uint32
- [unknown1] - uin16
- [unknown2] - 10 bit unsigned integer
- [patchData]
- [zeroCode] - One bit. If 0, the data is zerocoded
- [hasData] - One bit, If 0, the entire patch is zeros.
- [data] - has a size of (patchSize % 16) + 2
- [data] ... - repeat until patchSize has been read
- [patchHeader] ... - repeat until patchgroupSize has been read
- ...
The data then has to be decompressed, and I have no idea how this data is used.
You may find some use from the psuedocode at LibSecondLife.org