target_framemode(3)

πŸ“¦
version 0.7.1 Β· 2 versions
, in nixos 26.05

πŸ’… target_framemode (the Arcan Lua API one, bestie)

Okay so real talk β€” target_framemode is literally just a lil hint you whisper to a frameserver like "hey babe, maybe don't send me everything?" πŸŽ€ It's from the Arcan Lua API, and it's giving "polite request, not a demand" energy.


✨ SYNOPSIS ✨

nil
target_framemode( tgtid, skipval, prewake, preaud, skipdbg1, skipdbg2 )

Returns nil β€” it's not here to hand you anything back, it's here to communicate. 🫢


🌸 DESCRIPTION 🌸

Some frameservers can literally be told to ignore transferring frames whose deadlines they have no hope of matching β€” like, why send a frame that's already late, bestie? πŸ’€ So you call target_framemode and pass a skipval, and here's the whole menu, no cap:

  • -1 ( NONE ) β€” always deliver every single frame, stalling if necessary. Every frame is the main character. πŸ‘‘
  • 0 ( AUTO ) β€” the frameserver itself is responsible for only delivering relevant frames. It's a whole "you know what's best, go off" situation. ✨
  • 0 < n <= 9 ( STEP n ) β€” only process every n frames, and retain the clock. Slay, but make it periodic. 🌈
  • 9 < n < * ( FASTFWD ) β€” only process every n (n - 9) frames, and fast forward the clock. Yes, that's literally the arithmetic, don't come for me. πŸ”₯

Then there's prewake β€” that one determines how far in advance of the next deadline frame generation should begin. Basically giving the frameserver a head start so it's not scrambling at the last second like me before a deadline 😭.

And preaud forcibly desynchs the A/V clock by n frames, which lowkey sounds chaotic but it's literally there so you can allow for some buffering. Buffering is iconic, periodt. πŸ¦‹

Oh and skipdbg1 / skipdbg2 β€” if these get set to > 0, random() jitter sleeps get inserted before generation and before transmission, so you can troubleshoot or optimize timing in the main process. Pure debugging vibes, iykyk. πŸ’…


πŸŽ€ NOTES πŸŽ€

  1. Switching skipmode may force an audio buffer flush. Not me dropping the beat mid-flush πŸ™ˆ β€” just know it can happen.
  2. Only libretro follows this pattern at the moment, but the decode and hijack libraries will be updated to include support. hijack and decode will also β€” (and yes, the original page just trails off right there like a text you left on read πŸ’€, so I'm leaving it exactly as it is, fr fr).

Ngl bestie, this is a hint API β€” you're suggesting, not commanding. And those skipdbg1/skipdbg2 jitter sleeps are debug tooling, so don't be surprised when your timing looks weird on purpose. 🌸

And that's the whole page! πŸ’– This was target_framemode(3), from the Arcan Lua API, signed off in the footer by targetcontrol, October 2026 β€” stan a consistent release cycle. 🧚 ⭐

πŸ“¦ where this page comes from