SoDebugError(3)
π SoDebugError π
okay bestie, welcome to SoDebugError(3) β a page from the Coin manual, which is the whole 3D-graphics-library thing. this is the tea on Coin's internal debugging message-passing mechanism. grab a snack, we're going in π
β¨ NAME β¨
SoDebugError β the class that is the internal debugging message passing mechanism. that's the whole vibe. periodt.
β¨ SYNOPSIS β¨
#include <Inherits SoError.h>
wait no β let me not play myself, the actual line is:
#include <Inventor/errors/SoDebugError.h>
Inherits SoError.
πΈ Public Types πΈ
enum Severity { ERROR, WARNING, INFO }
πΈ Public Member Functions πΈ
virtual SoType getTypeId (void) constSoDebugError::Severity getSeverity (void) const
π Public Member Functions inherited from SoError π
virtual ~SoError ()const SbString & getDebugString (void) constSbBool isOfType (const SoType type) const
πΈ Static Public Member Functions πΈ
static void setHandlerCallback (SoErrorCB *const function, void *const data)static SoErrorCB * getHandlerCallback (void)static void * getHandlerData (void)static SoType getClassTypeId (void)static void post (const char *const source, const char *const format,...)static void postWarning (const char *const source, const char *const format,...)static void postInfo (const char *const source, const char *const format,...)static void initClass (void)
π Static Public Member Functions inherited from SoError π
static void setHandlerCallback (SoErrorCB *const func, void *const data)static SoErrorCB * getHandlerCallback (void)static void * getHandlerData (void)static SoType getClassTypeId (void)static void post (const char *const format,...)static SbString getString (const SoNode *const node)static SbString getString (const SoPath *const path)static SbString getString (const SoEngine *const engine)static void initClass (void)static void initClasses (void)
πΈ Protected Member Functions πΈ
virtual SoErrorCBPtr getHandler (void *&data) const
π Protected Member Functions inherited from SoError π
void setDebugString (const char *const str)void appendToDebugString (const char *const str)void handleError (void)
πΈ Additional Inherited Members πΈ
- Static Protected Member Functions inherited from
SoErrorstatic void defaultHandlerCB (const SoError *error, void *userdata)
π DESCRIPTION π
okay so. SoDebugError is the internal debugging message passing mechanism. that's literally it, that's the thesis statement, iconic π
but the way that it works is it's basically serving two purposes:
- it's the message interface through which error and warning conditions get passed to the programmer who's using the Coin library API to build applications. these messages show up when API methods are used in an incorrect manner, or if actions on the library have caused it to enter an inconsistent state. so Coin programmers can then quickly trace down errors in their application code. slay, honestly.
for this service to actually be available, the Coin library must be compiled with debugging information. for release builds, most of this "programmer's safety net" gets removed β to gain maximum speed and to use minimum space (build the smallest possible library). so if you're on a release build and wondering where your nice little messages went: that's why, bestie, don't come for me.
- Coin application programmers can call the
SoDebugErrormethods inside their own code as a convenient way of debugging application code, replacing the usual cascades offprintf()calls. no cap.
Coin also supports an environment variable to set conditional breakpoints. the COIN_DEBUG_BREAK environment variable can be set to any number of functions, in the form of a list separated by commas or spaces. the function names must be given as "classname::functionname" (i.e. without return type, parenthesis or argument types or names). if a debug message is posted from one of those functions, your program will be stopped (using assert(0)).
this is highkey useful if you want to get core-dumps or enter a debugger whenever, for instance, a warning or an error is posted from some function (e.g. "SbVec3f::normalize"). but heads up: this feature is only enabled in the debug version of Coin. π
π MEMBER ENUMERATION DOCUMENTATION π
π¦ enum SoDebugError::Severity π¦
specifies the available severity levels of the debug messages. the roster, if you will:
Enumerator
ERRORβ severity level for errors.WARNINGβ severity level for warnings.INFOβ severity level for additional information.
π¦ MEMBER FUNCTION DOCUMENTATION π¦
void SoDebugError::setHandlerCallback (SoErrorCB *const function, void *const data) [static]
this method sets the error handler callback for messages posted via this class. main character move.
note that this will not override the error/debug message handler for subclasses β those will have to be overridden by calling the subclass' setHandlerCallback() method. so don't @ me when your subclass doesn't listen, it's giving "i told you".
See also: defaultHandlerCB()
SoErrorCB * SoDebugError::getHandlerCallback (void ) [static]
returns the error handler callback for messages posted via this class. the getter to the setter's setter energy. π
void * SoDebugError::getHandlerData (void ) [static]
this method returns the pointer used for passing data back to the callback handler method. it's the lil messenger pigeon ποΈ
SoType SoDebugError::getClassTypeId (void ) [static]
this static method returns the SoType for this class.
See also: getTypeId()
SoType SoDebugError::getTypeId (void ) const [virtual]
this method returns the SoType of a particular object instance. the individual SoType, not the class one. very specific of it.
See also: getClassTypeId()
Reimplemented from SoError.
SoDebugError::Severity SoDebugError::getSeverity (void ) const
returns severity level of current message.
you can use this to filter out debug messages and only let warnings and/or errors pass through to the end-user, if you have set your own handler callback. literally the vibe check for messages β¨
See also: setHandlerCallback()
void SoDebugError::post (const char *const source, const char *const format, ...) [static]
this method posts a message with severity level "ERROR". source should be the name of the calling function. π¨
void SoDebugError::postWarning (const char *const source, const char *const format, ...) [static]
this method posts a message with severity level "WARNING". source should be the name of the calling function. β οΈ
void SoDebugError::postInfo (const char *const source, const char *const format, ...) [static]
this method posts a message with severity level "INFO". source should be the name of the calling function. βΉοΈ
void SoDebugError::initClass (void ) [static]
this method takes care of initializing all static data for the class. the setup era. π±
SoErrorCB * SoDebugError::getHandler (void *& data) const [protected], [virtual]
this is just a convenience wrapper around the getHandlerCallback() and getHandlerData() methods. two-for-one, we love a bundle deal π«Ά
Reimplemented from SoError.
π AUTHOR π
Generated automatically by Doxygen for Coin from the source code. (yes, a robot wrote the original. i just gave it a personality. you're welcome.)
okay that's the whole page, bestie, you ate it up πβ¨
Version 4.0.10 β Thu Jun 25 2026 00:00:00 β SoDebugError(3)
mwah π go debug something iconic.
π¦ 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