Перейти к основному содержанию

Structure of the element geometric data bucket

Меньше 1 минуты

Structure of the element geometric data bucket

The bucket is stored as a byte array, packed by the LZMA algorithm.

After receiving and unpacking it contains text data in JSON markup.

The data is an array of objects with properties.

[
  {}, // Element 0
  {}, // Element 1
  ... // Element N
]

For ease of presentation, the structure of metadata in the article will be presented in the YAML markup.

The metadata of an individual element are basically represented as a set of mandatory and optional keys that make up the blocks.

BoundingBox: [] # Block of boundary properties
SubElements: [] # Block of subelements list

Boundary properties block

BoundingBox: [minX,minY,minZ,maxX,maxY,maxZ]

An object that contains the min and max point coordinates for bounding box of an element.

Block of subelements list

SubElements: [subEl1,subEl2,subElN...]

Object contains list of subelement indices for parent element. As a rule, subelements are parts of the parent element and at the same time independent elements. However, the parent element may not have its own geometry. The viewer uses this information to highlight all subelements when the parent element is selected.