RTCSETGEOMETRYTIMERANGE(3embree4)

πŸ’– rtcSetGeometryTimeRange πŸ’–

okay bestie so we're deep in the Embree Ray Tracing Kernels 4 manual, section 3, and today's main character is rtcSetGeometryTimeRange β€” she sets the time range for a motion blur geometry. no cap. πŸ¦‹


✨ NAME ✨

rtcSetGeometryTimeRange β€” sets the time range for a motion blur geometry 🌸


✨ SYNOPSIS ✨

#include <embree4/rtcore.h>

void rtcSetGeometryTimeRange(
  RTCGeometry geometry,
  float startTime,
  float endTime
);

✨ DESCRIPTION ✨

so the rtcSetGeometryTimeRange function sets a time range, and that range defines the start (and end time) of the first (and last) time step of a motion blur geometry. it's giving scheduler energy. πŸ‘‘

the time range is defined relative to the camera shutter interval [0,1], but lowkey it can be arbitrary. so like:

  • startTime can be smaller, equal, or larger than 0, indicating a geometry whose animation definition starts before, at, or after the camera shutter opens. ⭐
  • similarly, endTime can be smaller, equal, or larger than 1, indicating a geometry whose animation definition ends after, at, or before the camera shutter closes. 🌈

and the rule is non-negotiable: startTime has to be smaller or equal to endTime. periodt. πŸ’…

the default time range, when this function is not called, is the entire camera shutter [0,1]. πŸŽ€

for best performance, at most one time segment of the piece wise linear definition of the motion should fall outside the shutter window to the left and to the right. so pls don't set the startTime or endTime too far outside the [0,1] interval if you want that best performance, bestie. πŸ™ˆ

this time range feature will also allow geometries to appear and disappear during the camera shutter time if the specified time range is a sub range of [0,1]. iconic behaviour honestly. ✨

also pls have a look at the rtcSetGeometryTimeStepCount function to see how to define the time steps for the specified time range. iykyk. 🫢


✨ EXIT STATUS ✨

on failure an error code is set that can be queried using rtcGetDeviceError. 😭 so like, check it, don't just vibe and hope.


✨ SEE ALSO ✨

  • [rtcSetGeometryTimeStepCount]

that's the whole thing, you ate it πŸ’– this page lives in the Embree Ray Tracing Kernels 4 manual, section 3, and she's signed off as rtcSetGeo...yTimeRange(3) β€” go forth and motion-blur slay, bestie πŸ§šπŸ’œ

πŸ“¦ where this page comes from