SoTimerSensor(3)
π SoTimerSensor(3) π
okay bestie, sit down, hydrate, because we're about to talk about a sensor that just... keeps going. like clockwork. literally. this is the SoTimerSensor page from the Coin manual (that's section 3 of the manual, the library-functions section, iykyk) β¨
β¨ NAME β¨
SoTimerSensor β the sensor class that triggers at given intervals. she's punctual. she's reliable. she's giving alarm clock but make it C++ π
πΈ SYNOPSIS πΈ
#include <Inventor/sensors/SoTimerSensor.h>
Inherits SoTimerQueueSensor. so yes, she's part of the whole sensor family tree, and everything her ancestors can do, she can do too π
π¦ Public Member Functions
SoTimerSensor (void)
SoTimerSensor (SoSensorCB *func, void *data)
virtual ~SoTimerSensor (void)
void setBaseTime (const SbTime &base)
const SbTime & getBaseTime (void) const
void setInterval (const SbTime &interval)
const SbTime & getInterval (void) const
virtual void schedule (void)
virtual void unschedule (void)
void reschedule (const SbTime &schedtime)
π«Ά Public Member Functions inherited from SoTimerQueueSensor
SoTimerQueueSensor (void)
SoTimerQueueSensor (SoSensorCB *func, void *data)
virtual ~SoTimerQueueSensor (void)
const SbTime & getTriggerTime (void) const
virtual SbBool isScheduled (void) const
π§ Public Member Functions inherited from SoSensor
SoSensor (void)
SoSensor (SoSensorCB *func, void *data)
virtual ~SoSensor (void)
void setFunction (SoSensorCB *callbackfunction)
SoSensorCBPtr getFunction (void) const
void setData (void *callbackdata)
void * getData (void) const
void setNextInQueue (SoSensor *next)
SoSensor * getNextInQueue (void) const
π Additional Inherited Members
Static Public Member Functions inherited from SoSensor:
static void initClass (void)
Protected Member Functions inherited from SoTimerQueueSensor:
void setTriggerTime (const SbTime &time)
Protected Attributes inherited from SoTimerQueueSensor:
SbBool scheduled
Protected Attributes inherited from SoSensor:
SoSensorCB * func
void * funcData
π Detailed Description π
The SoTimerSensor class is a sensor which will trigger at given intervals. no cap, that's the whole vibe.
Use sensors of this class when you want a job repeated at a certain interval, without explicitly needing to reschedule the sensor β i.e. SoTimerSensor automatically reschedules itself after it has been triggered. she's self-sufficient. main character energy fr fr π
SoTimerSensor instances are commonly used to trigger animation updates at a constant frame rate. that's her moment. that's her whole thing. β¨
π Constructor & Destructor Documentation π
SoTimerSensor::SoTimerSensor (void )
Default constructor. Sets up an interval of 1/30th of a second. cute little default, very animation-coded π
SoTimerSensor::SoTimerSensor (SoSensorCB * func, void * data)
Constructor taking as parameters the sensor callback function and the userdata which will be passed to the callback. you hand her a function and a lil data blob, she handles the rest π
See also: setFunction(), setData()
SoTimerSensor::~SoTimerSensor (void ) [virtual]
Destructor. she's done, she's logging off, no more intervals π
π₯ Member Function Documentation π₯
void SoTimerSensor::setBaseTime (const SbTime & baseref)
Set the base trigger time.
If you use this method, the trigger times will be on intervals from the given value.
Without an explicitly set base time, the next trigger invocation after a trigger has happened will be on the current time plus the interval time. Note that this will of course cause the timer to drift. yes bestie, drift. she's wandering. that's just what happens when you don't anchor her down π«
See also: getBaseTime()
const SbTime & SoTimerSensor::getBaseTime (void ) const
Returns the base trigger time.
See also: setBaseTime()
void SoTimerSensor::setInterval (const SbTime & intervalref)
Sets the time interval between each time the sensor triggers.
See also: getInterval()
const SbTime & SoTimerSensor::getInterval (void ) const
Returns the timer trigger interval.
See also: setInterval()
void SoTimerSensor::schedule (void ) [virtual]
Overrides the virtual schedule() method to be able to set up the base time, if this was not done by the user.
If no base time was set, base time will then equal the current time.
See also: unschedule(), isScheduled()
Reimplemented from SoTimerQueueSensor.
void SoTimerSensor::unschedule (void ) [virtual]
Overrides the virtual unschedule() method to handle unschedule() calls during triggering. yes she can cancel herself mid-glow-up, iconic behavior honestly π
Reimplemented from SoTimerQueueSensor.
void SoTimerSensor::reschedule (const SbTime & schedtime)
Set new trigger time based on the given schedule time, and schedules the sensor for triggering. glowed up, rescheduled, back on the calendar β
π Author π
Generated automatically by Doxygen for Coin from the source code. (not a human, not a bestie, just a doc generator doing its lil thing π§)
and that's the whole page, bestie! go forth and schedule your intervals responsibly π β¨
Coin manual, version 4.0.10, dated Thu Jun 25 2026 00:00:00 β mwah, love that for us, see u in the next man page πππ¦
π¦ where this page comes from
- fedora 43: Coin4-devel 4.0.10-1.fc43 Β· BSD-3-Clause AND GPL-3.0-or-later
- fedora 43: Coin4-devel 4.0.10-1.fc43 Β· BSD-3-Clause AND GPL-3.0-or-later
- fedora 44: Coin4-devel 4.0.10-1.fc44 Β· BSD-3-Clause AND GPL-3.0-or-later
- fedora 44: Coin4-devel 4.0.10-1.fc44 Β· BSD-3-Clause AND GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms