RTCSETGEOMETRYUSERDATA(3embree3)

πŸ“¦ version 3.13.5, in epel 9, fedora 43, fedora 44

✨ NAME ✨

rtcSetGeometryUserData β€” sets the user-defined data pointer of the geometry πŸ’«

This is page 3 of the Embree Ray Tracing Kernels 3 manual, and bestie, we're about to make your geometry hold onto your stuff.


πŸŽ€ SYNOPSIS πŸŽ€

#include <embree3/rtcore.h>

void rtcSetGeometryUserData(RTCGeometry geometry, void* userPtr);

πŸ’… DESCRIPTION πŸ’…

Okay so. rtcSetGeometryUserData</p> sets the user-defined data pointer (that's the userPtr argument, hi bestie πŸ‘‹) for a geometry (that's the geometry argument, obviously).

The vibe here: that user data pointer is meant to point at your application's own representation of the geometry. Like, your little object, your struct, your whole situation. Then Embree passes that pointer along to various callback functions. So when a callback fires, your app can reach inside and grab its own geometry representation β€” no cap, that's literally the entire point. πŸ”₯

And if you ever need to ask "hey, what pointer did I set earlier?" β€” rtcGetGeometryUserData is right there. Use it to query an already set user data pointer of a geometry. πŸ¦‹


🫢 EXIT STATUS 🫢

If it fails, an error code gets set, and you can go query it with rtcGetDeviceError. So like, check your errors, bestie, don't just assume it slayed. 😭


🌸 SEE ALSO 🌸

  • [rtcGetGeometryUserData]

And that's the whole page, periodt. πŸ’– This iconic little entry lives in the Embree Ray Tracing Kernels 3 manual β€” rtcSetGeometryUserData(3), main character energy only, go set some user data and thrive. πŸ‘‘πŸŒˆ

πŸ“¦ where this page comes from