Commit Graph

5 Commits

Author SHA1 Message Date
minsung
0e4701de79 Sprint 36~39 — IFC Alignment/Camber + proc-macro 스캐폴딩 + 변단면 거더
## Sprint 36: IfcAlignment (IFC Phase 3b)
- write_straight_alignment(): 직선 horizontal(.LINE.) + 평지
  vertical(.CONSTANTGRADIENT.) 세그먼트 + IfcRelNests 계층.
- IfcAlignmentSegment × IfcAlignmentHorizontalSegment × IfcAlignmentVerticalSegment.
- Site aggregate 에 Bridge 와 Alignment 동시 포함.

## Sprint 37: IFC 거더 Camber 반영
- BridgeExportParams.camber_mid_mm 추가.
- camber > 0 일 때: 거더 1 개를 CAMBER_SEGMENTS(10) 세그먼트로 분할, 각 세그먼트
  Y 에 포물선 값 적용 → 곡선 거더 근사. Pset 는 첫 세그먼트에 한 번만 부착.
- viewer scene_params_to_ifc() 에서 camber_mid_mm 매핑.

## Sprint 38: cimery-macros 크레이트 (proc-macro 스캐폴딩)
- 신규 크레이트, proc-macro = true, deps: syn/quote/proc-macro2.
- #[derive(ParamSummary)] 구현:
  · 구조체 named field 의 PARAM_COUNT (usize) + PARAM_NAMES (&[&str]) 생성.
  · 선언 순서 보존, 빈 구조체 지원, tuple/enum 은 컴파일 에러.
- 테스트 3개 (tests/derive_test.rs).
- ADR-002 D 로드맵: #[param(unit, range, default)] 전면 attribute 는 후속.

## Sprint 39: 변단면 거더 (Variable Depth)
- SceneParams.variable_depth_mm (0~800mm) 추가.
- apply_variable_depth(mesh, z0, z1, max, girder_h):
  · lift(u) = 4·max·u·(span-u)/span²  (중앙에서 최대)
  · y_new = y + lift(u)·(1 - y/h)
  · 상면 y=h 는 고정, 소핏 y=0 을 최대 lift 만큼 올림. 연속교 중앙부
    web 축소 관례와 정합. camber 와 독립 조합 가능.
- build_bridge_scene / build_selectable_scene 거더 생성 루프에 각각 적용
  (거더 local 좌표계에서 먼저 → translate → camber 순).
- UI "변단면 (mm)" 슬라이더 (선형·기하 섹션).
- ProjectFile variable_depth_mm 필드 (default 0).

모든 테스트 통과: kernel 18 + ifc 20 + macros 3.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-15 19:48:07 +09:00
minsung
7f14423bcd Sprint 33 — IFC4X3 Add2 익스포터 Phase 1 (cimery-ifc 신설)
P2 로드맵 (Gitea #4) 첫 단계. 교량·토목 현재 표준인 IFC4X3 Add2 로 익스포트.

## cimery-ifc 크레이트 구성
- src/guid.rs: IfcGloballyUniqueId 생성.
  UUIDv4 128비트 → buildingSMART base64 22자 인코딩.
- src/writer.rs: STEP Part21 텍스트 writer.
  IfcWriter(alloc/emit/write/finish), Ref(#N), lit, real, real3, ref_list.
  HEADER 블록(FILE_DESCRIPTION/FILE_NAME/FILE_SCHEMA='IFC4X3_ADD2') + DATA 블록.
- src/bridge_export.rs: 교량 하이레벨 API.
  BridgeExportParams(span·girder·slab·bearing 치수) + export_bridge() -> String.

## 생성 엔티티 (Phase 1)
계층:
  IfcProject
    └ IfcRelAggregates → IfcSite
        └ IfcRelAggregates → IfcBridge
            └ IfcRelContainedInSpatialStructure → elements[]

원소:
- IFCBEAM × (span_count × girder_count) — 거더
- IFCSLAB × 1 — 데크 슬래브 (전 구간 연속)
- IFCCOLUMN × (span_count-1) — 피어 기둥 (내부 지점만)
- IFCFOOTING × 2 — 교대 (양 끝)
- IFCBEARING × (span_count+1)×girder_count — IFC4X3 신규 엔티티

형상 단순화(Phase 1):
- IFCEXTRUDEDAREASOLID + IFCRECTANGLEPROFILEDEF 일률.
- Phase 2 에서 IFCARBITRARYCLOSEDPROFILEDEF 로 PSC-I 14점 단면 매핑 예정.

단위: IFCSIUNIT mm (+ radian·squareMetre·cubicMetre·second·kilogram).
배치: IfcLocalPlacement 월드 원점 기준 (선형·skew·camber 는 Phase 2).

## 테스트
10개 통과:
- guid: 22자 고정, 동일 UUID 동일 GUID, 문자셋 유효성.
- writer: shell 구조, REAL 포맷, ref_list 포맷.
- bridge_export: 단경간 핵심 엔티티 포함, 다경간 피어 개수, 거더 수 일치, STEP 구조.

## 통합
- workspace Cargo.toml: crates/ifc 추가.
- cimery-app: export_ifc_default IPC 커맨드 (tauri dialog .ifc save).
- main.rs invoke_handler 등록.

Phase 2 로드맵(후속 스프린트):
- IfcAlignment + IfcLinearPlacement (선형 좌표)
- 실제 단면 profile (PSC-I · SteelBox)
- Pset_BeamCommon·Pset_BearingCommon
- IfcPile·IfcExpansionJoint·IfcKerb(방호벽)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-15 17:02:51 +09:00
minsung
1f9ca3a00f Sprint 14~22 — egui 리본 UI + OcctKernel B-rep + 가로보/신축이음 + 선형 좌표 + USD 익스포트 + WASM + CI/CD + 테스트 4층
Sprint 14: egui TopBottomPanel 리본 + CollapsingHeader SidePanel (상부구조·추가부재·선형·프로젝트)
Sprint 15: IncrementalDb 전 Feature 타입 확장 (girder→7종), dirty-tracking 20 unit tests
Sprint 16: Gitea + GitHub Actions CI/CD (check/test/clippy/fmt + 멀티플랫폼 릴리스)
Sprint 17: AlignmentTransform + AlignmentScene — 선형 국소 프레임 → 세계 좌표 변환
Sprint 18: OcctKernel 교각(16각형 기둥+코핑) + 교대(흉벽+푸팅+날개벽) B-rep
Sprint 19: CrossBeamIR + ExpansionJointIR — IR/DSL/kernel/scene 전 계층, sweep_profile_flat_x
Sprint 20: 테스트 4층 — Layer1 insta 스냅샷(7종), Layer2 기하 불변량(19), Layer3 두-커널(7), Layer4 proptest(7) — 61 tests pass
Sprint 21: cimery-usd PureRustKernel 실제 기하 변환 + BridgeExporter 증분 캐시
Sprint 22: viewer wasm feature + wasm-bindgen/web-sys + GitHub Actions Cloudflare Pages 배포

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-15 08:18:06 +09:00
minsung
81349c97d2 Sprint 11/12/13 — 선택하이라이트 + 저장/로드 + Tauri앱 스켈레톤
Sprint 11 (Selection highlight + 단면 UI):
- FeatureDraw: CPU 정점 저장, update_highlight() — 선택 시 yellow-orange
- 렌더 루프: background mesh(지면+선형) + 피처별 독립 draw call 분리
- SceneParams: GirderSectionType (PscI / SteelBox), show_alignment
- egui: 단면형식 ComboBox, 선형표시 checkbox
- SteelBox 단면 지원 (span 비례 자동 치수)
- build_background_scene(): 지면+선형만 반환

Sprint 12 (Project save/load):
- project_file.rs: ProjectFile struct, to_params/from_params, save/load JSON
- egui: 💾 저장 / 📂 불러오기 버튼
- projects/ 폴더 자동 생성

Sprint 13 (Tauri app skeleton):
- crates/app/: Cargo.toml + main.rs (Tauri v2 통합 scaffold)
- 기동 시 PureRustKernel 동작 검증
- Tauri setup checklist 주석으로 문서화
- workspace에 cimery-app 추가

cargo check --workspace 통과

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-14 22:59:11 +09:00
minsung
62ddf3aea6 cimery Sprint 1 — Rust 워크스페이스 + 전 계층 파이프라인
8개 크레이트 구현, cargo test 32개 전부 통과:
- core: Mm/M 단위 newtype, UnitExt 리터럴, FeatureError
- ir: GirderIR + 전 단면 파라미터(PSC-I/U/SteelBox/PlateI) serde JSON
- dsl: Girder builder + 검증 (경간 범위·count·spacing)
- kernel: GeomKernel trait + StubKernel (box mesh, AABB)
- incremental: dirty-tracking IncrementalDb (salsa 업그레이드 경로 주석)
- evaluator: 상태 없는 IR→kernel 브리지
- usd: USDA 1.0 텍스트 익스포트 (CimeryBridgeAPI·GirderAPI schema)
- viewer: wgpu 22 + winit 0.30 컬러 삼각형 (Sprint 1 proof-of-concept)

Sprint 2 다음 단계:
- opencascade-rs로 StubKernel 교체 (실제 PSC-I sweep)
- viewer에서 Girder Mesh 렌더 + 카메라 orbit

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-14 17:46:14 +09:00