storepush_video_context(3)
πΈ storepush_video_context β Arcan Lua API π
okay bestie, so this one lives in the Arcan Lua API manual (section 3, for the uninitiated β¨), and it's genuinely one of the cutest little context tricks in the whole vidsys toolbox. let's get into it π«Ά
β¨ NAME β¨
storepush_video_context β literally renders your current video context into an object, and then pushes the context. two things, one call, main character energy π
π SYNOPSIS π
contextind, newvid
storepush_video_context()
so yeah, it takes no arguments (lowkey iconic of it) and hands you back two things: a contextind and a newvid. no cap π
π¦ DESCRIPTION π¦
okay so here's the vibe: the whole storepush/storepop family of functions is basically the regular push/pop context functions, but with a little gift with purchase π
the twist? the new context comes with an object inside its storage, and that object is a screenshot of the previous context. that's it, that's the whole personality. the way that it just... takes a picture of where you were before you jump somewhere new? obsessed π
so if push/pop is "save my spot," storepush/storepop is "save my spot and scrapbook it." periodt π
π EXAMPLE π
here's the whole thing in action, copied exactly so you can vibe with it:
function storepush_video_context0()
a = fill_surface(100, 100, 0, 255, 0);
b = fill_surface(100, 100, 255, 0, 0);
show_image({a, b});
move_image(b, VRESW - 100, VRESH - 100);
c = storepop_video_context();
show_image(c);
move_image(c, 50, 50, 50);
move_image(c, 0, 0, 50);
end
two surfaces, one green and one red π©π₯, both popped on screen, b yeeted down to the bottom-right corner with VRESW - 100 and VRESH - 100, then c comes back from storepop_video_context() carrying that screenshot. then we show it and move it around like it's nothing. ate π₯
π§ SEE ALSO π§
go read those too, bestie, they're the whole friend group and they make way more sense together π
that's the whole page, iykyk π β this one's from vidsys, dated October 2026. mwah, go screenshot something pretty πΈπ¦β¨
π¦ where this page comes from
- nixos 26.05: arcan 0.7.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms