Skip to main content
Version: Pre-Released

Configure the Measurement Service

This section describes how to configure and customize the application to take benefit of the Measurement Service. The Measurement Service allows the user to initialize the walls and room dimensions of his project with the result of a measurement done in real life and available in another online system.

 

Integration

The first Step is to enable the menu item "Use Measure Service" in Step Floorplan in menu "Initiate plan". It has to be activated through the parameter floorPlanImport.planMeasure in the application distribution.

Once activated, click on "Use Measure Service" menu item triggers the Iframe message MeasuringServiceButtonClicked. The integration developer uses this Iframe message to display a pop in in which the end-user can select a measured floorplan. The measured floorplan has to be available online because the business logic has to select it, load it, convert it to the expected JSON format and sent it to the planner.

Once selected and converted the measured floorplan has to be sent to the planner with the Iframe message MeasureServiceImport. The JSON object transmitted must respect the format specified below. Even if the format allows the description of multiple levels, the kitchen planner uses the first level to initialize the walls and openings of the project. The end-user can then start designing the kitchen with the measured floorplan imported.

Floor Layout Format

Foreword

This document describes the different parameters to provide in the json export to get the room measurement service. (All the measurements are in mm).

Available parameters

Version
KeyMandatoryValue TypeDescription
versionYESintegerThe document version
Level array

The array of levels of the project.

KeyMandatoryValue TypeDescription
levelNameYESstringThe level name
wallHeightYESfloatThe level wallHeight value
roomsYESarrayThe rooms of the level
Room array

The rooms of the level.

KeyMandatoryValue TypeDescription
roomNameYESstringThe name of the room
wallsYESarrayThe wall array
Wall array

The array of walls of the project (must be a closed room without intersecting segments).

KeyMandatoryValue TypeDescription
wallHeightNOfloatThe height of the wall if not defined we take the project wallHeight into account
pt1YESarrayArray of two spatial coordinates
pt2YESarrayArray of two spatial coordinates
baysNOarrayCan be empty
swNOarrayArray of baseheight and depth for sloped wall
2D Points for the wall array

The two 2D points of each wall.

KeyMandatoryValue TypeDescription
xYESfloatX spatial coordinates
yYESfloatY spatial coordinates
Parameters for the bay array

The information needed to reconstruct the bays.

KeyMandatoryValue TypeDescription
distanceFromPt1YESfloatThe distance between the first point of the bay and pt1 of the wall
altitudeYESfloatThe altitude between the floor and the bay
widthYESfloatThe width of the bay
heightYESfloatThe height of the bay
typeYESstringThe shape of the bay ("rectangle") (Not supported for now: "arch" and "round")
idYESintegerThe dbID of the bay to draw in the planner

Scheme for distFromPt1: Scheme for distFromPt1

Scheme for bay types: Scheme for bay types

Scheme for altitude, width and height of a rectangle bay: Scheme for altitude

Parameters for the sw array

The information needed to reconstruct the sloped walls.

KeyMandatoryValue TypeDescription
baseheightYESintegerThe height of the wall from the floor, where the sloped ceiling is located
depthYESintegerThe distance between the start of the sloped ceiling and the smallest height of the wall
Parameters for the products array

The information needed to reconstruct the products (gas items, ventilation items, electric items, room objects and water supply items).

KeyMandatoryValue TypeDescription
widthYESfloatThe width of the product
heightYESfloatThe height of the product
depthYESfloatThe depth of the product
idYESstringThe dbID of the product to draw in the planner
positionYESobjectThe position (X and Y spatial coordinates) of the product to draw in the planner
orientationYESfloatThe orientation of the product to draw in the planner (counter clockwise angle from X)

Sample

Here is provided a sample of the complete parameters JSON object:

{
"version": 0,
"levels":
[
{
"levelName": "level0",
"wallHeight": 2500,
"rooms": [
{
"roomName": "kitchen",
"walls": [
{
"pt1": {
"x": 0,
"y": 0
},
"pt2": {
"x": 0,
"y": 5000.5
},
"sw": [
{
"baseheight": 1300,
"depth": 1400
}
]
},
{
"pt1": {
"x": 0,
"y": 5000.5
},
"pt2": {
"x": 4000,
"y": 5000
},
"sw": [
{
"baseheight": 1100,
"depth": 1300
}
]
},
{
"pt1": {
"x": 4000,
"y": 5000
},
"pt2": {
"x": 6000,
"y": 4000
}
},
{
"pt1": {
"x": 6000,
"y": 4000
},
"pt2": {
"x": 4000,
"y": 0
},
"bays": [
{
"distanceFromPt1": 1000,
"altitude": 1000,
"width": 1200,
"height": 1000,
"type": "rectangle",
"id": 4840
}
]
},
{
"pt1": {
"x": 4000,
"y": 0
},
"pt2": {
"x": 1500,
"y": 1000
},
"bays": [
{
"distanceFromPt1": 300,
"altitude": 0,
"width": 1200,
"height": 2000,
"type": "rectangle",
"id": 4840
}
]
},
{
"pt1": {
"x": 1500,
"y": 1000
},
"pt2": {
"x": 0,
"y": 0
}
}
],
"products": [
{
"height": 1000,
"depth": 80,
"id": "9623",
"width": 1200,
"position": {
"x": 39.999961853027344,
"y": 1381.6307373046875,
"z": 0
},
"orientation": 1.5707963267948966
},
{
"height": 100,
"depth": 5,
"id": "2784",
"width": 100,
"position": {
"x": 2.4999983310699463,
"y": 445.74688720703125,
"z": 1200
},
"orientation": 1.5707963267948966
}
]
}
]
}
]
}