"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
var BlueprintIGXCBuilder_1 = require("./BlueprintIGXCBuilder");
exports.createSceneFromBlueprint = function (_a) {
    var model = _a.model, builderParams = tslib_1.__rest(_a, ["model"]);
    var builder = new BlueprintIGXCBuilder_1.BlueprintIGXCBuilder(builderParams);
    var corners = model.floorplan.getCorners();
    corners.forEach(function (corner) { return builder.addCorner(corner); });
    var walls = model.floorplan.getWalls();
    walls.forEach(function (wall) {
        return builder.addWall(wall.getStart().id, wall.getEnd().id);
    });
    var rooms = model.floorplan.getRooms();
    rooms.forEach(function (room) {
        return builder.addRoom(room.corners.map(function (corner) { return corner.id; }));
    });
    return builder.build();
};
