u/Kindly_Gift4836

Single photo → white mesh → textured 3D character: full ComfyUI + Hunyuan3D-2 pipeline (+ the bugs that ate my weekend)
▲ 7 r/meshyai+1 crossposts

Single photo → white mesh → textured 3D character: full ComfyUI + Hunyuan3D-2 pipeline (+ the bugs that ate my weekend)

TL;DR: One 2D portrait → Hunyuan3D-2 in ComfyUI for geometry → Meshy for the final texture pass. Geometry from open-source is genuinely great even on a hard pose. Texture baking is the weak spot. Full node chain + the 4 bugs that cost me hours below.

Result

img 1

[img 1: source photo] → [img 2: white mesh] → [img 3: textured render]

img 2

img 3

Input was a single seated full-body portrait — crossed arms, crossed legs, long flowing hair, fabric draping over a stool. I deliberately avoided the "T-pose on white background" these models love, to see how it handles a real pose. It held up better than I expected.

Hardware: RTX 5090 (32GB). Geometry stage peaks well under that.

The pipeline

Stage 1 — Geometry (ComfyUI + Hunyuan3D-2, fully local)

Node chain:

LoadImage
  → background removal (TransparentBGSession+ / ImageRemoveBackground+)
  → ImageResize+ (960x960)
  → Hy3DModelLoader        (hunyuan3d-dit-v2-0-fp16, attention_mode = sdpa)
  → Hy3DGenerateMesh       (guidance 5.5, 50 steps)
  → Hy3DVAEDecode          (mc surface extractor)
  → Hy3DPostprocessMesh    (decimate to ~50k faces)
  → Hy3DExportMesh         → white-mesh GLB

Raw decode landed around 333k verts / 1.3M faces, simplified down cleanly to 25k verts / 50k faces. The crossed legs, the hand against the cheek, the fabric folds — all reconstructed coherently from one view.

Stage 2 — Texture

Hunyuan3D-2 has a built-in texture path:

Hy3DMeshUVWrap
  → Hy3DRenderMultiView      (render the white mesh from 6 angles)
  → Hy3DDelightImage         (strip baked lighting)
  → Hy3DSampleMultiView      (paint model generates per-view textures)
  → Hy3DBakeFromMultiview    (project views back onto the mesh)
  → Hy3DMeshVerticeInpaintTexture / CV2InpaintTexture  (fill seams)
  → Hy3DApplyTexture
  → Hy3DExportMesh           → textured GLB

It works, but the multi-view projection left visible artifacts — red blotches where lip color and nail polish bled onto skin. Known limitation: the per-view colors don't always align perfectly during baking.

For the final asset I ran the mesh through Meshy. Texture alignment there is clearly cleaner — skin, hair, dress all came through without the bleed. Open-source geometry + commercial texture pass turned out to be the sweet spot for me.

The 4 bugs that cost me hours

1. A custom node globally monkey-patches PyTorch attention. An older Trellis integration node overwrites torch.nn.functional.scaled_dot_product_attention globally at import time. SageAttention only supports head dims 64/96/128, so Hunyuan3D's delight VAE (different head dim) crashes: AssertionError: headdim should be in [64, 96, 128] The fix is NOT patching source — that breaks on every update. Find the culprit and disable that node:

grep -rn "scaled_dot_product_attention\s*=" custom_nodes/

Disabling the offending node folder (rename to .disabled) stops the global pollution permanently.

2. White mesh vs textured mesh confusion. The workflow has TWO Hy3DExportMesh nodes — one geometry-only (intermediate), one textured. If the texture stage crashes partway, you still get the white-mesh GLB and assume "it ran but no color." Always confirm the SECOND export actually executed.

3. attention_mode is baked into shared workflow JSON. Workflows shared online store widget values, including attention_mode. If the original author had SageAttention installed, the JSON ships with attention_mode: sageattn. On a clean install that fails. Open Hy3DModelLoader, set it back to sdpa, re-save the workflow.

4. HuggingFace xet download fails behind some networks. Auto-download of the delight model died with a 401 from the xet CAS server. Workaround:

HF_HUB_DISABLE_XET=1
HF_ENDPOINT=https://hf-mirror.com   # or your preferred mirror

Open source vs commercial — honest take

  • Hunyuan3D-2 (open, free, local): geometry is excellent, fully self-hosted, nothing leaves your machine. Texture baking is the weak point — usable but artifact-prone.
  • Meshy (commercial): texture + auto-rig is a clear tier above. Trade-off: subscription + uploading your input.

They're complementary. Portfolio/demo → open-source geometry is plenty. Polished deliverable → the commercial texture pass earns its keep.

Notes

  • On RTX 5090 (sm_120 Blackwell) you need current PyTorch + CUDA — older prebuilt wheels won't load.
  • custom_rasterizer and the mesh painter extension need compiling from source; not hard, just set TORCH_CUDA_ARCH_LIST="12.0+PTX" first.

Happy to answer workflow questions in the comments.

reddit.com
u/Kindly_Gift4836 — 2 days ago

TIL why some Lottie files are 70 MB — and what it took to actually compress one

A designer sent me a Lottie file that was 70 MB. Not a video, a JSON file.

Turns out when designers use PNG frame sequences in After Effects, Bodymovin base64-embeds every frame directly into the JSON. A 5-second animation at 30fps is 150 PNGs stuffed inside one file. Standard Lottie optimizers don't touch this — they only optimize vector paths, not embedded raster images.

The fix that actually worked: decode the embedded PNGs, re-encode them as WebP (~80% smaller, same visual quality), optionally drop frames, then rewrite the animation timeline so playback still matches. Did the whole thing client-side with WebAssembly in a Web Worker so nothing uploads.

The gotcha that cost me a day: WebP method=0 is broken for alpha-channel images — it mangles transparency. You have to force method=2. If you've ever fought transparent WebP, that's why.

Has anyone found a cleaner approach to the embedded-PNG problem? Curious if there's a better re-encoding target than WebP here.

reddit.com
u/Kindly_Gift4836 — 2 days ago
▲ 0 r/rss

Lottie-mini – compress 70MB Lottie animations to under 1MB in-browser

Most online Lottie previewers cap uploads at 5-10 MB and require login.


Built a free one that doesn't:


- .json + .lottie supported
- No size limit
- No signup
- Side-by-side: drop two files to compare versions
- Runs 100% in your browser


https://www.lottie-mini.com/preview
u/Kindly_Gift4836 — 5 days ago
▲ 0 r/rss

Tide-now – 50+ trending sources in one page

https://www.tide-now.com

I kept opening the same 15 tabs every morning — Hacker News, Reddit,

GitHub Trending, Product Hunt, Hugging Face Papers, plus a handful

of Chinese sources (Weibo, Zhihu, 36kr) — so I built a single page

that pulls all of them.

A few things I wanted that I hadn't seen combined elsewhere:

- Cross-source trending: when the same story shows up on multiple

sites, it gets surfaced separately at the top with the source

badges next to it.

- AI summary on hover: hover a headline and a 1-2 sentence summary

appears (1-2s). Users bring their own API key (OpenAI / Anthropic /

Gemini / DeepSeek) via a settings drawer — keys never leave the

browser, summaries are cached server-side by title hash so the

same headline isn't re-summarized for everyone.

- Apple Music charts with multi-region + chart-type segment switcher

in a single card (US / UK / JP / Greater China × Songs / Albums).

Stack is Next.js 16 (App Router, Turbopack), Tailwind v4,

next-intl for en/zh, and better-sqlite3 for cache + summary

memoization. Deployed on Vercel, behind Cloudflare DNS.

No login, no tracking beyond Vercel Analytics, no paywall.

AdSense is pending review so ad slots are blank for now.

Source list is in src/sources/ — adding a new feed is one ~30-line

file. Happy to take suggestions for what to add.

u/Kindly_Gift4836 — 5 days ago