SoMFVec2s(3)
π SoMFVec2s π
ok so this is the SoMFVec2s(3) page, straight out of the Library Functions Manual, and bestie we are going to get you fluent in it. no cap. π
π NAME π
SoMFVec2s β the class that is literally a container for SbVec2s vectors. that's the whole job. she holds your 2D short vectors. icon behaviour. π
β¨ SYNOPSIS β¨
#include <Inventor/fields/SoMFVec2s.h>
Inherits SoMField. (so she's got the whole multi-value family tree behind her, we love a legacy moment πΈ)
π«Ά Public Member Functions
virtual SoType getTypeId (void) constβ hands you the type id, the little name tag that says this is the Coin field class she belongs tovirtual void copyFrom (const SoField &field)β copy the value(s) over fromfieldconst SoMFVec2s & operator= (const SoMFVec2s &field)β assignment, girl math but for fieldsvirtual SbBool isSame (const SoField &field) constβ are the types and values the same? yes or no babesSbVec2s operator[] (const int idx) constβ index into it like an array, so satisfyingconst SbVec2s * getValues (const int start) constβ pointer to the values array, starting atstartint find (SbVec2s value, SbBool addifnotfound=0)β go looking forvalue, and ifaddifnotfoundis truthy, add it when it's not therevoid setValues (const int start, const int num, const SbVec2s *newvals)β drop innumvalues fromnewvalsat indexstartvoid set1Value (const int idx, SbVec2s value)β set exactly one vector atidxvoid setValue (SbVec2s value)β collapse the whole field down to a single vectorSbVec2s operator= (SbVec2s val)β assign a singleSbVec2sin, slaySbBool operator== (const SoMFVec2s &field) constβ equality check against anotherSoMFVec2sSbBool operator!= (const SoMFVec2s &field) constβ the opposite of that, obviously πSbVec2s * startEditing (void)β begin editing, get your hands on the raw datavoid finishEditing (void)β and we're done editing, close it outvoid setValuesPointer (const int num, const SbVec2s *userdata)β point atnumof yourconst SbVec2sdata instead of copying, data sharing eravoid setValuesPointer (const int num, SbVec2s *userdata)β same thing, non-constSbVec2s *void setValuesPointer (const int num, const short *userdata)β same thing but the userdata is aconst short *void setValuesPointer (const int num, short *userdata)β and the plainshort *versionvoid setValues (int start, int num, const short xy[][2])β setnumvector array elements fromxy, starting at indexstartvoid set1Value (int idx, short x, short y)β set the vector atidxfrom a pair of shortsvoid set1Value (int idx, const short xy[2])β set the vector atidxfrom ashort[2]void setValue (short x, short y)β make this field hold exactly one vector with these element valuesvoid setValue (const short xy[2])β same energy, but from an array
π Public Member Functions inherited from SoMField
virtual ~SoMField ()int getNum (void) constvoid setNum (const int num)virtual void deleteValues (int start, int num=-1)virtual void insertSpace (int start, int num)SbBool set1 (const int index, const char *const valuestring)void get1 (const int index, SbString &valuestring)virtual void enableDeleteValues (void)virtual SbBool isDeleteValuesEnabled (void)
π¦ Public Member Functions inherited from SoField
virtual ~SoField ()void setIgnored (SbBool ignore)SbBool isIgnored (void) constvoid setDefault (SbBool def)SbBool isDefault (void) constSbBool isOfType (const SoType type) constvoid enableConnection (SbBool flag)SbBool isConnectionEnabled (void) constSbBool connectFrom (SoEngineOutput *master, SbBool notnotify=0, SbBool append=0)SbBool appendConnection (SoEngineOutput *master, SbBool notnotify=0)void disconnect (SoEngineOutput *engineoutput)SbBool isConnectedFromEngine (void) constSbBool getConnectedEngine (SoEngineOutput *&master) constSbBool connectFrom (SoField *master, SbBool notnotify=0, SbBool append=0)SbBool appendConnection (SoField *master, SbBool notnotify=0)void disconnect (SoField *field)SbBool isConnectedFromField (void) constSbBool getConnectedField (SoField *&master) constint getNumConnections (void) constint getForwardConnections (SoFieldList &slavelist) constint getConnections (SoFieldList &masterlist) constvoid disconnect (void)SbBool isConnected (void) constvoid setContainer (SoFieldContainer *cont)SoFieldContainer * getContainer (void) constSbBool set (const char *valuestring)void get (SbString &valuestring)SbBool shouldWrite (void) constvirtual void touch (void)virtual void startNotify (void)virtual void notify (SoNotList *nlist)SbBool enableNotify (SbBool on)SbBool isNotifyEnabled (void) constvoid addAuditor (void *f, SoNotRec::Type type)void removeAuditor (void *f, SoNotRec::Type type)int operator== (const SoField &f) constint operator!= (const SoField &f) constvirtual void connectionStatusChanged (int numconnections)SbBool isReadOnly (void) constvirtual void fixCopy (SbBool copyconnections)virtual SbBool referencesCopy (void) constvoid copyConnection (const SoField *fromfield)virtual SbBool read (SoInput *in, const SbName &name)virtual void write (SoOutput *out, const SbName &name) constvirtual void countWriteRefs (SoOutput *out) constvoid setFieldType (int type)int getFieldType (void) constSbBool getDirty (void) constvoid setDirty (SbBool dirty)void evaluate (void) const
β Static Public Member Functions
static void * createInstance (void)static SoType getClassTypeId (void)static void initClass (void)
π Static Public Member Functions inherited from SoMField
static SoType getClassTypeId (void)static void initClass (void)
π Static Public Member Functions inherited from SoField
static void initClass (void)static void initClasses (void)static SoType getClassTypeId (void)
π Protected Member Functions
virtual void deleteAllValues (void)virtual void copyValue (int to, int from)virtual int fieldSizeof (void) constvirtual void * valuesPtr (void)virtual void setValuesPtr (void *ptr)virtual void allocValues (int num)
π Protected Member Functions inherited from SoMField
SoMField (void)virtual void makeRoom (int newnum)
π Protected Member Functions inherited from SoField
SoField (void)void valueChanged (SbBool resetdefault=1)virtual void evaluateConnection (void) constvirtual SbBool readConnection (SoInput *in)virtual void writeConnection (SoOutput *out) constSbBool isDestructing (void) const
π§ Protected Attributes
SbVec2s * values
π Protected Attributes inherited from SoMField
int numint maxNumSbBool userDataIsUsed
π Additional Inherited Members
Public Types inherited from SoField
enum FieldType { NORMAL_FIELD = 0, EVENTIN_FIELD, EVENTOUT_FIELD, EXPOSED_FIELD }
π Detailed Description π
Bestie, listen. The SoMFVec2s class is a container for SbVec2s vectors. That's the assignment. π
Where does she get used? Anywhere nodes, engines or other field containers need to store an array of vectors with two elements. That's her whole moment. π
She also supports application data sharing through a setValuesPointer() method. If you wanna know how to actually use that function, go read the SoMField documentation β it's all in there. π«Ά
See also
SbVec2s,SoSFVec2s
Since
- Coin 2.5 (she's a Coin 2.5 girlie, vintage but make it cute π)
π οΈ Member Function Documentation π οΈ
β¨ SoType SoMFVec2s::getTypeId (void ) const [virtual] β¨
Returns the type identification instance which uniquely identifies the Coin field class the object belongs to. It's her government name, basically. π
See also
getClassTypeId(),SoType
Implements SoField.
β¨ void SoMFVec2s::copyFrom (const SoField & f) [virtual] β¨
Copy value(s) from f into this field. Heads up though: f must be of the same type as this field. no mixing, no matching, periodt.
Implements SoField.
β¨ SbBool SoMFVec2s::isSame (const SoField & f) const [virtual] β¨
Check for equal type and value(s). both or nothing. π€
Implements SoField.
β¨ void SoMFVec2s::deleteAllValues (void ) [protected], [virtual] β¨
π¨ This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Like, stay out of the kitchen bestie, this one's not for you.
Implements SoMField.
β¨ void SoMFVec2s::copyValue (int to, int from) [protected], [virtual] β¨
This method is used for moving values around internally within a multivalue field. It needs to be overridden in each field so it automatically takes care of running copy constructors where necessary. Very behind-the-scenes, very stage crew energy. π
Implements SoMField.
β¨ const SbVec2s * SoMFVec2s::getValues (const int start) const [inline] β¨
Returns a pointer to the values array. π«΄β¨
References SoMField::num.
β¨ void SoMFVec2s::setValues (int start, int numarg, const short xy[][2]) β¨
Set num vector array elements from xy, starting at index start.
References SoMField::maxNum, SoMField::num, and SoField::valueChanged().
β¨ void SoMFVec2s::set1Value (int idx, short x, short y) β¨
Set the vector at idx. one vector, two shorts, done. π
β¨ void SoMFVec2s::set1Value (int idx, const short xy[2]) β¨
Set the vector at idx. (yes bestie, same thing, different argument shape πΈ)
β¨ void SoMFVec2s::setValue (short x, short y) β¨
Set this field to contain a single vector with the given element values. just the one. main character, solo. π
β¨ void SoMFVec2s::setValue (const short xy[2]) β¨
Set this field to contain a single vector with the given element values. same vibe, array flavour. π
References SoMField::setNum().
βοΈ Author βοΈ
Generated automatically by Doxygen for Coin from the source code. (not a human, just a robot doing her little documentation dance π€π)
ok and that's the whole page bestie!! πβ¨
cute little sign-off for you: this one came from Coin, Version 2.5.0, dated alongside SoMFVec2s(3) β so if you ever need to cite your sources, you know exactly where she's from. now go forth and store your two-element short vectors, you absolute icon. ππ¦πΈπ«Άπ
π¦ where this page comes from
- fedora 43: Coin2-devel 2.5.0-52.fc43 Β· GPL-2.0-only
- fedora 43: Coin2-devel 2.5.0-52.fc43 Β· GPL-2.0-only
- fedora 44: Coin2-devel 2.5.0-54.fc44 Β· GPL-2.0-only
- fedora 44: Coin2-devel 2.5.0-54.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