agent (cont.)

+0:58
  • read_file{"EndLine":1442,"Path":"~/work/lowmarch/docs/portrait-guide.md","StartLine":614}

    input

    {
      "EndLine": 1442,
      "Path": "~/work/lowmarch/docs/portrait-guide.md",
      "StartLine": 614
    }

    result, 595 lines

    Partial read (lines 614-1413 of 1442). Showing bytes 0-46080 of 62750 in this line range, truncated at the 46080-byte limit. To read the rest of this line range, call this tool again with the same StartLine and EndLine and ByteOffset=46080.
    614: 
    615: **Why the VRoid bases limit us** (the user asked why the enemies all looked alike):
    616: - The eight samples are one face mesh and two body meshes.
    617: - VRoid's body sliders are baked in on export, so the files carry expression morphs only.
    618: - The eyes, brows and mouth are anime drawings in textures, so moving the skull under them changes
    619:   little.
    620: - Bone scaling inflates limbs like tubes; it can't add muscle, fat or a hunch.
    621: 
    622: **The test:** MakeHuman's CC0 base mesh and targets (`docs/makehuman.md`), converted by
    623: `tools/makehuman.py` into a VRM-shaped file so the whole pipeline runs unchanged.
    624: - **Macro targets** (gender, age, muscle, weight, height, proportions) blend as MakeHuman blends them:
    625:   each slider has anchors, and the weight of a combined target is the product of its sliders'
    626:   weights. Named targets take -1..1 for an incr/decr pair; an `l-` name applies to both sides.
    627: - **The rig:** joints are the default rig's head positions, taken from the morphed joint helpers.
    628:   The weights are mapped onto VRoid's J_Bip names, which suits the rig, the clips and the costume kit.
    629: - **The rest pose:** arms are rotated to horizontal, the forearms straightened, the palms twisted
    630:   down (thumb forward) and the fingers aligned with the hand; legs are straight. It is then turned to
    631:   face -z, in metres, with every bone's rest rotation identity.
    632: - **The parts:** the face mask (head skin in front of a plane 3 cm behind the eyes) is split from the
    633:   body, as VRoid's is. The eyes are stylised by us: the eyeball as the white, an iris cap with a
    634:   painted greyscale iris and a highlight disc, a tapered lid line along the lash helper's root,
    635:   smoothed brow strips, and a lip line.
    636: 
    637: **Result** (three bodies in the soldier kit, in the lineup beside the VRoid soldier):
    638: - **Bodies:** a big win. The youth, the stocky veteran and the brute are clearly different people;
    639:   the brute is broad and massive where the VRoid "huge" build was only tall.
    640: - **Faces:** the bone structure and age now read (jaw, cheekbones, nose, eye bags).
    641: - **Still rough:** the stylised eyes are small, and the faces read pale and flat without painted
    642:   detail. The lip line breaks into dashes. Hair is a plain crop.
    643: - **Also:** the kettle hat sits lower on these heads, over the eyes (as Unicorn Overlord's fighters
    644:   wear it).
    645: 
    646: ### 17 · VRoid heads on MakeHuman bodies, 2026-10-09
    647: 
    648: **Why:** the user found the MakeHuman faces realistic, not anime, and the arms odd. No free base has
    649: both anime faces and real body variety under a licence we can ship (MB-Lab's anime bases are AGPL;
    650: CharMorph's and Quaternius's are realistic or simple). So the head comes from VRoid and the body from
    651: MakeHuman (`spec["head"]`, `makehuman.graft()`).
    652: 
    653: **The graft:**
    654: - **Scale and place:** the VRoid head is scaled so crown-to-chin matches the MakeHuman head
    655:   (`head_scale` on top), pivots on the body's head bone, and is lowered until the chins meet. VRoid's
    656:   head bone sits lower in its head, so pivot alone left a long neck. The eye bones move to VRoid's.
    657: - **The neck:** VRoid doesn't stitch head to neck. The body's neck tube runs up inside the head and
    658:   the face's lower edge tucks against it. We do the same: MakeHuman's neck takes VRoid's neck section
    659:   above the point where the neck enters the head, and eases from its own shape below. A thick neck and
    660:   VRoid's slim one meet halfway: the head's outer shell (face skin, hair, never the mouth inside it)
    661:   widens near the neck to match, fading out upward. Stitching rings with a band failed: VRoid's
    662:   head/neck seam slopes, so a level cut tore the ring.
    663: - **What goes:** MakeHuman's own face and jaw, which is anything in front of the neck above its chin.
    664:   If any of it stays, it pokes through the VRoid face as white shards around the mouth.
    665: - **One body buffer:** the pipeline reads every body-skin primitive as indices into the first one's
    666:   vertices, as VRoid's share a buffer. VRoid's skull skin therefore joins the MakeHuman body buffer.
    667:   As a separate primitive, its indices were read against the wrong vertices and drew long triangles
    668:   across the collar, and the shirt cut from them crumpled.
    669: 
    670: **Arms:** the weird arms were the soldier's puffed sleeve, sized for VRoid's thin arm and mostly buried
    671: in MakeHuman's realistic one. Only its fold ripples poked through, and they read as muscle. `gear.puff`
    672: now sizes the puff from the arm's measured thickness as well as its length. On MakeHuman bodies,
    673: sleeves and trousers span the hollows between muscles (`fitting.limb_hull`: each limb segment's
    674: cloth goes out to its convex hull, fading near the joints). Both leave VRoid bodies as they were.
    675: 
    676: **Also fixed:** the face-length preset slid every skin vertex below the eyes, including the neck and
    677: body, after the clothes were fitted. It now moves the body only as far as its head weight. On the
    678: gaunt VRoid veteran, the neck had been dropping 1.9 cm out from under the collar.
    679: 
    680: **Lessons:**
    681: - When skin shows through cloth, find out whether it's the geometry or the renderer (`?mode=3d` on a
    682:   sheet), then whether the garment has holes (its boundary loops), before tuning offsets.
    683: - Asymmetric damage on a symmetric body means bad data, not bad tuning.
    684: 
    685: ### 18 · The body workshop, after an outside critique, 2026-10-09
    686: 
    687: The user still found the MakeHuman arms odd, the neck join wonky in places, and the older faces young.
    688: A second model (Fable) critiqued the renders against the Unicorn Overlord study. The six MakeHuman
    689: soldiers (three men, three women) now have their own page (`LOWMARCH_SITE=mh-workshop` for
    690: `build.py` and `sheets.py`; its roster and notes are in `build.WORKSHOPS`).
    691: 
    692: **Arms:**
    693: - **The puff was the "muscle".** Sized for VRoid's thin arm, it was buried in MakeHuman's realistic
    694:   one, and only its fold ripples poked through the sleeve. The `cap` puff (on MakeHuman bodies):
    695:   - a shoulder cap, widest at the top and fuller at the back, wider than the arm by at least a third;
    696:   - five folds converging on a leather band above the elbow, the band traced round the sleeve itself;
    697:   - the shirt sleeve tucked inside it.
    698: - **Arms sank into broad sides.** `shape["arm_out"]` holds them out; `build.arm_room()` picks the
    699:   smallest angle that clears the body in the reference pose and the idle.
    700: - **Hands were splayed paddles.** `shape["curl"]` relaxes the fingers wherever a pose leaves them alone.
    701: - **Cloth followed every muscle.** `fitting.limb_hull` pushes sleeves, trousers and boots (toes included)
    702:   out to each segment's convex hull.
    703: 
    704: **Neck:**
    705: - **The ring under the chin** was our own throat cut open, plus MakeHuman's chin left inside VRoid's.
    706:   Now the throat stays, MakeHuman's chin goes, and the throat is drawn back onto VRoid's neck line.
    707: - **The head's lower edge** widens only at the back and sides, and takes the neck's normals where it
    708:   overlaps, so the two shade alike.
    709: - **The shirt** has a straight, sloped neckline (`wrap(cut=...)` plus a hem on the same plane). The coif
    710:   covers the nape.
    711: - **Removing VRoid's face strip under the jaw** (`strip_reach`) was a wrong turn: the hole let the head
    712:   chart sink inside the jaw, and beards went with it.
    713: 
    714: **Faces (age, the study's way):**
    715: - `strip_blush`: VRoid's cheek and eye-corner blush off.
    716: - `face_lines`: a few strokes drawn into a copy of the face texture. They are laid out in 3D from the
    717:   face's landmarks, dropped onto the face from the front, and mapped to texture space.
    718: - `iris`: smaller irises.
    719: - Expression shapes: VRoid's angry eye (a straight heavy lid), a little of the smile eye (it raises the
    720:   lower lid), and the mouth turned down.
    721: - **Hair and beards now follow the face presets' reshaping.** A widened jaw used to cover the beard
    722:   built on it.
    723: - **The moustache** is placed from the mouth on MakeHuman units. A long face put the old fixed angle on
    724:   the chin.
    725: 
    726: **Also:** a "Neck and collar" row on every check sheet; `?mode=3d` on a sheet (geometry or shading?); a
    727: collar crumple that turned out to be our bug: the pipeline reads all body skin as one vertex buffer.
    728: 
    729: **Still open** (critique): trousers like tights; breastplate a bib on wide chests; a stiff idle; no
    730: puffs on big men (a sleeve per build); beards as a solid shape.
    731: 
    732: ### 19 · Sleeves and a polearm guard after the study's soldiers, 2026-10-09
    733: 
    734: Side by side with the Unicorn Overlord soldiers (`~/.local/share/lowmarch/study/uo_soldier_arms*.png`,
    735: study only), the user saw that their arms show no muscle at all, and four differences in how ours
    736: were built:
    737: - **Their whole sleeve is loose,** fullest round the elbow. Ours puffed at the shoulder and went tight,
    738:   and that bump read as a bicep. `gear.loose_sleeves` now lets the shirt's own sleeves out: little at
    739:   the shoulder, most round the elbow and above the gauntlet, less on the side toward the body, a little
    740:   more behind, with six soft folds that turn down the arm and deepen toward the cuff. No puff, no band.
    741: - **Their gauntlets reach almost to the elbow** and flare; the sleeve bags into them. `cuffs(length=0.70)`,
    742:   and `gear.tuck_sleeves` pulls the sleeve inside the cuff's inner face (binned by angle and distance
    743:   along the forearm). The shirt is subdivided once so the folds have vertices to sit on.
    744: - **No band on the upper arm.** Theirs have none.
    745: - **Both hands on the weapon.** `clips.polearm` (cast entries get `stance="polearm"` for classes in
    746:   `cast.POLEARMS`): a low guard, left foot forward, the shaft across the body with the head forward and
    747:   up. The right fist is placed from the right shoulder in arm lengths (fixed offsets from the hips fit
    748:   one build and put the brute's hand in his hip). The left fist holds the shaft where a set reach from
    749:   the left shoulder meets it, so every build keeps bent elbows instead of a fixed hand spacing that a
    750:   short arm can't span. Both arms grip with `duel.clear_grip`, trying elbow directions until they clear
    751:   the body. The attack draws back and thrusts on a lunge, both hands on throughout.
    752: - **Lean from the hips.** Bending the spine for the thrust pushed the breastplate's hem through the belt;
    753:   most of the lean is now a hip tilt.
    754: - The halberd's rear hand moved to 0.5 m from the butt (it was 0.8: a long tail behind the soldier).
    755: 
    756: Garment-through-plate flags dropped from up to 30 mm in workshop v1 to 8 mm at most (the brute's
    757: reference pose aside).
    758: 
    759: ### 20 · Breeches, solid beards, a skirt that hangs, a measured grip and a studied idle, 2026-10-09
    760: 
    761: **Outfits (the rest of the critique):**
    762: - **Breeches** (`gear.breeches`): the trousers let out like the sleeves (`_let_out` and `_tuck`, now shared
    763:   by arms and legs through `_limb_frame`), fullest above the boot top and bagging into it, less on the inner
    764:   thigh; the boot tops stand off the shin (`flare_boots`). The women wear tights and boots to above the knee
    765:   (`mobs.soldier_f`), as the study draws them.
    766: - **Breastplate** `arm=64`: the armhole scoop starts later, so the plate reaches the armpits.
    767: - **Solid beards**: `outline_plate(thickness=f(u, v, s, t))` fills a beard down to the face; the fall under
    768:   the chin is one spade-shaped mass (three locks read as a ruff, a wide block as a bib).
    769: - **The scale skirt** (`skirt_cone(clear=...)`) hangs from the waist over what it covers: the tightest
    770:   outline that starts at the waist and clears the trousers below (an upper concave hull down each line).
    771:   Sized from the waist alone, the seat came through the back; stepping straight out to the seat, it
    772:   stood off like a shelf (a TorsoChart fills the rows above what it measured with the nearest row's
    773:   radius, so the trousers' hips read as present right up at the waist: those rows are ignored). In the
    774:   guard it follows the thighs (`share=0.15`), and `slim_under` draws the
    775:   trousers in where it hides them: a stiff skirt and a striding thigh otherwise always meet somewhere.
    776: - The layer check's "up to N mm" now measures only the points it counts (it included rim hits it had
    777:   thrown out, so a 4 mm problem read 17).
    778: 
    779: **The grip.** A weapon's shaft went through a fixed point near the wrist, tuned on one VRoid hand. On the
    780: soldiers' scaled hands and MakeHuman's own, it was 3.5 to 8 cm off: the shaft ran over the knuckles and the
    781: fingers closed under it. `rig.grip_points` measures the hole: each finger's joints and fingertip in the
    782: fist pose fitted with a circle across the palm; the weapon (`gear._hand_frame`, through `fit.grip`) and the
    783: clips (`clips.fists`) both use it.
    784: 
    785: **The idle, after a study.** One clean animated idle from the study (a mercenary), tracked patch by patch
    786: (`~/.local/share/lowmarch/study/uo_idle*`, study only):
    787: - a loop of about 2 s; the feet planted, the knees nearly still;
    788: - the hips sink about 2% of the figure's height and the chest about twice that, forward as they sink, and
    789:   the upper body rocks back as it rises (the back shoulder dips as the front one rises);
    790: - uneven timing: a slow rise (about 0.7 s), a short hold, a quicker sink (about 0.4 s), a longer settle;
    791: - the arms ride on the torso; the weapon's tip dips as the body sinks, so it swings the most.
    792: `clips.polearm` now samples that loop every 0.1 s (`GUARD_TOP`, `GUARD_LOW`, `IDLE_SINK`, eased between
    793: points), the shaft a beat behind, the head kept level, and grips both hands afresh at every sample so they
    794: stay on the shaft in between. The check sheets have an "Idle loop" row (one side, six moments).
    795: A battle clip with soldiers in formation was too small and dithered to measure.
    796: 
    797: ### 21 · Base spike, 2026-10-09
    798: 
    799: **Why:** the user saw that the base decides how many kinds of character we can make, and asked what else
    800: there is besides VRoid and MakeHuman. The candidates were researched (licence first), then the plausible
    801: ones were put in the same soldier kit on their own page (`LOWMARCH_SITE=base-spike`; the `spk_` cast
    802: entries). Each was judged on a checklist:
    803: 1. a licence we can ship;
    804: 2. body variety without bone-scaling;
    805: 3. faces that can read as Unicorn Overlord, vary with age and structure, and have no seam;
    806: 4. pipeline fit (rig, kit, clips);
    807: 5. the overall read against MakeHuman with a VRoid head.
    808: 
    809: **Results:**
    810: - **MakeHuman + VRoid head** (the baseline):
    811:   - still the only anime read;
    812:   - the youth's ring under the chin is still there;
    813:   - face variety stops at VRoid's two heads plus presets.
    814: - **MakeHuman's own head pushed toward anime** (`cast._anime`: MakeHuman's face targets for bigger, lower
    815:   eyes, a small nose and mouth and a narrower chin; `face_round`, rounded face normals; heavier lines):
    816:   - no seam;
    817:   - real structure and age (a 15- and a 70-year-old);
    818:   - still a pale mask with small eyes. MakeHuman's eye targets scale a realistic opening, and an anime eye
    819:     is a drawn shape bigger than the opening. `face_round` 0.75 flattened the face too far.
    820:   - MakeHuman has 34 CC0 expression units (`targets/expression/units`) that the converter doesn't use yet.
    821: - **Quaternius Universal Base Characters** (CC0; `tools/quaternius.py`, `docs/quaternius.md`):
    822:   - **Bodies:** the free pack has only the two "superhero" bodies, each fixed.
    823:   - **Faces:** a painted Western face with no face shapes, about 7.8 heads tall.
    824:   - **Fit:** it converts in one step onto our rig (`makehuman.straighten`, `settle` and `write`, now shared).
    825:   - **Arms:** the man's wide lats put an arm 2.1 cm into the body through the guard idle.
    826:   - **Plates:** the breastplate copies the sculpted abs and back muscles.
    827:   - **Animations:** its CC0 animation libraries share the skeleton and could serve any base.
    828: - **Blender Studio base meshes** (CC0): unrigged sculpting bases with no shape keys. The stylized pair are
    829:   5.5-6-head caricatures, the wrong direction for a "stylize" target.
    830: - **Anny:** MakeHuman's mesh and targets as a PyTorch library; our converter already reads the same targets.
    831: 
    832: **Measuring proportions:** crown to chin by the pipeline's own landmark (the face mask's lowest midline
    833: point). A front-profile search for the chin was unreliable: it found chests and collars.
    834: 
    835: **Verdict:** keep MakeHuman for bodies. The next head experiment would warp VRoid's face mask (drawn eyes,
    836: brows, mouth and expression shapes) by landmarks onto MakeHuman's skull, keeping MakeHuman's structure and
    837: age with VRoid's drawing and no neck seam.
    838: 
    839: ### 22 · VRoid Studio driven from WSL, and MakeHuman's mass on a VRoid body, 2026-10-09
    840: 
    841: **The driver** (`tools/winvroid`, after mcp-vroid's Linux driver, MIT):
    842: - **How it works:** VRoid Studio runs on Windows, and WSL drives it through `powershell.exe`:
    843:   - `V.cs` is compiled once and does capture, input and window queries;
    844:   - `ocr.ps1` uses Windows' own OCR.
    845: - **Capture:** `PrintWindow` returns a blank client for Unity's DirectX window, so the screen is captured
    846:   instead, and VRoid must be uncovered.
    847: - **Pointer:** Unity reads raw mouse input. A cursor moved by `SetCursorPos` never hovers, so scroll wheels
    848:   did nothing; absolute `SendInput` moves fixed it.
    849: - **Safety:** input is refused unless the foreground window belongs to VRoid's process.
    850: - **Quirks found:**
    851:   - The first click on a sample downloads it; a second opens it.
    852:   - The export dialog writes VRoid's default licence fields into our copy.
    853:   - A new character won't export until Title and Creator are filled.
    854:   - OCR reads "Title" as "Titte".
    855:   - VRoid's "height" slider is stored as `figureSlender*`, and extrapolates hard: -1.5 made an 81 cm figure.
    856: - **Export without clothes:** VRoid Studio 2.14 deletes the body skin its own clothes cover (Base_Male, an
    857:   older export, has its full skin). Our costume is shaped from the skin, so a clothed export lost its
    858:   chest, shoulders and upper arms. The driver now removes tops, bottoms and shoes first
    859:   (`winvroid.outfit_none`: each Outfit category's first tile is "none").
    860: - **The `.vroid` project:** a ZIP whose `v1model/data.bin` is protobuf. Each slider is a pair of shape keys
    861:   with float weights, and keys at 0 are left out. It is readable; writing projects directly is possible
    862:   but untried.
    863: 
    864: **What VRoid lacks for heavy and muscular bodies:** mass. Its body keys change length, width and scale only,
    865: and it has none for regional volume. Its clothing must follow every body key, which is probably why there
    866: are few.
    867: 
    868: **Mass carried across** (`tools/mass.py`):
    869: - **Method:** MakeHuman's muscle and weight are mapped region by region onto a VRoid model's body:
    870:   - limbs by distance along the bone and angle round it;
    871:   - the torso by height between the hip and shoulder joints and angle round the vertical;
    872:   - the neck fading below the head.
    873: - **Blending:** regions blend by skin weights; hands, feet and head are left alone. The outward part is
    874:   scaled by VRoid's thickness against MakeHuman's.
    875: - **The output:** a copy of the VRM with only the body mesh's positions and normals replaced. VRoid's
    876:   clothes share that mesh's vertices and move with it.
    877: - **Scale:**
    878:   - MakeHuman's macros alone are mild: maximum weight adds about 3 cm at the waist.
    879:   - The regional muscle and fat targets do the work, at gain 2.6. At 1.4, the loose sleeves hid it.
    880: - **Open:**
    881:   - The guard puts an arm into wide bodies, as it did with Quaternius.
    882:   - The figures keep Base_Male's height and face.
    883: 
    884: ### 23 · The armory, and proportions held by code, 2026-10-09
    885: 
    886: **Why:** iterating on whole costumed, animated soldiers took minutes per try and hid the bodies. The user
    887: asked for an armory instead: bodies, heads and hair as separate parts, T-posed and bare, to assemble into
    888: archetypes later. Faces should be original in Unicorn Overlord's style; copies of its characters are only
    889: study-only benchmarks.
    890: 
    891: **The armory page** (`LOWMARCH_SITE=armory`; the cast's `arm_` entries):
    892: - **Pose:** built in the T-pose (the portrait's pose is `{}`), so the reference pose shown everywhere is
    893:   the T-pose.
    894: - **Skipped:** clips (every one holds the pose) and the arm and garment checks.
    895: - **Costume:** plain shorts, plus a band for women (`mobs.underwear`), which keep all the skin
    896:   (`fit.keep_skin = ("J_Bip",)`).
    897: - **Sheet rows:** T-pose round, head, joins (`ARMORY_ROWS`).
    898: - **Speed:** the whole page rebuilds in about 15 s.
    899: - **The list:** characters with a `group` show in one dropdown with sections.
    900: 
    901: **Proportions** (`docs/proportions.md`, `tools/proportions.py`):
    902: - **Source:** 16 figures and 8 faces from the study, landmarks placed by eye on ruled crops, raw data in
    903:   the study folder.
    904: - **Targets:** per archetype (young, adult, heavy, generic). The face unit (chin to eye line) is the base
    905:   measure, since hair hides the skull's top.
    906: - **Measured on our model files:** heads tall, eye line, eye opening, face width, crotch height,
    907:   shoulder, hip and waist widths, arm, hand and foot length, and thighs crossing the midline (tearing).
    908:   The armory build lists each body's ratios that miss its archetype in the checks panel.
    909: - **Findings:**
    910:   - Generic units are about 6 heads with short legs; heroes run 6.5 to 9.5.
    911:   - Our bodies are too tall in heads and narrow for the heavy and generic builds.
    912:   - VRoid's bodies are narrow with short arms, though their faces pass.
    913:   - MakeHuman's own heads set the eyes too high in the head (the "realistic" read).
    914:   - The massed VRoid bodies' thighs cross by about 4 cm: the tearing.
    915: 
    916: **VRoid sample export:** `python3 tools/winvroid/winvroid.py samples` exports pixiv's 26 samples into
    917: `vroid/samples_2_14/` (resumable; it stops when VRoid loses the foreground). That keeps them apart from
    918: the older D–G, which are other characters and back the hunter and the thief.
    919: 
    920: ### 24 · Bodies fitted by code, and the faults behind the armory's shoulders, 2026-10-10
    921: 
    922: **Why:** in the first armory nearly every body had wrong shoulders and too much distance from the neck to
    923: the chest, some had chest holes, head sizes didn't match, and the VRoid bodies with MakeHuman's mass were
    924: torn. Each fault is now held by a measurement and a fix in code.
    925: 
    926: **Shoulders and neck:**
    927: - **What was wrong:** MakeHuman's neck is long. The chin sat 0.52 to 0.58 head heights above the shoulder
    928:   joints, where VRoid's bodies sit at 0.30 to 0.36. The trapezius ran in a long ramp from the jaw to arms
    929:   set low.
    930: - **What wasn't:** the collarbones. MakeHuman's already slope 6 to 10 degrees down and out, like VRoid's.
    931:   Lifting them in the straightening (`clavicle_lift`, kept) flattens the ramp but shrugs the shoulders.
    932: - **The fix:** the neck is fitted with MakeHuman's own controls (`neck-scale-vert`, then
    933:   `measure-neck-height`).
    934: - **New measures** (`proportions.py`): `neck_hd`, `clav_deg`, `drop_hd`, taken from the joints. The skin's
    935:   top above a thick arm is the arm.
    936: 
    937: **The fitter** (`tools/fit.py`, see `docs/proportions.md`): each ratio moves the MakeHuman control behind
    938: it, the head is sized in closed form, and the figure is scaled back to its design height.
    939: 
    940: **What a short neck broke in the head graft**, all fixed:
    941: - **The jaw cut:** it took any skin in front of the neck above MakeHuman's chin. Two consequences:
    942:   - It took the trapezius' top on a short neck. Only skin bound to the head (`jaw_hw`, 0.9) goes now.
    943:   - It took the throat's top, half head and half neck, and opened a gap under VRoid's chin. The same
    944:     threshold fixes this.
    945: - **The neck's radius:** it's now measured from the neck bone's skin only. Mid-neck had moved down into
    946:   the trapezius' flare, so the radius read too thick.
    947: - **The throat stitch:** it switched to VRoid's section on a hard 60-degree edge, which left a box on the
    948:   throat. It now eases in with the angle.
    949: - **Fixed distances:** the graft's distances (the chin search, the neck ring, the taper) now scale with
    950:   `body_scale`. A 1.2 times bigger body put the chin outside the search window, and the head came out the
    951:   wrong size.
    952: 
    953: **The inspection underwear:**
    954: - **Notches at the waistband:** they came from skin triangles crossing the hem line, which were dropped,
    955:   leaving gaps as deep as a triangle (3 cm on MakeHuman's hips). The shorts now take triangles past the
    956:   hems and clamp everything onto the hem planes (`wrap(..., clamp=True)`). They also push back out what a
    957:   hem pulls into the skin (`refloor=True`). Both are off by default, so finished costumes don't drift.
    958: - **Holes:** they came from skin weighted to bones outside the list. The shorts take every bone but the
    959:   arms'.
    960: - **Skin coming through:** the skin well inside the shorts is hidden (`fit.drop_skin`). It must leave
    961:   the arms alone: the costume is fitted with the arms hanging beside the hips, and the first try hid the
    962:   forearms.
    963: 
    964: **Mass on VRoid bodies** (`tools/mass.py`):
    965: - **Rebased:** onto VRoid's own bases, exported unclothed in the PC session (`base_masc.vrm`,
    966:   `base_fem.vrm`).
    967: - **Seams:** VRoid 2's exports split vertices along texture seams, so the move is made on welded
    968:   vertices.
    969: - **Thighs:** each leg's skin eases toward a 3 mm gap at the midline instead of crossing it (was 4 cm).
    970: - **Limbs carry thickness only:** the segment's own joint motion is taken out. MakeHuman's muscular macro
    971:   widens the shoulders, and copying that shift slid the forearm skin past the hands.
    972: - **The torso** takes its own share of the gain (`torso_gain`). At the limbs' 2.6 the lats ballooned.
    973: 
    974: **The PC session:**
    975: - **Exported:** all 26 VRoid samples (A to Z, `vroid/samples_2_14/`, about 95 s each) and both bases,
    976:   unclothed (`winvroid.py bases`).
    977: - **A retry added:** the menu ignores clicks while the editor reloads after an export.
    978: 
    979: ### 25 · VRoid bodies shaped by MakeHuman, their own head kept, 2026-10-10
    980: 
    981: **Why:** the head graft looked like surgery and the heads didn't sit naturally on some bodies, and
    982: MakeHuman's mass carried onto VRoid didn't sculpt well. VRoid's bodies only come in a narrow range and
    983: MakeHuman's realistic bodies don't match an anime head. The spike (`tools/cage.py`) keeps VRoid's whole
    984: model, head included, and takes only the broad shape from a MakeHuman body: MakeHuman gives the range of
    985: builds, VRoid gives the head and the surface.
    986: 
    987: **How it's done** (the details are in `tools/cage.py`):
    988: - **The skeleton goes onto the MakeHuman body's joints:** the limb bones are turned and stretched from
    989:   joint to joint, the spine as one piece. The head, hands and feet are scaled whole, and the head is
    990:   placed by its chin.
    991: - **The wrap:** each body vertex casts a ray along its normal to the MakeHuman skin. The distance is
    992:   smoothed over space, so only broad volumes come across.
    993: - **Untouched:** the head, hands and feet, and every vertex the body shares with the face mesh.
    994: 
    995: **What didn't work, and why:**
    996: - **Shaping by hand with the spec's own controls** (bone thickness, rings, bumps) made fat or boxy
    997:   bodies:
    998:   - Scaling a whole bone's thickness shows as a step wherever its skin weight changes quickly (knees,
    999:     wrists). Scaling the collarbone made a box round the shoulders.
    1000:   - Smooth rings along each limb fixed the steps, but widening a slim body's cross-sections reads as fat,
    1001:     not strong. The trapezius and deltoids are shapes over the top of the shoulder, which rings can't
    1002:     raise.
    1003: - **Nearest points:** for a slim body inside a big one, the nearest reference point usually lies to the
    1004:   side. Cast along the normal instead, and only accept skin facing the same way: without that, a neck
    1005:   whose front is missing (the reference's grafted head) takes its back and pinches the throat.
    1006: - **Smoothing a vector:** it cancels round a limb, because opposite sides point opposite ways. Smooth the
    1007:   distance along the normal instead.
    1008: - **Smoothing by mesh passes:** it isn't the same distance everywhere. VRoid's chest is densely meshed
    1009:   and kept MakeHuman's pec edges as two domes. A Gaussian over real distance is the same everywhere, and
    1010:   the torso gets a wider one than the limbs (3.5 to 4.5 cm against 2 to 2.5).
    1011: - **Stretching short bones one by one:** the 6 cm pelvis bone stretched 2.6 times made a box. The spine
    1012:   stretches as one piece instead.

    195 more lines not shown.