| 31 | controlnet.verify_control_type(name, plus_input) |
| 32 | controlnet.allow_condhint_latents = True |
| 33 | return io.NodeOutput(controlnet, PlusPlusImageWrapper(plus_input),) |
| 34 | |
| 35 | class PlusPlusLoaderSingle(io.ComfyNode): |
| 36 | @classmethod |
| 37 | def define_schema(cls) -> io.Schema: |
| 38 | return io.Schema( |
| 39 | node_id='ACN_ControlNet++LoaderSingle', |
| 40 | display_name='Load ControlNet++ Model (Single) 🛂🅐🅒🅝', |
| 41 | category='Adv-ControlNet 🛂🅐🅒🅝/ControlNet++', |
| 42 | inputs=[ |
| 43 | io.Combo.Input('name', options=folder_paths.get_filename_list("controlnet")), |
| 44 | io.Combo.Input('control_type', options=['openpose', 'depth', 'hed/pidi/scribble/ted', 'canny/lineart/mlsd', 'normal', 'segment', 'tile', 'inpaint/outpaint', 'none'], default='none') |
| 45 | ], |
| 46 | outputs=[ |
| 47 | io.ControlNet.Output('CONTROL_NET', is_output_list=False) |
| 48 | ] |
| 49 | ) |
| 50 | |
| 51 | |
| 52 | @classmethod |
| 53 | def execute(cls, name: str, control_type: str): |
| 54 | controlnet_path = folder_paths.get_full_path("controlnet", name) |
| 55 | controlnet = load_controlnetplusplus(controlnet_path) |
| 56 | controlnet.single_control_type = control_type |
nothing calls this directly
no outgoing calls
no test coverage detected