Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using filters in Cesium #983

Closed
rickklooster opened this issue May 23, 2019 · 2 comments
Closed

Using filters in Cesium #983

rickklooster opened this issue May 23, 2019 · 2 comments

Comments

@rickklooster
Copy link

We are experimenting with using the Cesium connection to display BIM models in Cesium. It already kind of works (check https://3drotterdam.nl/ruggedised/#/ & turn on 'Zwembad' & 'Kunstenpand'), but since these are the full models it's quite heavy.

Schermafbeelding 2019-05-22 om 22 19 48

Is there more information on how the filters work on the cesium to select just certain content from the BIM server? Hope this way we can scale it down a little ;)

@rubendel
Copy link
Member

There are a few ways to query less geometry, all of them are based on leaving out certain objects. BIMserver has no notion of LOD at the moment.

As a base line, this will get you all objects:

{
  "type": {
    "name": "IfcProduct",
    "includeAllSubTypes": true
  }
}

To only get certain types (IfcWall has includeAllSubTypes enabled because it has a few subtypes like IfcWallStandardCase):

{
  "types": [{
    "name": "IfcWall",
    "includeAllSubTypes": true
  }, {
    "name": "IfcSlab"
  }, {
    "name": "IfcRoof"
  }]
}

Obviously, selecting on the types is not always a good fit. Some authoring tools export all objects in a model as the same type (usually IfcProxy or IfcBuildingElementProxy).

The following query will only give you objects with a given "density" [0]. Basically what you do here is you query for the root tile (BIMserver uses tiles as well) of a virtual octree with depth=0 (a complicated way of saying, the whole model). In this case all objects with a density between 0 and 10 are returned. You can tweak the numbers of course.

{
  "type": {
    "name": "IfcProduct",
    "includeAllSubTypes": true
  },
  "tiles": {
    "ids": [0],
    "densityLowerThreshold": 10,
    "densityUpperThreshold": 0,
    "maxDepth": 0
  }
}

[0] In BIMserver, density is currently defined as: "The amount of triangles an object has, divided by the area (in m2) of the largest face of the axis aligned bounding box of the object". The rationale behind this is actually a good fit for your use case, since it's a tradeoff between size (in bytes) and as how many pixels objects are potentially going to show up in a viewer.

@sergeiknysh
Copy link

@rickklooster let me know please did you succeed whith this approach from @rubendel ?
I try to solve the same problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants