mirror of
https://github.com/Comfy-Org/comfy-remote-nodes.git
synced 2026-11-04 23:37:22 +00:00
[PR #14] [MERGED] feat(model_3d): add client-side MODEL_3D decoder + capability advertisement #14
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Comfy-Org/comfy-remote-nodes#14
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Comfy-Org/comfy-remote-nodes/pull/14
Author: @Kosinkadink
Created: 5/16/2026
Status: ✅ Merged
Merged: 5/16/2026
Merged by: @Kosinkadink
Base:
main← Head:feat/client-model-3d-decoder📝 Commits (1)
58d93dafeat(model_3d): add client-side MODEL_3D decoder + capability advertisement📊 Changes
5 files changed (+391 additions, -15 deletions)
View changed files
📝
client.py(+9 -0)➕
notes/run_model3d_decoder.py(+316 -0)📝
protocol.py(+14 -3)📝
proxy_node.py(+19 -8)📝
serialization.py(+33 -4)📄 Description
Closes the loop on the just-merged comfy-rnp-server PR #37 which added the four Tripo / Rodin 3D providers and the
Capability.MODEL_3D_GLB_INLINEtoken. Without this client-side half the providers were unreachable from any RNP client — descriptors would fail negotiation because the proxy_node didn't advertise the token.Client changes (all inside
ComfyUI/custom_nodes/comfy_remote_nodes)protocol.py— mirror the newCapability.MODEL_3D_GLB_INLINEconstant and add"model_3d"toHEAVY_TYPESsois_enveloperecognises inbound 3D-model envelopes. The vendoredprotocolmodule is the single source of truth for the proxy_node and serialization layers; both already consumeis_envelope/decode_envelope_datafrom here.serialization.py— adddecode_model3d_envelopethat hands raw GLB bytes tocomfy_api.latest._util.File3DviaBytesIO, mirroring the existingdecode_video_envelopeshape. Onlyglb_inlineis accepted today; any other encoding surfacesRnpProtocolError(code=INTERNAL)as defence-in-depth so a future encoding never silently downgrades to garbage bytes. Registered in the_DECODERSdispatch table and re-exported via__all__.proxy_node.py— add"MODEL_3D" -> IO.File3DGLB.Outputto_OUTPUT_CLASSESso descriptors withoutput=["MODEL_3D"]parse to a real socket. The descriptor io_type string is the logical name"MODEL_3D"(consistent across vendors) — the resulting V3 Output carries the upstream"FILE_3D_GLB"comfytype tag fromIO.File3DGLBso frontend-side socket matching works against any GLB-aware downstream node (preview3d / SaveGLB / Load3D).client.py— advertiseCapability.MODEL_3D_GLB_INLINEinCLIENT_CAPABILITIESso servers gate provider descriptors on the presence of the token. Legacy clients that don't advertise it still see NEGOTIATION_FAILED at descriptor-load time (safe degradation), not a parse error at execute.Smoke test (
notes/run_model3d_decoder.py)Covers:
HEAVY_TYPESincludes"model_3d".is_enveloperecognises a MODEL_3D envelope.decode_model3d_enveloperound-trips a minimal valid GLB (binary glTF 2.0, magicb"glTF").decode_envelopedispatchestype=model_3dto the new decoder.RnpProtocolError.make_model3d_envelopehelper — server packs, client decodes, bytes match.proxy_node._OUTPUT_CLASSEScontract:"MODEL_3D" -> IO.File3DGLB.Output.client.CLIENT_CAPABILITIESadvertisesCapability.MODEL_3D_GLB_INLINE.No server-side changes. The 4 just-shipped Tripo / Rodin providers (
TripoTextToModelApi_RNP,TripoImageToModelApi_RNP,TripoMultiviewToModelApi_RNP,Rodin3DRegularApi_RNP) are now reachable end-to-end from ComfyUI.First of four cross-cutting RNP/1 protocol PRs in leverage order:
Amp-Thread-ID: T-019e3314-4336-71d2-a333-6d1e33a9986e
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.