Skip to content

LivLiv Player 0.6.0

Choose a tag to compare

@mekoand mekoand released this 23 Nov 11:56
· 17 commits to main since this release

Long hair that swings and rests on the shoulders, feel settings an editor can change while the character plays, an
advanced entry for code that runs the renderer itself, and VRM files from Blender that play. A page written for 0.5
needs no change. What it will see change, all on purpose (below): long hair swings, and long hair lying on the body
moves less with the head; a model whose file sets tuning.blink, expr or mouth plays them; the idle motion
turned back on eases in instead of jumping; and blinks no longer show a see-through iris halfway.

New

  • Feel settings, live. player.tuning is the character's feel settings as it plays (its model's tuning; a frozen
    copy), and player.setTuning(changes) changes some of them without loading the character again: undefined puts
    one back to the model's own, each load starts from the new character's own. On Player and BodyPlayer. Changing
    turn, nod, fringe or hairRest on a model with keyforms measures its key poses again, so it draws exactly as
    it would loaded with those settings. See API.md.
  • blink, expr and mouth from the model's tuning count, as on livliv.ai: how often the idle motion blinks,
    how readily face tracking reads a smile, how far face tracking and live lip sync open the mouth (lip sync's own
    gain multiplies with it). A Host may carry tuning (optional): drivers read it there. A model whose file sets
    them to other than 1 plays differently from 0.5
    ({ "blink": 2, "mouth": 0.5 } blinks twice as often and opens its
    mouth half as far); the featured characters set them to 1 or not at all.
  • load(source, { continueMotion: true }): the same character loaded again (an editor's change) goes on moving
    from its last frame (its springs, the body's lag, the long hair's swing, the expression showing) instead of starting
    again at rest.
  • @livliv-dev/player/runtime, an advanced entry: the renderer (Puppet) and the motion modules, for code that
    runs its own frame loop, with meshes(), rgbaAt() and layersAt() to ask what is drawn where. Outside the
    compatibility promise of the other entries: pin the exact version. See API.md.
  • packageModelJson(paths): which model.json among a package's files is its own, as load() picks it.
  • Format 4.2 (FORMAT.md): tuning.gaze, tuning.fringe,
    tuning.hair_sway and tuning.hair_rest in the schema, all optional. The player read gaze and fringe before, but
    the schema refused a file that had them. The Tuning type is exported.

Changed

  • Blinks without a see-through iris. Halfway through a blink the open eye used to fade out from eye-open 0.2 down
    while the closed eye faded in under it: for a few frames of every blink the iris showed as a grey, see-through smear
    (most on pale irises, and for as long as a face-tracked eye stays half shut). The open eye now stays whole until it is
    squashed to a thin slit and goes in a short step (eye-open 0.06 to 0.03), and the idle motion holds each blink shut
    for 35 ms: the close takes 75 ms and a frame often missed its bottom (a third of the blinks at 60 fps, two in three in
    a 30 fps recording never showed the closed eye); now every one does. Every character blinks this way at default
    settings.
    A frame with the eyes open 0.2 or more, or shut, draws exactly as in 0.5; between 0.08 and 0.05 the open
    eye shows as a thin slit where it used to be a fading smear. Each of the idle motion's blinks ends 35 ms later, so
    its later blinks and small glances fall a little differently. A new switch, player.blinkHandover = false, blinks as
    before (API.md). BodyPlayer (VRM, PNGTuber) is unchanged. In the runtime entry:
    Puppet.blinkHandover, blinkHold on LivelyIdle and IdleDriver (0 unless set), BLINK_HOLD, eyeFade,
    blinkOpen, blinkOver.
  • Long hair swings below the shoulders (#15). Below the jaw, long
    hair used to follow the torso, so its tips moved less than the hair at the shoulders. A gentle pendulum, thrown by the
    head's and the torso's moves and settling by itself, now swings it sideways, more toward the tips (twin tails and
    ponytails included); hair over the body swings less. Characters you already have move this way too: at their
    default settings their hair tips sway when the head turns or the body leans.
    The rest pose is unchanged, and a
    character whose tuning.hairBack (format 4: hair_back) or new hairSway (hair_sway) is 0 draws every frame as
    in 0.5.
  • Long hair lying on the body goes with the body. From the neck down, long hair over the shoulders and chest used to go
    almost wholly with the head, so a large move of the head and the torso together slid it over the clothes and showed
    what it covered between the strands (light clothes in fragments through dark hair, a hard edge along a collar). Where
    hair lies over the body it now takes less of the head's motion and more of the body's; hair beside the body, the bangs
    and the long hair's swing are as before. Characters you already have move this way too: their chest hair moves less
    when the head turns.
    The rest pose is unchanged, and a character whose new tuning.hairRest (format 4:
    hair_rest) is 0 draws every frame as before.
  • VRM files from Blender (#1): a VRM 1.0 whose licence URL is not
    VRM's own (the author's terms page) plays, with that URL in its terms; node constraints that depend on each other in a
    circle are left out with a warning instead of refusing the file; a file that cannot play says why in the exporter's
    terms (bones the humanoid lacks, no meta, a VRM version this player does not read). A .vrm URL given to a Player
    says to use a BodyPlayer.
  • modelFiles() takes names with # and ?, which it refused before, as load() takes them. Its paths stay safe
    to write out: it refuses a name that would leave the package (as opening a .livliv does), and one with a control
    character or :, now from a package too. Its errors name the file.
  • A model's first frame draws everything once, out of sight (Player only): every layer's pictures, the eyes'
    masks, the stencil. Some browsers put off a texture's upload until it is first drawn, so the first blink, glance or
    expression after a load could stall a frame. The renderer underneath has it as a switch (Puppet.prewarm), off.
  • The idle motion going on again doesn't jump. After frames drawn with idle off, it used to go on from where it
    had stopped, in one frame; now it eases in from the pose those frames showed, over 0.4 s. A player whose idle motion
    is never turned off plays exactly as before.
  • The model schema compiles without warnings in ajv's default settings (it logged two); it accepts and refuses the same
    files.
  • The repository's featured characters are livliv.ai's current builds: 13 refreshed, Mochi and Kotaro gone (23). A page
    that loads Mochi or Kotaro from GitHub Pages keeps working: their folders and packages stay there, unlisted.