Nodes/ComfyUI-ComfyUI-Hunyuan3DWrapper/Hy3D Bake From Multiview
ComfyUI Node

Hy3D Bake From Multiview

The node that turns six photos of your mesh into one flat texture

By kijai·Created 2 years ago·Updated 5 months ago· 1,033
Hy3D Bake From Multiview
  • images
  • renderer
  • camera_config
  • texture
  • mask
  • renderer

Hunyuan3D's paint stage doesn't paint a UV map directly - it generates a ring of multi-view images around your mesh. Hy3DBakeFromMultiview is the node that projects those images back onto the geometry and bakes them into a single UV texture. It's the point where "a bunch of renders" becomes "a texture you can actually export." If you skip it, you have no skin to apply.

How the bake works

The mechanism is back-projection, and it's worth knowing roughly because it explains the outputs. For each of your multi-view images, the renderer knows the camera it was rendered from (azimuth and elevation). The node back-projects the image onto the mesh surface in UV space, giving a candidate texture for that view. Each view is weighted by a cosine map (faces pointing at the camera get more trust), raised to the 4th power, then all the candidates are merged with the "fast" method. The result is a texture where well-seen areas are sharp and occluded or unseen areas are empty.

That last bit is the whole story of the node, because it's why the next node in the chain exists:

  • texture (IMAGE) - the baked UV texture, complete with holes where no view reached.
  • mask (MASK) - the trust map: where the bake actually covered. This is the mask you feed to Hy3DMeshVerticeInpaintTexture or CV2InpaintTexture to fill the gaps.
  • renderer (MESHRENDER) - passed through so Hy3DApplyTexture can finish the job.

Inputs are images (the multiview output from Hy3DSampleMultiView), renderer (from Hy3DRenderMultiView), and an optional camera_config from Hy3DCameraConfig. If you leave the camera config unconnected, it uses the same six default views (azimuths 0/90/180/270/0/180, elevations 0/0/0/0/90/-90) that the render and sample stages default to - so you must keep camera settings consistent across those three nodes, or the projection won't line up. Wire the same Hy3DCameraConfig everywhere.

Common issues

The two failure modes people hit:

  • The bake looks stretched or wrong - almost always mismatched cameras between render, sample, and bake. One Hy3DCameraConfig node, wired to all three.
  • The node crashes on a missing custom_rasterizer - the bake calls into the compiled rasterizer. On anything other than Windows 11 / Python 3.12 / CUDA 12.6 you'll need to build or match the wheel (see the pack README); the community's most common error reports for this whole pack are exactly No module named 'custom_rasterizer' and the CUDA no kernel image failure from this part of the pipeline.

Install is the pack install (ComfyUI Manager, search "Hunyuan3DWrapper", or clone into custom_nodes). Once the rasterizer is healthy, this node is a reliable workhorse: bake, inpaint, apply, export.

CategoryHunyuan3DWrapper

Inputs (3)

NameTypeDefaultDescription
imagesIMAGE
rendererMESHRENDER
camera_configoptHY3DCAMERA

Outputs (3)

NameTypeDescription
textureIMAGE
maskMASK
rendererMESHRENDER