mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #5100] [MERGED] feat(sprites): optional styleProfileId for sprite-sheet bakes #6626
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#6626
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/5100
Author: @kolacheee
Created: 8/15/2026
Status: ✅ Merged
Merged: 8/15/2026
Merged by: @kolacheee
Base:
staging← Head:feat/5095-sprite-style-profile📝 Commits (3)
67b86fffeat(sprites): optional styleProfileId for sprite-sheet bakes (#5095)9cd1b88Merge branch 'staging' into feat/5095-sprite-style-profile49bbef9test(sprites): cover imageDefaults.styleProfileId precedence link📊 Changes
3 files changed (+90 additions, -1 deletions)
View changed files
📝
CHANGELOG.md(+1 -0)📝
packages/server/src/routes/sprites.routes.ts(+19 -1)📝
scripts/regressions/sprite-background.regression.ts(+70 -0)📄 Description
Closes #5095
Why
Sprite-sheet bakes always compile against the user's active image style profile (typically anime or photorealistic) with no per-request override — so anyone wanting sprites in a different style (the driving case: pixel-art sprites for a pixel-art Game experience's AI art tier, but equally an anime bake for a photoreal user) gets every sheet in the wrong style. The shared prompt compiler already accepts a
styleProfileIdoverride; the sprite path just never passed one.What changed (server-only, additive)
packages/server/src/routes/sprites.routes.ts:SpriteGenerateSheetBodygains optionalstyleProfileId(also reaching the preview and full-body expression paths, which share the body type).compileSpritePromptnormalizes it at the single choke point (trim, length-cap, blank → absent) and threads it tocompileImagePrompt, whose existing chain — explicit ?? connection image defaults ?? default profile — matches the gallery route's semantics.findImageStyleProfileeverywhere else (graceful fallback, never a throw).sharpslicing, and chroma-matte background removal untouched.scripts/regressions/sprite-background.regression.ts(inregression:sprites): explicit non-default override changes the compiled prompt; explicit-default equals omitted; unknown-id output equals thefindImageStyleProfilefallback's output; blank behaves as omitted.compileSpritePromptis exported for the regression, matching the file's existing pattern.No UI change yet — the field is the enabler for tooling and packages (e.g. a pixel Experience's Tier-2 bake calls the route directly); a sprite-panel profile picker is a natural follow-up, and the user-facing doc (
docs/characters/sprites.md) is deliberately untouched until a UI exists for it to describe.Validation
pnpm checkpnpm regression:sprites(extended)pnpm version:checkstyleProfileIdcompiles a prompt in that profile (the/generate-sheet/previewendpoint shows the exact prompt without spending a generation).Summary by CodeRabbit
New Features
Bug Fixes
Tests
Documentation
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.