SbCondVar(3)
π SbCondVar(3) π
ok so bestie, we're in the Library Functions Manual and today's main character is SbCondVar β yes it's giving "my brain hurts" but honestly? it's iconic once you get it. π§
β¨ NAME β¨
SbCondVar β a class for synchronizing access to global variables. no cap, that's literally its whole job. π
β¨ SYNOPSIS β¨
#include <Inventor/threads/SbCondVar.h>
πΈ Public Member Functions πΈ
SbCondVar (void)
~SbCondVar (void)
SbBool wait (SbMutex &mutex)
SbBool timedWait (SbMutex &mutex, SbTime period)
void wakeOne (void)
void wakeAll (void)
π¦ Detailed Description π¦
A class for synchronizing access to global variables.
ok so picture this: condition variables are the thing you use to protect global variables when you've got multiple threads running concurrently. it's the group chat moderator of your code, fr fr. π
π Constructor & Destructor Documentation π
π SbCondVar::SbCondVar (void ) [inline] π
Constructor. it's born β¨
π SbCondVar::~SbCondVar (void ) [inline] π
Destructor. it's gone π (but respectfully)
π Member Function Documentation π
β SbBool SbCondVar::wait (SbMutex & mutex) [inline] β
This method blocks the calling thread until another thread calls wakeOne() or wakeAll() on the SbCondVar object. like bestie is literally sitting there waiting for a text back. π
β SbBool SbCondVar::timedWait (SbMutex & mutex, SbTime period) [inline] β
This method blocks the calling thread until another thread calls wakeOne() or wakeAll() on the object β but if that does not happen within period, the thread is woken again anyways. it's giving "if you don't reply in 20 mins i'm moving on". π«Ά
TRUE is returned when the thread wakes because either wakeOne() or wakeAll() was called, FALSE is returned if the wait times out. so true = they texted back, false = you gave up. π
β void SbCondVar::wakeOne (void ) [inline] β
This method wakes up one of the threads waiting on this SbCondVar. just one. singular. the chosen one. π
β void SbCondVar::wakeAll (void ) [inline] β
This method wakes up all the threads waiting on this SbCondVar. everyone's invited to the function, periodt. π₯
π Author π
Generated automatically by Doxygen for Coin from the source code. (yes the robots wrote this one, we just gave it a glow-up. π€β¨)
lowkey reminder: this whole thing is about threads and mutexes, so if you're out here changing global variables from multiple threads with no cond var, that's not a vibe check, that's a race condition. protect your globals bestie. π
ok bye, love you, go read the source π
this has been Coin, Version 3.1.3, SbCondVar(3) β mwah, catch you on the next manpage ππ¦
π¦ where this page comes from
- fedora 43: Coin3-devel 3.1.3-40.fc43 Β· GPL-2.0-only
- fedora 43: Coin3-devel 3.1.3-40.fc43 Β· GPL-2.0-only
- fedora 44: Coin3-devel 3.1.3-42.fc44 Β· GPL-2.0-only
- fedora 44: Coin3-devel 3.1.3-42.fc44 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms