RTCUPDATEGEOMETRYBUFFER(3embree3)

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

πŸ’– rtcUpdateGeometryBuffer β€” bestie, your buffer just got a glow-up notification ✨

okay so real talk, this one's from the Embree Ray Tracing Kernels 3 manual, section 3embree3, and the page is literally called rtcUpdateGeometryBuffer (the header just squishes it down to rtcUpdate...etryBuffer because manpage titles have no room for the full main-character name, tragic honestly πŸ’…).


🌸 NAME 🌸

rtcUpdateGeometryBuffer β€” tells the geometry that a buffer view it's holding onto has been modified, like a little "hey bestie, I changed something" tap on the shoulder 🫢


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <embree3/rtcore.h>

void rtcUpdateGeometryBuffer(
  RTCGeometry geometry,
  enum RTCBufferType type,
  unsigned int slot
);

✨ DESCRIPTION ✨

So here's the vibe. The rtcUpdateGeometryBuffer function marks the buffer view that's bound to the specified buffer type and slot (those are the type and slot arguments, bestie) of a geometry (that's the geometry argument, obviously) as modified. Marked. Flagged. Notified. Periodt. πŸ’–

If a data buffer gets changed by the application β€” like you went in there and edited it yourself β€” then the rtcUpdateGeometryBuffer call must be invoked for that buffer. Not "should", not "would be nice if", must. No cap.

Here's the little detail that saves you work though: each buffer view assigned to a buffer slot is initially marked as modified already. So this function only needs to be called when you're doing buffer modifications after the first rtcCommitScene. First commit? You're already covered, gorgeous. 🌈

🌟 tl;dr vibe check: touch a buffer after rtcCommitScene β†’ call rtcUpdateGeometryBuffer or Embree will not know. iykyk.

πŸ’€ EXIT STATUS πŸ’€

On failure, an error code gets set, and you can go query it with rtcGetDeviceError. Not me checking the error code every single time πŸ™ˆ but you should, fr fr.


πŸ‘‘ SEE ALSO πŸ‘‘

  • [rtcNewGeometry]
  • [rtcCommitScene]

and that's the whole page, angel πŸŽ€ go forth and mark your buffers as modified, the Embree Ray Tracing Kernels 3 crew is rooting for you πŸ’œ (the footer is just the page title rtcUpdate...etryBuffer(3) again, section 3, no date on this one β€” iconic, mysterious, we love a low-effort footer ✨)

πŸ“¦ where this page comes from