rendertarget_id(3)

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

πŸ’– NAME πŸ’–

okay so bestie, welcome to rendertarget_id(3) from the Arcan Lua API ✨ β€” the function that assigns a numeric identifier to a rendertarget. That's it, that's the gig. πŸ’…

πŸ¦‹ SYNOPSIS πŸ¦‹

id or nil
rendertarget_id( vid:rtgt )
rendertarget_id( vid:rtgt, int:id )

πŸŽ€ DESCRIPTION πŸŽ€

This one is intended for rendering cases where a shader needs to distinguish between the destination rendertarget. The example the page gives is stereoscopically rendering a side-by-side packed textured source without manually managing multiple pipelines. Iconic, honestly. 🌈

So what do you do? Create two rendertargets β€” one via define_rendertarget and the other via define_linktarget β€” then give each one a unique identifier with the help of this function, rendertarget_id. After that, write your shader so it does the distinction via the builtin int uniform rtgt_id. Periodt. πŸ’œ

There are two forms of this function, and they're exactly what they sound like: one retrieves the current identifier, and the other updates it. If the vid specified with rtgt does not exist, nil will be returned. No cap, that's the rule. 😭

🌈 SEE ALSO 🌈

  • targetcontrol

that's the page, bestie 🫢 β€” source/version: Arcan Lua API, date: October 2026, and the star of the show is rendertarget_id(3). mwah πŸ’‹

πŸ“¦ where this page comes from