ComfyUI > Nodes > ComfyUI-NegiTools > Stereo Image Generator 🧅

ComfyUI Node: Stereo Image Generator 🧅

Class Name

NegiTools_StereoImageGenerator

Category
Generator
Author
natto-maki (Account age: 395days)
Extension
ComfyUI-NegiTools
Latest Updated
2024-09-15
Github Stars
0.03K

How to Install ComfyUI-NegiTools

Install this extension via the ComfyUI Manager by searching for ComfyUI-NegiTools
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-NegiTools 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

Stereo Image Generator 🧅 Description

Transforms 2D images into stereo pairs for 3D visual effects and immersive experiences with customizable parameters.

Stereo Image Generator 🧅:

The NegiTools_StereoImageGenerator is a powerful node designed to create stereo images from a given input image and its corresponding depth map. This node is particularly useful for generating 3D visual effects, enhancing the depth perception in images, and creating immersive visual experiences. By leveraging advanced image processing techniques, it transforms a 2D image into a stereo pair, which can be viewed with 3D glasses or on 3D displays. The node allows you to control various parameters such as divergence, stereo offset exponent, and fill technique, providing flexibility and precision in generating the desired stereo effect. Whether you are an AI artist looking to add depth to your creations or a developer working on 3D visualization projects, this node offers a robust solution for stereo image generation.

Stereo Image Generator 🧅 Input Parameters:

image

This parameter represents the input image that you want to convert into a stereo image. It should be a standard 2D image in a format supported by the node.

depth_image

This parameter is the depth map corresponding to the input image. The depth map provides information about the distance of each pixel from the viewer, which is crucial for generating the stereo effect.

divergence

This parameter controls the divergence of the stereo images, which affects the perceived depth. It is a float value with a default of 5.0, a minimum of 0.05, and a maximum of 10.0. Adjusting this value can make the stereo effect more or less pronounced.

stereo_offset_exponent

This parameter determines the exponent used for calculating the stereo offset. It is a float value with a default of 1.0, a minimum of 0.1, and a maximum of 3.0. This parameter allows you to fine-tune the stereo effect by adjusting the offset calculation.

fill_technique

This parameter specifies the technique used to fill in the gaps created during the stereo image generation. The available options are "polylines_sharp", "polylines_soft", "naive", "naive_interpolating", and "none". Each technique offers a different approach to handling the gaps, affecting the final appearance of the stereo images.

output_mode

This parameter defines the output mode for the stereo images. The available options are "L-R", "R-L", and "L-R-L". "L-R" generates a left-right stereo pair, "R-L" generates a right-left stereo pair, and "L-R-L" generates a left-right-left sequence.

Stereo Image Generator 🧅 Output Parameters:

STEREO_IMAGE

This output parameter provides the combined stereo image, which can be viewed with 3D glasses or on a 3D display. It is the main output of the node, representing the final stereo effect.

IMAGE_L

This output parameter provides the left image of the stereo pair. It is useful for applications that require separate access to the left and right images.

IMAGE_R

This output parameter provides the right image of the stereo pair. Similar to IMAGE_L, it is useful for applications that need individual access to the stereo images.

Stereo Image Generator 🧅 Usage Tips:

  • Adjust the divergence parameter to control the depth effect. Higher values will create a more pronounced 3D effect, while lower values will result in a subtler effect.
  • Experiment with different fill_technique options to see which one best suits your image. Some techniques may work better for certain types of images or desired effects.
  • Use the output_mode parameter to generate the stereo image sequence that fits your display or viewing method. For example, "L-R" is commonly used for standard 3D displays.

Stereo Image Generator 🧅 Common Errors and Solutions:

ValueError

  • Explanation: This error occurs when an invalid output_mode is provided.
  • Solution: Ensure that the output_mode parameter is set to one of the following valid options: "L-R", "R-L", or "L-R-L".

Depth Map Range Error

  • Explanation: This error occurs if the depth map has a uniform value, causing the depth range to be zero.
  • Solution: Verify that the depth map has varying depth values. If the depth map is uniform, adjust it to include a range of depth values to avoid this error.

Stereo Image Generator 🧅 Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-NegiTools
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.