RTCGETGEOMETRYUSERDATAFROMSCENE(3embree4)
π rtcGetGeometryUserDataFromScene β Embree Ray Tracing Kernels 4 π
okay bestie, gather round, because this one is literally just "hey, what was that lil pointer I stapled to my geometry?" and the answer comes to you through the scene. no cap.
β¨ NAME β¨
rtcGetGeometryUserDataFromScene β returns the user data pointer of the geometry through the scene object π«Ά
πΈ SYNOPSIS πΈ
#include <embree4/rtcore.h>
void* rtcGetGeometryUserDataFromScene(RTCScene scene, unsigned int geomID);
π¦ DESCRIPTION π¦
so. the rtcGetGeometryUserDataFromScene function goes and fetches that user data pointer you already set earlier with rtcSetGeometryUserData, grabbing it off the geometry sitting at index geomID inside the scene you passed in as scene. that's it, that's the whole job π
and if you never called rtcSetGeometryUserData at all? then it just hands you back NULL. no drama, no error, just NULL. iconic behaviour honestly.
now here's the part that's actually the main character moment β¨ β unlike its sibling rtcGetGeometryUserData, the rtcGetGeometryUserDataFromScene function can be used during rendering inside a SYCL kernel. yes queen, from inside the kernel. that's the whole reason this variant exists. iykyk.
π EXIT STATUS π
if something goes wrong, an error code gets set, and you can go peek at it with rtcGetDeviceError. so like, if things are giving nothing, check the error code first, bestie π
π SEE ALSO π
- [
rtcSetGeometryUserData] - [
rtcGetGeometryUserData]
and that's the tea, periodt πβ¨πΈπ¦π
this lil page is from Embree Ray Tracing Kernels 4 (the 3 in the section number is the manual section, not the version, don't @ me) β go forth and query your geometry user data responsibly, queen π
π¦ where this page comes from
- alpine 3.24: embree-doc 4.4.1-r0 Β· Apache-2.0
- arch rolling: embree 4.4.1-1 Β· Apache-2.0
- fedora 43: embree 4.4.1-1.fc43 Β· Apache-2.0
- fedora 44: embree 4.4.1-1.fc44 Β· Apache-2.0
- nixpkgs unstable: embree 4.4.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms