fix: keep person guard for product scale lock

This commit is contained in:
134 2026-07-06 08:08:14 +08:00
parent 376881d9f9
commit 5d4286f7c2

View File

@ -2610,7 +2610,7 @@ async function buildScaleAdjustRmbgStructureLockedComposite(params: {
: null; : null;
const protectedPersonRemovalMask = protectedPersonMask; const protectedPersonRemovalMask = protectedPersonMask;
const sideProtectedCleanedAlpha = const sideProtectedCleanedAlpha =
protectedPersonSide && sameSizeCutout && sourceCropRaw protectedPersonSide && sameSizeCutout && sourceCropRaw && !preferPixelStructure
? suppressScaleAdjustProtectedFurnitureDarkAlpha({ ? suppressScaleAdjustProtectedFurnitureDarkAlpha({
alphaMask: Buffer.from(cleanedAlpha), alphaMask: Buffer.from(cleanedAlpha),
bbox: { left: 0, top: 0, width: cutoutWidth, height: cutoutHeight }, bbox: { left: 0, top: 0, width: cutoutWidth, height: cutoutHeight },
@ -3542,9 +3542,7 @@ async function buildScaleAdjustVisualLayoutGuideBuffer(params: {
const preferPixelStructure = isScaleAdjustFurnitureProductLikePrompt( const preferPixelStructure = isScaleAdjustFurnitureProductLikePrompt(
region.prompt region.prompt
); );
const protectedPersonSide = preferPixelStructure const protectedPersonSide = getScaleAdjustProtectedPersonSide(region.prompt);
? null
: getScaleAdjustProtectedPersonSide(region.prompt);
const hasPersonPixels = const hasPersonPixels =
!preferPixelStructure && !preferPixelStructure &&
!!sourceRaw && !!sourceRaw &&