Files
chflame163-ComfyUI_LayerStyle/workflow/mask_box_detect_example.json
T
chflame163 3bf19861c6 Commit MaskBoxDetect, X,Y to Percent, GaussianBlur and GetImageSize nodes.
Commit MaskBoxDetect node, which can automatically detect the position through the mask and output it to the composite node.
Commit X,Y to Percent node to convert absolute coordinates to percent coordinates.
Commit GaussianBlur node.
Commit GetImageSize node.
2024-01-23 13:39:41 +08:00

409 lines
6.5 KiB
JSON

{
"last_node_id": 10,
"last_link_id": 12,
"nodes": [
{
"id": 5,
"type": "LayerUtility: ImageBlendAdvance",
"pos": [
359,
-287
],
"size": {
"0": 315,
"1": 338
},
"flags": {},
"order": 5,
"mode": 0,
"inputs": [
{
"name": "background_image",
"type": "IMAGE",
"link": 2
},
{
"name": "layer_image",
"type": "IMAGE",
"link": 3
},
{
"name": "layer_mask",
"type": "MASK",
"link": 4
},
{
"name": "x_percent",
"type": "FLOAT",
"link": 8,
"widget": {
"name": "x_percent"
}
},
{
"name": "y_percent",
"type": "FLOAT",
"link": 9,
"widget": {
"name": "y_percent"
}
}
],
"outputs": [
{
"name": "image",
"type": "IMAGE",
"links": [
5
],
"shape": 3,
"slot_index": 0
},
{
"name": "mask",
"type": "MASK",
"links": null,
"shape": 3
}
],
"properties": {
"Node name for S&R": "LayerUtility: ImageBlendAdvance"
},
"widgets_values": [
true,
"normal",
100,
50,
50,
"None",
1,
1,
0,
"lanczos",
0
]
},
{
"id": 6,
"type": "PreviewImage",
"pos": [
730,
-286
],
"size": [
1041.1129755859374,
650.982203125
],
"flags": {},
"order": 6,
"mode": 0,
"inputs": [
{
"name": "images",
"type": "IMAGE",
"link": 5
}
],
"properties": {
"Node name for S&R": "PreviewImage"
}
},
{
"id": 2,
"type": "LoadImage",
"pos": [
-488,
66
],
"size": [
381.4913983453371,
316.9454925390627
],
"flags": {},
"order": 0,
"mode": 0,
"outputs": [
{
"name": "IMAGE",
"type": "IMAGE",
"links": [
2
],
"shape": 3,
"slot_index": 0
},
{
"name": "MASK",
"type": "MASK",
"links": [
10,
12
],
"shape": 3,
"slot_index": 1
}
],
"properties": {
"Node name for S&R": "LoadImage"
},
"widgets_values": [
"clipspace/clipspace-mask-38360.5.png [input]",
"image"
]
},
{
"id": 10,
"type": "LayerMask: MaskPreview",
"pos": [
-36,
137
],
"size": [
327.928316040039,
231.32022418212887
],
"flags": {},
"order": 3,
"mode": 0,
"inputs": [
{
"name": "mask",
"type": "MASK",
"link": 12
}
],
"properties": {
"Node name for S&R": "LayerMask: MaskPreview"
}
},
{
"id": 8,
"type": "PreviewImage",
"pos": [
352,
128
],
"size": {
"0": 318.7994079589844,
"1": 246
},
"flags": {},
"order": 4,
"mode": 0,
"inputs": [
{
"name": "images",
"type": "IMAGE",
"link": 7
}
],
"properties": {
"Node name for S&R": "PreviewImage"
}
},
{
"id": 1,
"type": "LoadImage",
"pos": [
-423,
-295
],
"size": {
"0": 315,
"1": 314
},
"flags": {},
"order": 1,
"mode": 0,
"outputs": [
{
"name": "IMAGE",
"type": "IMAGE",
"links": [
3
],
"shape": 3,
"slot_index": 0
},
{
"name": "MASK",
"type": "MASK",
"links": [
4
],
"shape": 3,
"slot_index": 1
}
],
"properties": {
"Node name for S&R": "LoadImage"
},
"widgets_values": [
"512x512 (20).png",
"image"
]
},
{
"id": 7,
"type": "LayerMask: MaskBoxDetect",
"pos": [
-35,
-233
],
"size": {
"0": 315,
"1": 250
},
"flags": {},
"order": 2,
"mode": 0,
"inputs": [
{
"name": "mask",
"type": "MASK",
"link": 10
}
],
"outputs": [
{
"name": "box_preview",
"type": "IMAGE",
"links": [
7
],
"shape": 3,
"slot_index": 0
},
{
"name": "x_percent",
"type": "FLOAT",
"links": [
8
],
"shape": 3,
"slot_index": 1
},
{
"name": "y_percent",
"type": "FLOAT",
"links": [
9
],
"shape": 3,
"slot_index": 2
},
{
"name": "width",
"type": "INT",
"links": null,
"shape": 3
},
{
"name": "height",
"type": "INT",
"links": null,
"shape": 3
},
{
"name": "x",
"type": "INT",
"links": null,
"shape": 3
},
{
"name": "y",
"type": "INT",
"links": null,
"shape": 3
}
],
"properties": {
"Node name for S&R": "LayerMask: MaskBoxDetect"
},
"widgets_values": [
"min_bounding_rect",
0,
-200,
1
]
}
],
"links": [
[
2,
2,
0,
5,
0,
"IMAGE"
],
[
3,
1,
0,
5,
1,
"IMAGE"
],
[
4,
1,
1,
5,
2,
"MASK"
],
[
5,
5,
0,
6,
0,
"IMAGE"
],
[
7,
7,
0,
8,
0,
"IMAGE"
],
[
8,
7,
1,
5,
3,
"FLOAT"
],
[
9,
7,
2,
5,
4,
"FLOAT"
],
[
10,
2,
1,
7,
0,
"MASK"
],
[
12,
2,
1,
10,
0,
"MASK"
]
],
"groups": [],
"config": {},
"extra": {},
"version": 0.4
}