Add separate style pool config

This commit is contained in:
2026-06-28 00:24:40 +02:00
parent 4c8edc0d3e
commit 78e39734b5
18 changed files with 378 additions and 27 deletions
+7
View File
@@ -98,6 +98,7 @@ SXCP_CATEGORY_CONFIG = "SXCP_CATEGORY_CONFIG"
SXCP_CAST_CONFIG = "SXCP_CAST_CONFIG"
SXCP_GENERATION_PROFILE = "SXCP_GENERATION_PROFILE"
SXCP_FILTER_CONFIG = "SXCP_FILTER_CONFIG"
SXCP_STYLE_CONFIG = "SXCP_STYLE_CONFIG"
SXCP_ETHNICITY_LIST = "SXCP_ETHNICITY_LIST"
SXCP_CHARACTER_CAST = "SXCP_CHARACTER_CAST"
SXCP_CHARACTER_SLOT = "SXCP_CHARACTER_SLOT"
@@ -647,6 +648,7 @@ def _compat_configs(scene: dict[str, Any], branch_name: str = "") -> dict[str, A
"camera_config": branch_configs.get("camera_config") or configs.get("camera_config") or "",
"location_config": branch_configs.get("location_config") or configs.get("location_config") or "",
"composition_config": branch_configs.get("composition_config") or configs.get("composition_config") or "",
"style_config": branch_configs.get("style_config") or configs.get("style_config") or "",
"character_profile": branch_configs.get("character_profile") or configs.get("character_profile") or "",
"character_cast": branch_configs.get("character_cast") or configs.get("character_cast") or "",
"hardcore_position_config": branch_configs.get("hardcore_position_config") or configs.get("hardcore_position_config") or "",
@@ -1210,6 +1212,7 @@ class SxCPSceneStart:
"category_config": (SXCP_CATEGORY_CONFIG,),
"generation_profile": (SXCP_GENERATION_PROFILE,),
"filter_config": (SXCP_FILTER_CONFIG,),
"style_config": (SXCP_STYLE_CONFIG,),
"extra_positive": ("STRING", {"default": "", "multiline": True}),
"extra_negative": ("STRING", {"default": "", "multiline": True}),
},
@@ -1235,6 +1238,7 @@ class SxCPSceneStart:
category_config="",
generation_profile="",
filter_config="",
style_config="",
extra_positive="",
extra_negative="",
):
@@ -1258,6 +1262,7 @@ class SxCPSceneStart:
_set_config(scene, "category_config", category_config)
_set_config(scene, "generation_profile", generation_profile)
_set_config(scene, "filter_config", filter_config)
_set_config(scene, "style_config", style_config)
_add_history(scene, "scene_start", f"{category_preset}/{subcategory}; {profile}")
return _scene_out(scene)
@@ -2220,6 +2225,7 @@ class SxCPSceneOutput:
hardcore_position_config=configs["hardcore_position_config"],
location_config=configs["location_config"],
composition_config=configs["composition_config"],
style_config=configs["style_config"],
extra_positive=configs["extra_positive"],
extra_negative=configs["extra_negative"],
)
@@ -2289,6 +2295,7 @@ class SxCPScenePairOutput:
hardcore_position_config=hard_configs["hardcore_position_config"],
location_config=base_configs["location_config"] or hard_configs["location_config"],
composition_config=base_configs["composition_config"] or hard_configs["composition_config"],
style_config=base_configs["style_config"] or hard_configs["style_config"],
extra_positive=_joined_text(base_configs["extra_positive"], hard_configs["extra_positive"]),
extra_negative=base_configs["extra_negative"] or hard_configs["extra_negative"],
)