sdf_csg opなし → coordgrid(引数だけで決まる op —— 画像やデータの入力を取らない)import fullseye as fs; fs.ledger.grid_coords(bounds, res) (実装を直接呼ぶなら import sdf_ops; sdf_ops.grid_coords(bounds, res)、台帳から引くなら ops3d.get("grid_coords"))fullseye.ledger.grid_coords(...) は宣言 out 型 coordgrid の値だけを返す(本体は補助情報も返す)。捨てられた側が要るときは fullseye.ledger.grid_coords.raw(...)、または sdf_ops.grid_coords を直接呼ぶ。CSG 評価用のボクセル中心座標グリッドを作る(occupancy と同じ格子規約)。
bounds=((xmin,xmax),(ymin,ymax),(zmin,zmax))、res は各軸のボクセル数(スカラ=立方
or 長さ3)。voxel i の中心は world lo + (i+0.5)/res * span(occupancy.query_distance
の c=(q-lo)/span*res-0.5 と整合 = 中心アライン)。返り値は
coords shape (nx,ny,nz,3) と extent=(xmin,xmax,ymin,ymax,zmin,zmax)。
こうして作った座標に sphere_sdf/box_sdf を評価し CSG 合成すれば、recon3d の
marching cubes や occupancy のゼロ交差抽出へそのまま渡せる。
Raises ValueError for degenerate bounds or res<=0。
py -3.11 examples_3d/gear_metrology.pypy -3.11 examples_3d/molecule_atom_count.pypy -3.11 examples_3d/procedural_hand.pypy -3.11 examples_3d/render_beauty.pypy -3.11 examples_3d/sdf_csg.pypy -3.11 examples_3d/sfm_recon.pycoordgrid を入力に取れる)fuse_to_voxel · sphere_sdf · box_sdf · plane_sdf · cylinder_sdf · torus_sdf · capsule_sdf
sdf_csg)sphere_sdf · box_sdf · plane_sdf · cylinder_sdf · torus_sdf · capsule_sdf · sdf_union · sdf_intersect
Provenance: sdf_ops.py — 3D operator registry. この per-op ノートは tools/opdocs.py md が自動生成(手編集しない)。
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.