SoMouseButtonEvent(3)
π SoMouseButtonEvent(3) π
okay bestie, sit down, we're learning about SoMouseButtonEvent π
this is a page from the Library Functions Manual and it's literally all about mouse buttons in Coin. yes, that Coin. the Coin 3D library. stay with me π«Ά
β¨ NAME β¨
SoMouseButtonEvent β the class that holds all the tea about mousebutton interaction π±οΈβ¨
πΈ SYNOPSIS πΈ
#include <Inventor/events/SoMouseButtonEvent.h>
Inherits SoButtonEvent. yes, it's giving nepo baby but make it useful π
π Public Types
enum Button { ANY, BUTTON1, BUTTON2, BUTTON3, BUTTON4, BUTTON5 }
Public Types inherited from SoButtonEvent:
enum State { UP, DOWN, UNKNOWN }
π¦ Public Member Functions
virtual SoType getTypeId (void) const
SoMouseButtonEvent (void)
virtual ~SoMouseButtonEvent ()
void setButton (Button button)
Button getButton (void) const
Public Member Functions inherited from SoButtonEvent:
SoButtonEvent (void)
virtual ~SoButtonEvent ()
void setState (State state)
State getState (void) const
Public Member Functions inherited from SoEvent:
SoEvent (void)
virtual ~SoEvent ()
SbBool isOfType (SoType type) const
void setTime (const SbTime t)
SbTime getTime (void) const
void setPosition (const SbVec2s &p)
const SbVec2s & getPosition (void) const
const SbVec2s getPosition (const SbViewportRegion &vpRgn) const
const SbVec2f getNormalizedPosition (const SbViewportRegion &vpRgn) const
void setShiftDown (SbBool isDown)
SbBool wasShiftDown (void) const
void setCtrlDown (SbBool isDown)
SbBool wasCtrlDown (void) const
void setAltDown (SbBool isDown)
SbBool wasAltDown (void) const
β Static Public Member Functions
static SoType getClassTypeId (void)
static void initClass (void)
static SbBool isButtonPressEvent (const SoEvent *e, Button whichButton)
static SbBool isButtonReleaseEvent (const SoEvent *e, Button whichButton)
static SbBool enumToString (Button enumval, SbString &stringrep)
Static Public Member Functions inherited from SoButtonEvent:
static SoType getClassTypeId (void)
static void initClass (void)
static SbBool enumToString (State enumval, SbString &stringrep)
Static Public Member Functions inherited from SoEvent:
static SoType getClassTypeId (void)
static void initClass (void)
π Detailed Description π
so the SoMouseButtonEvent class contains information about mousebutton interaction. that's the whole vibe, no cap.
when you press any buttons on the mouse, these get translated from a system specific event into a Coin event, and then they get sent to the scenegraph by using instances of this class. it's giving main character energy for your clicks π₯
See also π«Ά
SoEvent, SoButtonEvent, SoSpaceballButtonEvent, SoKeyboardEvent
SoEventCallback, SoHandleEventAction
π Member Enumeration Documentation π
enum SoMouseButtonEvent::Button
this enum contains all mouse buttons detected by Coin. every single one, we're not leaving anybody out π
Enumerator:
ANYβ unknown button. it's a mystery, we don't know her πBUTTON1β first mouse button (usually the leftmost button).BUTTON2β second mouse button (usually the middle button).BUTTON3β third mouse button (usually the rightmost button).BUTTON4β fourth mouse button (typically from a wheelmouse). heads up bestie: this is not part of the original Open Inventor API πBUTTON5β fifth mouse button (typically from a wheelmouse). again, this is not part of the original Open Inventor API π
π§ Constructor & Destructor Documentation π§
SoMouseButtonEvent::SoMouseButtonEvent (void )
constructor. she's born β¨
SoMouseButtonEvent::~SoMouseButtonEvent () [virtual]
destructor. she's leaving, and honestly, slay π
π Member Function Documentation π
SoType SoMouseButtonEvent::getTypeId (void ) const [virtual]
returns the actual type id of an instantiated object. like, who is she? now you know π
reimplemented from SoButtonEvent.
void SoMouseButtonEvent::initClass (void ) [static]
initialize the type information data. get her set up, periodt.
void SoMouseButtonEvent::setButton (SoMouseButtonEvent::Button buttonarg)
set the value of the button which the user interacted with.
this method is used from the window specific device classes when translating events to the generic Coin library. iykyk π«Ά
See also: getButton()
SoMouseButtonEvent::Button SoMouseButtonEvent::getButton (void ) const
returns the value of the button which was pressed or released.
See also: getState()
wasShiftDown(), wasCtrlDown(), wasAltDown(), getPosition(), getTime()
SbBool SoMouseButtonEvent::isButtonPressEvent (const SoEvent * e, SoMouseButtonEvent::Button whichButton) [static]
convenience method for quickly checking if the given event is a press on the given button, whichButton. quick lil vibe check on your clicks β
See also: isButtonReleaseEvent(), isOfType(), getButton(), getState()
SbBool SoMouseButtonEvent::isButtonReleaseEvent (const SoEvent * e, SoMouseButtonEvent::Button whichButton) [static]
convenience method for quickly checking if the given event is a release of the given button, whichButton. the letting-go moment π
See also: isButtonPressEvent(), isOfType(), getButton(), getState()
SbBool SoMouseButtonEvent::enumToString (Button enumval, SbString & stringrep) [static]
converts from an enum value of type SoMouseButtonEvent::Button to a string containing the enum symbol. enum β string, glow up complete π¦
this function is an extension for Coin, and it is not available in the original SGI Open Inventor v2.1 API. so don't go looking for it there bestie π Since: Coin 3.0
π Author π
generated automatically by Doxygen for Coin from the source code. not a human, not a girlie, just a doc generator doing her thing π€β¨
and that's the whole page, no notes π this was Coin, Version 3.1.3, SoMouseButtonEvent(3), and the date is whatever Doxygen felt like stamping that day πΈ mwah, go click something iconic π
π¦ 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