Skip to content

Require raw texture dimensions at construction#342

Closed
esnya wants to merge 3 commits into
codex/type-inmemory-texture-sourcefrom
codex/type-inmemory-raw-texture-dimensions
Closed

Require raw texture dimensions at construction#342
esnya wants to merge 3 commits into
codex/type-inmemory-texture-sourcefrom
codex/type-inmemory-raw-texture-dimensions

Conversation

@esnya
Copy link
Copy Markdown
Owner

@esnya esnya commented Jun 1, 2026

Summary

  • split in-memory texture source creation into raw and encoded entrypoints so raw textures require width/height at the call site
  • make raw TexturePayload/ResoniteTexturePayload byte constructors dimension-required and encoded source-backed constructors format-fixed
  • update mapper/test/canonical dump helpers to route raw vs encoded payloads through the typed entrypoints

Verification

  • dotnet restore PlateauResoniteLink.sln --locked-mode --disable-build-servers
  • dotnet format whitespace . --folder --verify-no-changes
  • dotnet build PlateauResoniteLink.sln --configuration Release --no-restore --disable-build-servers -m:1 -p:UseSharedCompilation=false
  • dotnet test PlateauResoniteLink.sln --configuration Release --no-restore --verbosity normal -m:1 --disable-build-servers -p:UseSharedCompilation=false (1006 passed)
  • Fake Live Sink canonical dump for plateau-13213-higashimurayama-shi-2020, mesh 53395325, packages dem,bldg, terrain mesh grid matched the baseline with git diff --no-index; temp dump removed

@esnya
Copy link
Copy Markdown
Owner Author

esnya commented Jun 2, 2026

レビュー対応として追加で TexturePayload / ResoniteTexturePayload の payload invariant を閉じました。

  • raw/encoded の構築後に Width / Height / Format / Source / BinaryPayload を init で差し替えられないよう、payload の状態プロパティを get-only に変更
  • それにより RawRgba32 なのに width/height が null という状態は通常の C# API から生成不能になったため、mapper/test support 側の Raw texture payload requires width/height runtime fallback を削除
  • 新しい同型ラッパーは増やさず、既存の raw vs encoded constructor 境界をそのまま不変条件の境界にしています

検証:

  • dotnet restore PlateauResoniteLink.sln --locked-mode --disable-build-servers
  • dotnet format whitespace . --folder --verify-no-changes
  • dotnet build PlateauResoniteLink.sln --configuration Release --no-restore --disable-build-servers -m:1 -p:UseSharedCompilation=false
  • dotnet test PlateauResoniteLink.sln --configuration Release --no-restore --verbosity normal -m:1 --disable-build-servers -p:UseSharedCompilation=false (1006 passed)
  • Fake Live Sink canonical dump: higashi-53395325-dem-bldg-grid-geotiff.json と一致

@esnya esnya force-pushed the codex/type-validated-dataset-location-payloads branch from 3a49941 to 1d7b442 Compare June 2, 2026 15:19
@esnya esnya force-pushed the codex/type-inmemory-raw-texture-dimensions branch from 61be868 to b9ef702 Compare June 2, 2026 15:26
@esnya esnya force-pushed the codex/type-validated-dataset-location-payloads branch from 1d7b442 to 812c3cb Compare June 2, 2026 18:24
@esnya esnya force-pushed the codex/type-inmemory-raw-texture-dimensions branch from b9ef702 to 379ee50 Compare June 2, 2026 18:24
@esnya esnya force-pushed the codex/type-validated-dataset-location-payloads branch from 812c3cb to e0f1833 Compare June 2, 2026 19:15
@esnya esnya force-pushed the codex/type-inmemory-raw-texture-dimensions branch from 379ee50 to df4dd28 Compare June 2, 2026 19:15
@esnya esnya force-pushed the codex/type-validated-dataset-location-payloads branch from e0f1833 to 453d25a Compare June 2, 2026 19:34
@esnya esnya force-pushed the codex/type-inmemory-raw-texture-dimensions branch from df4dd28 to 7d68051 Compare June 2, 2026 19:34
@esnya esnya force-pushed the codex/type-validated-dataset-location-payloads branch from 453d25a to 813a8b5 Compare June 2, 2026 19:59
@esnya esnya force-pushed the codex/type-inmemory-raw-texture-dimensions branch from 7d68051 to 3cf937d Compare June 2, 2026 19:59
@esnya esnya force-pushed the codex/type-validated-dataset-location-payloads branch from 813a8b5 to f5ab83a Compare June 2, 2026 20:48
@esnya esnya force-pushed the codex/type-inmemory-raw-texture-dimensions branch from 3cf937d to e5d16f9 Compare June 2, 2026 20:48
@esnya esnya changed the base branch from codex/type-validated-dataset-location-payloads to codex/type-inmemory-texture-source June 2, 2026 20:49
@esnya
Copy link
Copy Markdown
Owner Author

esnya commented Jun 2, 2026

Superseded by #340: these texture source/payload changes depend on the same upstream texture boundary and have been folded into the main-target #340 PR instead of keeping a dependent stack.

@esnya esnya force-pushed the codex/type-inmemory-texture-source branch from 42cb588 to 2f854f7 Compare June 2, 2026 22:14
@esnya esnya closed this Jun 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant