Skip to main content

GLIGENTextBoxApplyBatchCoords

KJNodes/experimental
GLIGENTextBoxApplyBatchCoords

This node allows scheduling GLIGEN text box positions in a batch, to be used with AnimateDiff-Evolved. Intended to pair with the Spline Editor -node. GLIGEN model can be downloaded through the Manage's "Install Models" menu. Or directly from here: https://huggingface.co/comfyanonymous/GLIGEN_pruned_safetensors/tree/main Inputs: - **latents** input is used to calculate batch size - **clip** is your standard text encoder, use same as for the main prompt - **gligen_textbox_model** connects to GLIGEN Loader - **coordinates** takes a json string of points, directly compatible with the spline editor node. - **text** is the part of the prompt to set position for - **width** and **height** are the size of the GLIGEN bounding box Outputs: - **conditioning** goes between to clip text encode and the sampler - **coord_preview** is an optional preview of the coordinates and bounding boxes.

Example

JSON Example
{
  "class_type": "GLIGENTextBoxApplyBatchCoords",
  "inputs": {
    "conditioning_to": [
      "node_id",
      0
    ],
    "latents": [
      "node_id",
      0
    ],
    "clip": [
      "node_id",
      0
    ],
    "gligen_textbox_model": [
      "node_id",
      0
    ],
    "coordinates": "",
    "text": "example text",
    "width": 128,
    "height": 128
  }
}

This example shows required inputs only. Connection values like ["node_id", 0] should reference actual node IDs from your workflow.

Inputs

NameTypeStatusConstraintsDefault
conditioning_toCONDITIONINGrequired--
latentsLATENTrequired--
clipCLIPrequired--
gligen_textbox_modelGLIGENrequired--
coordinatesSTRINGrequired--
textSTRINGrequired--
widthINTrequiredmin: 8, max: 4096, step: 8128
heightINTrequiredmin: 8, max: 4096, step: 8128
size_multiplierFLOAToptional-[1]

Outputs

IndexNameTypeIs ListConnection Reference
0conditioningCONDITIONINGNo["{node_id}", 0]
1coord_previewIMAGENo["{node_id}", 1]
How to connect to these outputs

To connect another node's input to an output from this node, use the connection reference format:

["node_id", output_index]

Where node_id is the ID of this GLIGENTextBoxApplyBatchCoords node in your workflow, and output_index is the index from the table above.

Example

If this node has ID "5" in your workflow:

  • conditioning (CONDITIONING): ["5", 0]
  • coord_preview (IMAGE): ["5", 1]
Was this page helpful?