refactor(pipeline): MP1a - Content-owned upload enums; drop Silk.NET from Content
Coordinator-directed follow-up: AcDream.Content must stay Silk.NET-free (the MP1b bake tool must not ship GL binaries). The Silk.NET.OpenGL PackageReference added for the PixelFormat?/PixelType? upload hints is replaced by Content-owned UploadPixelFormat/UploadPixelType enums (UploadFormats.cs) whose underlying values are the GL ABI constants (Rgba = 0x1908, UnsignedByte = 0x1401), verified numerically identical to the Silk.NET.OpenGL members against 2.23.0. This is the one sanctioned edit to the verbatim-moved Prepare* bodies: enum literal for enum literal, numeric value identical, behavior unchanged. App casts at the single upload boundary (AddTexture call in UploadGfxObjMeshData) via lifted nullable enum conversion — value- and null-preserving. Also hardens the MP1a _sideStaged hand-off seam: List -> ConcurrentQueue. One MeshExtractor is shared by up to MaxParallelLoads (4) decode workers; the original code enqueued to the thread-safe _stagedMeshData directly, so the hand-off buffer must be thread-safe too. Drain ordering verified: side-staged entries enqueue BEFORE the top-level result, preserving the original mid-Prepare FIFO order. Verified: grep -i silk on the csproj -> no matches; deps.json has zero Silk entries; dotnet build 0 errors; full test suite green (4059 passed). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
30cc1e282e
commit
1477cda60a
5 changed files with 89 additions and 50 deletions
|
|
@ -807,7 +807,13 @@ namespace AcDream.App.Rendering.Wb {
|
|||
atlasList.Add(atlasManager);
|
||||
}
|
||||
|
||||
textureIndex = atlasManager.AddTexture(batch.Key, batch.TextureData, batch.UploadPixelFormat, batch.UploadPixelType);
|
||||
// MP1a: AcDream.Content is Silk.NET-free — the extraction records
|
||||
// carry Content-owned UploadPixelFormat/UploadPixelType enums whose
|
||||
// underlying values are the GL ABI constants (numerically identical
|
||||
// to Silk.NET.OpenGL.PixelFormat/PixelType), so this lifted nullable
|
||||
// cast is value- and null-preserving.
|
||||
textureIndex = atlasManager.AddTexture(batch.Key, batch.TextureData,
|
||||
(PixelFormat?)batch.UploadPixelFormat, (PixelType?)batch.UploadPixelType);
|
||||
|
||||
if (_useModernRendering) {
|
||||
ibo = GlobalBuffer!.IBO;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue