[G3][100] Formöffnungen (Rundbogen, Segment-/Spitzbogen, rund, schräg, Giebel) und Dachfenster/Deckenöffnungen

[G3] Opening.shape + shapeRise (Rust-Modell, Typen generiert). Kern opening_shape.rs: konvexer Umriss
im Öffnungsrechteck; Wand behält das Rechteck-Loch, Füllkörper (Streifen-Quader) schliessen den Rest.
Schnitt: Wandband bis an den Umriss, Rahmen/Glas auf lichter Höhe, kein Sturz/Storenkasten bei Formen.
Ansicht: Rahmen als Umriss, Glas eingerückt, Wandrest in Wandfarbe. 3D: Rahmen-Ring, Glas/Türblatt entlang
des Umrisses. IFC: neuer Datensatz OPENING_SOLID (Profil-Extrusion quer durch die Wand, Füllung als Netz).
Dialog „Fenster bearbeiten": Form + Stich.

[100] Öffnungen mit Wirt Dach/Decke: hostRoofId/hostCeilingId, hostPoint, hostAngle. Dachfenster schneiden
alle Dachschichten (3D dicht, Live-Schnitt, Schnitt), Rahmen/Glas/Eindeckrahmen, Grundriss gestrichelt,
Ansicht, IFC (IfcOpeningElement im IfcRoof/IfcSlab + IfcWindow). Deckenöffnungen als Aussparung.
Befehl „Dachfenster" (roofwindow). Beide Teile teilen opening_shape.rs und den IFC-Datensatz, daher ein Commit.
This commit is contained in:
Claude committed 2026-10-29 23:58:52 +00:00
1 parent a385997282
commit 38d5f9505a
21 files changed
+1805 -65

No files matched your search

+35
View File
@@ -0,0 +1,35 @@
// Dachfenster ([100]) als Engine-Befehl: ein Klick setzt ein Fenster (78 × 118 cm, in der Dachebene
// gemessen) mit seiner Mitte an den Punkt — in das Dach, dessen Umriss den Punkt enthält (Dächer des
// aktiven Geschosses zuerst), sonst als Oberlicht in die Decke des Geschosses. Die Öffnung schneidet
// alle Schichten (Kern: `cmd_solid.rs::roof_window_ops`, Geometrie `opening_shape.rs`).
import { createMutation } from "../createCore";
import type { Command, CommandResult, CommandState } from "../types";
const idle = (): [CommandState, CommandResult] => [{ phase: "start", lastPoint: null }, { draft: null, done: true }];
export const roofWindowCommand: Command = {
name: "roofwindow",
labelKey: "cmd.roofWindow.label",
floorOnly: true,
prompt: () => "cmd.roofWindow.start",
accepts: () => ["point"],
options: () => [],
init: (): CommandState => ({ phase: "start", lastPoint: null }),
onInput: (state, input, ctx): [CommandState, CommandResult] => {
if (input.kind !== "point") return [state, { draft: null }];
return [
{ phase: "start", lastPoint: input.point },
{ draft: null, commit: createMutation(ctx, { cmd: "roofWindow", p: input.point }) },
];
},
onMove: (state, point): [CommandState, CommandResult] => [
state,
{ draft: { preview: [{ kind: "poly", pts: [point], closed: false }], vertices: [point] } },
],
onConfirm: (): [CommandState, CommandResult] => idle(),
onCancel: (): [CommandState, CommandResult] => idle(),
};