[sldev] Packing alogrithm behind LAND_LAYER_CODE part of aLayerData message

Tleiades tleiades at hotmail.com
Wed Mar 14 14:05:04 PDT 2007


I decided that maybe I should try to tell what I have already figured out, and what hunches I have.

This specific subtype of the LayerData message starts with a GroupHeader,
containing a patch size, a stride and a repetition of the layer type. I haven't figured the exact purpose of the stride yet, but believe I have the other two fields pinned down.

Next follows a number of patches, each patch begins with a header. The only things in the header I have been able to determine is that quant_wbits (in part) encodes the size of the following numeric data, and that patchids seems to reference some sort of co-ordinate system.

Following the patch header is a bitpattern, which depending on bits turned on or off either idicates zero, negative or positive number, the size of the numbers are determined by the quant_wbits field. My guess is that the numbers are height encodings.

In short the message encodes a packed height field, but I really have no clue on how to combine the individual LayerData messages into a complete height map.

  ----- Original Message ----- 
  From: Tleiades 
  To: sldev at lists.secondlife.com 
  Sent: Wednesday, March 14, 2007 6:46 PM
  Subject: [sldev] Packing alogrithm behind LAND_LAYER_CODE part of aLayerData message


  Hi

  I've been trying to figure out the algorithm behind packing and decoding the LAND_LAYER_CODE part of a LayerData message. I'd like to get the broad picture of how that data is encoded, but I seem to get lost, not seeing the forest, because all the trees get in the way.

  Is there someone who can provide me with an overall picture of the algorithm or point me to some url's explaining the algorithm?




------------------------------------------------------------------------------


  _______________________________________________
  Click here to unsubscribe or manage your list subscription:
  /index.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.secondlife.com/pipermail/sldev/attachments/20070314/13954dac/attachment.htm


More information about the SLDev mailing list