ComfyUI > Nodes > LF Nodes > Resolution switcher

ComfyUI Node: Resolution switcher

Class Name

LF_ResolutionSwitcher

Category
✨ LF Nodes/Logic
Author
lucafoscili (Account age: 2148days)
Extension
LF Nodes
Latest Updated
2024-10-15
Github Stars
0.03K

How to Install LF Nodes

Install this extension via the ComfyUI Manager by searching for LF Nodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter LF Nodes in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Resolution switcher Description

Automatically switch resolution settings based on conditions for images or videos, enhancing efficiency and output quality.

Resolution switcher:

The LF_ResolutionSwitcher node is designed to dynamically switch between different resolution settings based on a specified condition. This node is particularly useful in scenarios where you need to adapt the resolution of an image or a video stream depending on certain criteria, such as performance requirements or visual quality needs. By automating the resolution switching process, this node helps streamline workflows and ensures that the appropriate resolution is used in different contexts, enhancing both efficiency and output quality.

Resolution switcher Input Parameters:

on_true

This parameter specifies the resolution value to be used if the boolean condition is true. It allows you to define a higher or lower resolution setting that will be applied when the condition is met. The value should be a valid resolution format, such as "1920x1080" for Full HD.

on_false

This parameter specifies the resolution value to be used if the boolean condition is false. Similar to the on_true parameter, it allows you to define an alternative resolution setting that will be applied when the condition is not met. The value should be a valid resolution format, such as "1280x720" for HD.

boolean

This boolean parameter determines which resolution setting to apply. If set to true, the on_true resolution will be used; if set to false, the on_false resolution will be applied. This parameter acts as the switch that controls the resolution output based on the specified condition.

Resolution switcher Output Parameters:

resolution

The output parameter resolution provides the selected resolution value based on the boolean condition. It returns either the on_true or on_false resolution, depending on the state of the boolean parameter. This output is crucial for ensuring that the correct resolution is applied in your workflow, adapting to the specified conditions dynamically.

Resolution switcher Usage Tips:

  • Ensure that the resolution values provided in on_true and on_false are in a valid format and supported by your system or application.
  • Use the boolean parameter to create dynamic workflows where resolution needs to change based on specific conditions, such as user input or system performance metrics.
  • Test the node with different boolean conditions to verify that the correct resolution is being applied in each scenario.

Resolution switcher Common Errors and Solutions:

Invalid resolution format

  • Explanation: The resolution value provided in on_true or on_false is not in a valid format.
  • Solution: Ensure that the resolution values are in the correct format, such as "1920x1080" or "1280x720".

Boolean parameter not set

  • Explanation: The boolean parameter is not set, causing the node to fail in determining which resolution to apply.
  • Solution: Make sure to set the boolean parameter to either true or false to control the resolution switching.

Unsupported resolution

  • Explanation: The resolution value provided is not supported by your system or application.
  • Solution: Verify that the resolution values are supported by your system or application and adjust them accordingly.

Resolution switcher Related Nodes

Go back to the extension to check out more related nodes.
LF Nodes
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.