ComfyUI Node

Y7 SBS (Video)

2D To 3D Video Converter<div style="font-size: 0.8em"><div id="Y7_shortdesc" style="margin-bottom: 15px;">Converts a 2D video to a stereoscopic 3D video from its frames and depth maps</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 0px; font-size: 12px;">Processes a sequence of video frames to create an SBS (side-by-side) stereoscopic 3D video.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 0px; font-size: 12px;">Inputs:</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">frames</code>: Sequence of video frames to convert to side-by-side 3D.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">depth_maps</code>: Sequence of depth maps corresponding to each frame.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- method: <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">mesh_warping</code> or <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">grid_sampling</code> to shift pixels based on the depth map.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">depth_scale</code>: Controls the strength of the 3D effect (default: 40). Higher values create more pronounced depth but at the cost of tearing and artefacts.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">mode</code>: Viewing mode:</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 40px; font-size: 12px;"> - parallel: For parallel viewing (left eye sees left image).</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 40px; font-size: 12px;"> - cross_eyed: For cross-eyed viewing (left eye sees right image ande vice versa).</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 40px; font-size: 12px;"> - For more info about parallel vs cross-eyed <a href='https://www.ks.uiuc.edu/Research/vmd/vmd-1.7.1/ug/node97.html#:~:text=In%20cross%2Deyed%20stereo%2C%20the,hence%20the%20name%20cross%2Deyed.' target='_blank'>visit here.</a></div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">depth_blur_strength</code>: Controls how much to blur the depth map transitions (3-33, odd values only)</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 40px; font-size: 12px;"> - Lower values for sharper depth separation between objects or layers.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 40px; font-size: 12px;"> - Higher values for smoother transitions between depth planes, though this may introduce some distortion in some images.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">temporal_smoothing</code>: Controls smoothing between frames (0.0-0.5). Higher values create more consistent depth perception between frames but may reduce responsiveness to rapid depth changes.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 0px; font-size: 12px;">- <code style="border: 1px solid #666; border-radius: 3px; padding: 0px 1px; font-family: monospace; display: inline-block;">batch-size</code>: Number of frames to process at once. Lower values = less memory, but maybe slower.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 0px; font-size: 12px;">Output:</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">- A sequence of side-by-side stereoscopic frames.</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 0px; font-size: 12px;">Usage (see example workflow):</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">1. Use one of the 'Load Video' nodes from Video Helper Suite to extract frames</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">2. Use 'DepthAnythingV2' nodes to generate depth maps for each frame</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">3. Feed both into this node to create SBS 3D frames</div></div><div style="font-size: 0.8em"><div style="margin-bottom: 8px; margin-left: 20px; font-size: 12px;">4. Use the 'Video Combine' node from the video helper suite to rebuild the video</div></div>

By yushan777·Created about a year ago·Updated 29 days ago· 42
Y7 SBS (Video)
  • frames
  • depth_maps
  • IMAGE
methodmesh_warping
depth_scale30
mode
output_typesbs
depth_blur_strength7
temporal_smoothing0.20
batch_size32
CategoryY7 SBS

Inputs (9)

NameTypeDefaultDescription
framesIMAGESequence of video frames to convert to side-by-side 3D
depth_mapsIMAGESequence of depth maps corresponding to each frame
methodCOMBOmesh_warpingSelect the 3D rendering method: - mesh_warping: produces smoother, more natural depth with curved distortion - grid_sampling: faster, simpler pixel shifting for a classic stereo effect
depth_scaleINT301–100Controls the strength of the 3D effect - higher values create more pronounced depth
modeCOMBOParallel: For parallel viewing (left eye sees left image). Cross-eyed: For cross-eyed viewing (left eye sees right image)
output_typeCOMBOsbsChoose output format: - sbs: Side-by-side stereoscopic image (left/right) for 3D viewing - top-bottom: Over-under stereoscopic image (left eye on top, right eye on bottom) - anaglyph: Red-cyan anaglyph for viewing with red-cyan 3D glasses
depth_blur_strengthINT73–33Controls how much to blur the depth map transitions. Higher values create smoother depth transitions but may lose detail. 3-15. Odd values only.
temporal_smoothingFLOAT0.200–0.5Smoothing between frames (0=none, higher values=more smoothing)
batch_sizeINT321–256Number of frames to process at once. Lower values use less memory but may be slower.

Outputs (1)

NameTypeDescription
IMAGEIMAGE