Skip to content
This repository was archived by the owner on Mar 19, 2026. It is now read-only.

v0.10 衝突検出#80

Merged
HMasataka merged 7 commits into
mainfrom
feature/v0.10-collision-detection
Mar 5, 2026
Merged

v0.10 衝突検出#80
HMasataka merged 7 commits into
mainfrom
feature/v0.10-collision-detection

Conversation

@HMasataka
Copy link
Copy Markdown
Owner

Summary

  • SpatialHashGrid (グリッドベース空間ハッシュ、OverlapSphere用)
  • BVH広域フェーズ (SAH構築、IntroSortでO(n log n)保証)
  • GJK+EPA狭域フェーズ (Sphere/Box/Capsule間の衝突判定+貫通情報)
  • レイキャストAPI (Raycast, RaycastAll, SphereCast, OverlapSphere)
  • ECSシステム統合 (BroadPhaseSystem + NarrowPhaseSystem)

全てunmanaged struct、フレームループ0-allocation制約遵守。
エラーハンドリングはResultパターン。

新規: 20ソースファイル + 15テストファイル (72テスト)
変更: AABB.cs (SurfaceArea追加), ErrorCode.cs (Physics ErrorCodes追加)

Test plan

  • 全614テストパス (新規72 + 既存548、リグレッションなし)
  • ビルド成功 (0 warnings, 0 errors)

🤖 Generated with Claude Code

HMasataka and others added 7 commits March 5, 2026 22:19
BVHのSAHヒューリスティックに必要なSurfaceAreaプロパティと、
物理ドメインのResult<T>用エラーコードを追加。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
tagged union方式のCollider (Sphere/Box/Capsule)、
GJKサポート関数、GJK衝突判定+EPA貫通情報抽出を実装。
全てunmanaged structでフレームループ0-allocation制約を遵守。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
SAHベースBVH (IntroSortでO(n log n)保証) と
OverlapSphere用のグリッドベース空間ハッシュを実装。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
BVHベースのRay/Sphere交差テストと、
SpatialHashGridベースのOverlapSphereクエリを実装。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
BroadPhaseSystem (BVH構築+ペア抽出) と
NarrowPhaseSystem (GJK+EPA実行) をPhysicsフェーズに追加。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
GJK+EPA、BVH、SpatialHashGrid、レイキャスト、
ECSシステム統合の単体テストを網羅的に追加。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@HMasataka HMasataka merged commit bf9f53a into main Mar 5, 2026
3 checks passed
@HMasataka HMasataka deleted the feature/v0.10-collision-detection branch March 5, 2026 13:23
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant