.TH "SoField" 3 "Sat Oct 12 2013" "Version 4.0.0a" "Coin" \" -*- nroff -*- .ad l .nh .SH NAME SoField \- .PP The \fBSoField\fP class is the top-level abstract base class for fields\&. .PP Fields is the mechanism used throughout Coin for encapsulating basic data types to detect changes made to them, and to provide conversion, import and export facilities\&. .SH SYNOPSIS .br .PP .PP \fC#include \fP .PP Inherited by \fBSoMField\fP, and \fBSoSField\fP\&. .SS "Public Types" .in +1c .ti -1c .RI "enum \fBFieldType\fP { \fBNORMAL_FIELD\fP = 0, \fBEVENTIN_FIELD\fP, \fBEVENTOUT_FIELD\fP, \fBEXPOSED_FIELD\fP }" .br .in -1c .SS "Public Member Functions" .in +1c .ti -1c .RI "virtual \fB~SoField\fP ()" .br .ti -1c .RI "void \fBsetIgnored\fP (SbBool ignore)" .br .ti -1c .RI "SbBool \fBisIgnored\fP (void) const " .br .ti -1c .RI "void \fBsetDefault\fP (SbBool defaultVal)" .br .ti -1c .RI "SbBool \fBisDefault\fP (void) const " .br .ti -1c .RI "virtual \fBSoType\fP \fBgetTypeId\fP (void) const =0" .br .ti -1c .RI "SbBool \fBisOfType\fP (const \fBSoType\fP type) const " .br .ti -1c .RI "void \fBenableConnection\fP (SbBool flag)" .br .ti -1c .RI "SbBool \fBisConnectionEnabled\fP (void) const " .br .ti -1c .RI "SbBool \fBconnectFrom\fP (\fBSoEngineOutput\fP *master, SbBool notnotify=FALSE, SbBool append=FALSE)" .br .ti -1c .RI "SbBool \fBappendConnection\fP (\fBSoEngineOutput\fP *master, SbBool notnotify=FALSE)" .br .ti -1c .RI "void \fBdisconnect\fP (\fBSoEngineOutput\fP *engineoutput)" .br .ti -1c .RI "SbBool \fBisConnectedFromEngine\fP (void) const " .br .ti -1c .RI "SbBool \fBgetConnectedEngine\fP (\fBSoEngineOutput\fP *&master) const " .br .ti -1c .RI "SbBool \fBconnectFrom\fP (\fBSoField\fP *master, SbBool notnotify=FALSE, SbBool append=FALSE)" .br .ti -1c .RI "SbBool \fBappendConnection\fP (\fBSoField\fP *master, SbBool notnotify=FALSE)" .br .ti -1c .RI "void \fBdisconnect\fP (\fBSoField\fP *field)" .br .ti -1c .RI "SbBool \fBisConnectedFromField\fP (void) const " .br .ti -1c .RI "SbBool \fBgetConnectedField\fP (\fBSoField\fP *&master) const " .br .ti -1c .RI "int \fBgetNumConnections\fP (void) const " .br .ti -1c .RI "int \fBgetForwardConnections\fP (\fBSoFieldList\fP &slavelist) const " .br .ti -1c .RI "int \fBgetConnections\fP (\fBSoFieldList\fP &masterlist) const " .br .ti -1c .RI "void \fBdisconnect\fP (void)" .br .ti -1c .RI "SbBool \fBisConnected\fP (void) const " .br .ti -1c .RI "void \fBsetContainer\fP (\fBSoFieldContainer\fP *cont)" .br .ti -1c .RI "\fBSoFieldContainer\fP * \fBgetContainer\fP (void) const " .br .ti -1c .RI "SbBool \fBset\fP (const char *valuestring)" .br .ti -1c .RI "void \fBget\fP (\fBSbString\fP &valuestring)" .br .ti -1c .RI "SbBool \fBshouldWrite\fP (void) const " .br .ti -1c .RI "virtual void \fBtouch\fP (void)" .br .ti -1c .RI "virtual void \fBstartNotify\fP (void)" .br .ti -1c .RI "virtual void \fBnotify\fP (\fBSoNotList\fP *nlist)" .br .ti -1c .RI "SbBool \fBenableNotify\fP (SbBool on)" .br .ti -1c .RI "SbBool \fBisNotifyEnabled\fP (void) const " .br .ti -1c .RI "void \fBaddAuditor\fP (void *f, \fBSoNotRec::Type\fP type)" .br .ti -1c .RI "void \fBremoveAuditor\fP (void *f, \fBSoNotRec::Type\fP type)" .br .ti -1c .RI "int \fBoperator==\fP (const \fBSoField\fP &f) const " .br .ti -1c .RI "int \fBoperator!=\fP (const \fBSoField\fP &f) const " .br .ti -1c .RI "virtual void \fBconnectionStatusChanged\fP (int numconnections)" .br .ti -1c .RI "SbBool \fBisReadOnly\fP (void) const " .br .ti -1c .RI "virtual SbBool \fBisSame\fP (const \fBSoField\fP &f) const =0" .br .ti -1c .RI "virtual void \fBcopyFrom\fP (const \fBSoField\fP &f)=0" .br .ti -1c .RI "virtual void \fBfixCopy\fP (SbBool copyconnections)" .br .ti -1c .RI "virtual SbBool \fBreferencesCopy\fP (void) const " .br .ti -1c .RI "void \fBcopyConnection\fP (const \fBSoField\fP *fromfield)" .br .ti -1c .RI "virtual SbBool \fBread\fP (\fBSoInput\fP *input, const \fBSbName\fP &name)" .br .ti -1c .RI "virtual void \fBwrite\fP (\fBSoOutput\fP *out, const \fBSbName\fP &name) const " .br .ti -1c .RI "virtual void \fBcountWriteRefs\fP (\fBSoOutput\fP *out) const " .br .ti -1c .RI "void \fBsetFieldType\fP (int type)" .br .ti -1c .RI "int \fBgetFieldType\fP (void) const " .br .ti -1c .RI "SbBool \fBgetDirty\fP (void) const " .br .ti -1c .RI "void \fBsetDirty\fP (SbBool dirty)" .br .ti -1c .RI "void \fBevaluate\fP (void) const " .br .in -1c .SS "Static Public Member Functions" .in +1c .ti -1c .RI "static void \fBinitClass\fP (void)" .br .ti -1c .RI "static void \fBinitClasses\fP (void)" .br .ti -1c .RI "static void \fBcleanupClass\fP (void)" .br .ti -1c .RI "static \fBSoType\fP \fBgetClassTypeId\fP (void)" .br .in -1c .SS "Protected Member Functions" .in +1c .ti -1c .RI "\fBSoField\fP (void)" .br .ti -1c .RI "void \fBvalueChanged\fP (SbBool resetdefault=TRUE)" .br .ti -1c .RI "virtual void \fBevaluateConnection\fP (void) const " .br .ti -1c .RI "virtual SbBool \fBreadValue\fP (\fBSoInput\fP *in)=0" .br .ti -1c .RI "virtual void \fBwriteValue\fP (\fBSoOutput\fP *out) const =0" .br .ti -1c .RI "virtual SbBool \fBreadConnection\fP (\fBSoInput\fP *in)" .br .ti -1c .RI "virtual void \fBwriteConnection\fP (\fBSoOutput\fP *out) const " .br .ti -1c .RI "SbBool \fBisDestructing\fP (void) const " .br .ti -1c .RI "virtual \fBSoNotRec\fP \fBcreateNotRec\fP (\fBSoBase\fP *cont)" .br .in -1c .SH "Detailed Description" .PP The \fBSoField\fP class is the top-level abstract base class for fields\&. .PP Fields is the mechanism used throughout Coin for encapsulating basic data types to detect changes made to them, and to provide conversion, import and export facilities\&. Almost all public properties in nodes are stored in fields, and so are the inputs and outputs of engines\&. So fields can be viewed as the major mechanism for scenegraph nodes and engines to expose their public API\&. .PP Forcing data modification to go through a public function interface while hiding the data members makes it possible to automatically detect and react upon changes in the data structures set up by the application programmer\&. .PP E\&.g\&. the default behavior when changing the value of a field in a scenegraph node is that there'll automatically be a chain of notifications -- from the field to the owner node, from that node to it's parent node, etc all the way through to the top-most root node, where the need for a rendering update will be signalled to the application\&. .PP (This notification mechanism is the underlying feature that makes the Coin library classify as a so-called \fIdata-driven\fP scenegraph API\&. .PP The practical consequences of this is that rendering and many other processing actions is default scheduled to \fIonly\fP happen when something has changed in the retained data structures, making the Coin library under normal circumstances \fImuch\fP less CPU intensive than so-called 'application-driven' scenegraph API, like for instance SGI IRIS Performer, which are continuously re-rendering even when nothing has changed in the data structures or with the camera viewport\&.) .PP Storing data members as fields also provides other conveniences for the application programmer: .PP .PD 0 .IP "\(bu" 2 Fields can be connected to other fields\&. This makes it for instance possible to have 'self-updating' scenes, ie you can set up scenes where entities \fIautomatically\fP react to changes in other entities\&. This also provides a necessary mechanism for having 'auto-animating' scenes, as it is possible to connect any field to the global field named \fCrealTime\fP, providing a wall-clock timer\&. .PP .PD 0 .IP "\(bu" 2 When connecting fields to each other, Coin has built-in mechanisms for automatically converting between different field types\&. .PP .PD 0 .IP "\(bu" 2 Fields provide persistance for scenegraph import (and export) operations\&. This includes animating entities, so animations can be stored within ordinary Inventor format files\&. .PP .PD 0 .IP "\(bu" 2 Fields provides features for introspection: they have a type-system, just like for nodes and actions, they are named, and it is also possible to find out which node, engine or other entity owns a field\&. .PP .PD 0 .IP "\(bu" 2 Fields can hold multiple values\&. Multi-value fields comes with a much higher level interface abstraction than standard C/C++ arrays\&. .PP Note: there are some field classes which has been obsoleted from the Open Inventor API\&. They are: SoSFLong, SoSFULong, SoMFLong and SoMFULong\&. You should use these classes instead (respectively): \fBSoSFInt32\fP, \fBSoSFUInt32\fP, \fBSoMFInt32\fP and \fBSoMFUInt32\fP\&. .PP For extending the Coin library with your own classes, we strongly recommend that you make yourself acquainted with the excellent «The Inventor Toolmaker» book (ISBN 0-201-62493-1), which describes the tasks involved in detail\&. This book was written by the original SGI Inventor designers and explains many of the underlying design ideas, aswell as having lots of hands-on examples on how to extend the Coin toolkit in ways that are true to the fundamental design ideas\&. («The Inventor Toolmaker» is also available at SGI's online library, at no cost\&. See \fCDownload The Inventor Toolmaker\fP\&.) Reading the sourcecode of the built-in classes in Coin should also provide very helpful\&. .PP \fBSee Also:\fP .RS 4 \fBSoFieldContainer\fP, \fBSoFieldData\fP .RE .PP .SH "Constructor & Destructor Documentation" .PP .SS "SoField::~SoField ()\fC [virtual]\fP" Destructor\&. Disconnects ourself from any connected field or engine before we disconnect all auditors on the field\&. .SS "SoField::SoField (void)\fC [protected]\fP" This is the base constructor for field classes\&. It takes care of doing the common parts of data initialization in fields\&. .SH "Member Function Documentation" .PP .SS "void SoField::initClass (void)\fC [static]\fP" Internal method called upon initialization of the library (from \fBSoDB::init()\fP) to set up the type system\&. .PP Reimplemented in \fBSoMField\fP, \fBSoSFImage\fP, \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMFPath\fP, \fBSoMFColor\fP, \fBSoMFColorRGBA\fP, \fBSoMFVec2d\fP, \fBSoMFVec2f\fP, \fBSoMFVec2i32\fP, \fBSoMFVec4b\fP, \fBSoMFVec4d\fP, \fBSoMFVec4f\fP, \fBSoMFVec4i32\fP, \fBSoMFVec4s\fP, \fBSoMFVec4ub\fP, \fBSoMFVec4ui32\fP, \fBSoMFVec4us\fP, \fBSoSFPath\fP, \fBSoMFVec2b\fP, \fBSoMFVec2s\fP, \fBSoMFVec3b\fP, \fBSoMFVec3d\fP, \fBSoMFVec3f\fP, \fBSoMFVec3i32\fP, \fBSoMFVec3s\fP, \fBSoSFTrigger\fP, \fBSoMFBool\fP, \fBSoMFDouble\fP, \fBSoMFEngine\fP, \fBSoMFFloat\fP, \fBSoMFInt32\fP, \fBSoMFNode\fP, \fBSoMFShort\fP, \fBSoMFUInt32\fP, \fBSoMFUShort\fP, \fBSoSFImage3\fP, \fBSoMFMatrix\fP, \fBSoMFName\fP, \fBSoMFPlane\fP, \fBSoMFRotation\fP, \fBSoMFString\fP, \fBSoMFTime\fP, \fBSoSFBox2d\fP, \fBSoSFBox2f\fP, \fBSoSFBox2i32\fP, \fBSoSFBox2s\fP, \fBSoSFBox3d\fP, \fBSoSFBox3f\fP, \fBSoSFBox3i32\fP, \fBSoSFBox3s\fP, \fBSoSFColor\fP, \fBSoSFColorRGBA\fP, \fBSoSFEnum\fP, \fBSoSFMatrix\fP, \fBSoSFName\fP, \fBSoSFPlane\fP, \fBSoSFRotation\fP, \fBSoSFString\fP, \fBSoSFTime\fP, \fBSoSFVec2b\fP, \fBSoSFVec2d\fP, \fBSoSFVec2f\fP, \fBSoSFVec2i32\fP, \fBSoSFVec2s\fP, \fBSoSFVec3b\fP, \fBSoSFVec3d\fP, \fBSoSFVec3f\fP, \fBSoSFVec3i32\fP, \fBSoSFVec3s\fP, \fBSoSFVec4b\fP, \fBSoSFVec4d\fP, \fBSoSFVec4f\fP, \fBSoSFVec4i32\fP, \fBSoSFVec4s\fP, \fBSoSFVec4ub\fP, \fBSoSFVec4ui32\fP, \fBSoSFVec4us\fP, \fBSoMFEnum\fP, \fBSoSFBool\fP, \fBSoSFDouble\fP, \fBSoSFFloat\fP, \fBSoSFInt32\fP, \fBSoSFShort\fP, \fBSoSFUInt32\fP, \fBSoSFUShort\fP, \fBSoMFBitMask\fP, \fBSoSFBitMask\fP, and \fBSoSField\fP\&. .SS "void SoField::initClasses (void)\fC [static]\fP" Initialize all the field classes\&. .SS "void SoField::setIgnored (SbBoolignore)" Sets the flag which indicates whether or not the field should be ignored during certain operations\&. .PP The effect of this flag depends on what type of field it is used on, and the type of the node which includes the field\&. .PP This flag is represented in Inventor files by a ~ behind the field name\&. The flag is in other words persistent\&. .PP \fBSee Also:\fP .RS 4 \fBisIgnored()\fP .RE .PP .SS "SbBool SoField::isIgnored (void) const" Returns the ignore flag\&. .PP \fBSee Also:\fP .RS 4 \fBsetIgnored()\fP .RE .PP .SS "void SoField::setDefault (SbBooldef)" Set whether or not this field should be marked as containing a default value\&. .PP \fBSee Also:\fP .RS 4 \fBisDefault()\fP .RE .PP .SS "SbBool SoField::isDefault (void) const" Check if the field contains its default value\&. Fields which has their default value intact will normally not be included in the output when writing scene graphs out to a file, for instance\&. .PP \fBSee Also:\fP .RS 4 \fBsetDefault()\fP .RE .PP .SS "\fBSoType\fP SoField::getTypeId (void) const\fC [pure virtual]\fP" Returns the type identification instance which uniquely identifies the Coin field class the object belongs to\&. .PP \fBSee Also:\fP .RS 4 \fBgetClassTypeId()\fP, \fBSoType\fP .RE .PP .PP Implemented in \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMFPath\fP, \fBSoSFImage\fP, \fBSoSFPath\fP, \fBSoSFTrigger\fP, \fBSoMFEngine\fP, \fBSoMFNode\fP, \fBSoSFImage3\fP, \fBSoMFColor\fP, \fBSoMFColorRGBA\fP, \fBSoMFMatrix\fP, \fBSoMFName\fP, \fBSoMFPlane\fP, \fBSoMFRotation\fP, \fBSoMFString\fP, \fBSoMFTime\fP, \fBSoMFVec2b\fP, \fBSoMFVec2d\fP, \fBSoMFVec2f\fP, \fBSoMFVec2i32\fP, \fBSoMFVec2s\fP, \fBSoMFVec3b\fP, \fBSoMFVec3d\fP, \fBSoMFVec3f\fP, \fBSoMFVec3i32\fP, \fBSoMFVec3s\fP, \fBSoMFVec4b\fP, \fBSoMFVec4d\fP, \fBSoMFVec4f\fP, \fBSoMFVec4i32\fP, \fBSoMFVec4s\fP, \fBSoMFVec4ub\fP, \fBSoMFVec4ui32\fP, \fBSoMFVec4us\fP, \fBSoSFBox2d\fP, \fBSoSFBox2f\fP, \fBSoSFBox2i32\fP, \fBSoSFBox2s\fP, \fBSoSFBox3d\fP, \fBSoSFBox3f\fP, \fBSoSFBox3i32\fP, \fBSoSFBox3s\fP, \fBSoSFColor\fP, \fBSoSFColorRGBA\fP, \fBSoSFEnum\fP, \fBSoSFMatrix\fP, \fBSoSFName\fP, \fBSoSFPlane\fP, \fBSoSFRotation\fP, \fBSoSFString\fP, \fBSoSFTime\fP, \fBSoSFVec2b\fP, \fBSoSFVec2d\fP, \fBSoSFVec2f\fP, \fBSoSFVec2i32\fP, \fBSoSFVec2s\fP, \fBSoSFVec3b\fP, \fBSoSFVec3d\fP, \fBSoSFVec3f\fP, \fBSoSFVec3i32\fP, \fBSoSFVec3s\fP, \fBSoSFVec4b\fP, \fBSoSFVec4d\fP, \fBSoSFVec4f\fP, \fBSoSFVec4i32\fP, \fBSoSFVec4s\fP, \fBSoSFVec4ub\fP, \fBSoSFVec4ui32\fP, \fBSoSFVec4us\fP, \fBSoMFBool\fP, \fBSoMFDouble\fP, \fBSoMFEnum\fP, \fBSoMFFloat\fP, \fBSoMFInt32\fP, \fBSoMFShort\fP, \fBSoMFUInt32\fP, \fBSoMFUShort\fP, \fBSoSFBool\fP, \fBSoSFDouble\fP, \fBSoSFFloat\fP, \fBSoSFInt32\fP, \fBSoSFShort\fP, \fBSoSFUInt32\fP, \fBSoSFUShort\fP, \fBSoMFBitMask\fP, and \fBSoSFBitMask\fP\&. .SS "\fBSoType\fP SoField::getClassTypeId (void)\fC [static]\fP" Returns a unique type identifier for this field class\&. .PP \fBSee Also:\fP .RS 4 \fBgetTypeId()\fP, \fBSoType\fP .RE .PP .PP Reimplemented in \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMField\fP, \fBSoMFPath\fP, \fBSoSFImage\fP, \fBSoSFPath\fP, \fBSoSField\fP, \fBSoSFTrigger\fP, \fBSoMFEngine\fP, \fBSoMFNode\fP, \fBSoSFImage3\fP, \fBSoMFColor\fP, \fBSoMFColorRGBA\fP, \fBSoMFMatrix\fP, \fBSoMFName\fP, \fBSoMFPlane\fP, \fBSoMFRotation\fP, \fBSoMFString\fP, \fBSoMFTime\fP, \fBSoMFVec2b\fP, \fBSoMFVec2d\fP, \fBSoMFVec2f\fP, \fBSoMFVec2i32\fP, \fBSoMFVec2s\fP, \fBSoMFVec3b\fP, \fBSoMFVec3d\fP, \fBSoMFVec3f\fP, \fBSoMFVec3i32\fP, \fBSoMFVec3s\fP, \fBSoMFVec4b\fP, \fBSoMFVec4d\fP, \fBSoMFVec4f\fP, \fBSoMFVec4i32\fP, \fBSoMFVec4s\fP, \fBSoMFVec4ub\fP, \fBSoMFVec4ui32\fP, \fBSoMFVec4us\fP, \fBSoSFBox2d\fP, \fBSoSFBox2f\fP, \fBSoSFBox2i32\fP, \fBSoSFBox2s\fP, \fBSoSFBox3d\fP, \fBSoSFBox3f\fP, \fBSoSFBox3i32\fP, \fBSoSFBox3s\fP, \fBSoSFColor\fP, \fBSoSFColorRGBA\fP, \fBSoSFEnum\fP, \fBSoSFMatrix\fP, \fBSoSFName\fP, \fBSoSFPlane\fP, \fBSoSFRotation\fP, \fBSoSFString\fP, \fBSoSFTime\fP, \fBSoSFVec2b\fP, \fBSoSFVec2d\fP, \fBSoSFVec2f\fP, \fBSoSFVec2i32\fP, \fBSoSFVec2s\fP, \fBSoSFVec3b\fP, \fBSoSFVec3d\fP, \fBSoSFVec3f\fP, \fBSoSFVec3i32\fP, \fBSoSFVec3s\fP, \fBSoSFVec4b\fP, \fBSoSFVec4d\fP, \fBSoSFVec4f\fP, \fBSoSFVec4i32\fP, \fBSoSFVec4s\fP, \fBSoSFVec4ub\fP, \fBSoSFVec4ui32\fP, \fBSoSFVec4us\fP, \fBSoMFBool\fP, \fBSoMFDouble\fP, \fBSoMFEnum\fP, \fBSoMFFloat\fP, \fBSoMFInt32\fP, \fBSoMFShort\fP, \fBSoMFUInt32\fP, \fBSoMFUShort\fP, \fBSoSFBool\fP, \fBSoSFDouble\fP, \fBSoSFFloat\fP, \fBSoSFInt32\fP, \fBSoSFShort\fP, \fBSoSFUInt32\fP, \fBSoSFUShort\fP, \fBSoMFBitMask\fP, and \fBSoSFBitMask\fP\&. .SS "SbBool SoField::isOfType (const \fBSoType\fPtype) const" Check if this instance is of a derived type or is the same type as the one given with the \fItype\fP parameter\&. .SS "void SoField::enableConnection (SbBoolflag)" This sets a \fIflag\fP value which indicates whether or not the set up connection should be considered active\&. For as long as the 'enable connection' flag is \fCFALSE\fP, no value propagation will be done from any connected source field, engine or interpolator into this field\&. .PP If the connection is first disabled and then enabled again, the field will automatically be synchronized with any master field, engine or interpolator\&. .PP \fBSee Also:\fP .RS 4 \fBisConnectionEnabled()\fP .RE .PP .SS "SbBool SoField::isConnectionEnabled (void) const" Return the current status of the connection enabled flag\&. .PP \fBSee Also:\fP .RS 4 \fBenableConnection()\fP .RE .PP .SS "SbBool SoField::connectFrom (\fBSoEngineOutput\fP *master, SbBoolnotnotify = \fCFALSE\fP, SbBoolappend = \fCFALSE\fP)" Connects this field as a slave to \fImaster\fP\&. This means that the value of this field will be automatically updated when \fImaster\fP is changed (as long as the connection also is enabled)\&. .PP If this field had any master-relationships beforehand, these are all broken up if \fIappend\fP is \fCFALSE\fP\&. .PP Call with \fInotnotify\fP if you want to avoid the initial notification of connected auditors (a\&.k\&.a\&. \fIslaves\fP)\&. .PP Function will return \fCTRUE\fP unless: .PP .PD 0 .IP "\(bu" 2 If the field output connected \fIfrom\fP is of a different type from the engine output field-type connected \fIto\fP, a field converter is inserted\&. For some combinations of fields no such conversion is possible, and we'll return \fCFALSE\fP\&. .PP .PD 0 .IP "\(bu" 2 If this field is already connected to the \fImaster\fP, we will return \fCFALSE\fP\&. .PP \fBSee Also:\fP .RS 4 \fBenableConnection()\fP, \fBisConnectionEnabled()\fP, \fBisConnectedFromField()\fP .PP \fBgetConnectedField()\fP, appendConnection(SoEngineOutput *) .RE .PP .SS "SbBool SoField::appendConnection (\fBSoEngineOutput\fP *master, SbBoolnotnotify = \fCFALSE\fP)" Connect ourself as slave to another object, while still keeping the other connections currently in place\&. .PP \fBSee Also:\fP .RS 4 \fBconnectFrom()\fP .RE .PP .SS "void SoField::disconnect (\fBSoEngineOutput\fP *master)" Disconnect this field as a slave from \fImaster\fP\&. .SS "SbBool SoField::isConnectedFromEngine (void) const" Returns \fCTRUE\fP if we're connected from an engine\&. .PP \fBSee Also:\fP .RS 4 \fBisConnected()\fP, \fBisConnectedFromField()\fP .PP connectFrom(SoEngineOutput *) .RE .PP .SS "SbBool SoField::getConnectedEngine (\fBSoEngineOutput\fP *&master) const" Returns \fCTRUE\fP if we are connected as a slave to at least one engine\&. \fImaster\fP will be set to the source of the last engine connection made\&. .PP \fBSee Also:\fP .RS 4 \fBisConnectedFromEngine()\fP, connectFrom(SoEngineOutput *) .PP appendConnection(SoEngineOutput *) .RE .PP .SS "SbBool SoField::connectFrom (\fBSoField\fP *master, SbBoolnotnotify = \fCFALSE\fP, SbBoolappend = \fCFALSE\fP)" Connects this field as a slave to \fImaster\fP\&. This means that the value of this field will be automatically updated when \fImaster\fP is changed (as long as the connection also is enabled)\&. .PP If this field had any connections to master fields beforehand, these are all broken up if \fIappend\fP is \fCFALSE\fP\&. .PP Call with \fInotnotify\fP if you want to avoid the initial notification of connected auditors (a\&.k\&.a\&. \fIslaves\fP)\&. .PP Function will return \fCTRUE\fP unless: .PP .PD 0 .IP "\(bu" 2 If the field connected \fIfrom\fP has a different type from the field connected \fIto\fP, a field converter is inserted\&. For some combinations of fields no such conversion is possible, and we'll return \fCFALSE\fP\&. .PP .PD 0 .IP "\(bu" 2 If this field is already connected to the \fImaster\fP, we will return \fCFALSE\fP\&. .PP \fBSee Also:\fP .RS 4 \fBenableConnection()\fP, \fBisConnectionEnabled()\fP, \fBisConnectedFromField()\fP .PP \fBgetConnectedField()\fP, appendConnection(SoField *) .RE .PP .SS "SbBool SoField::appendConnection (\fBSoField\fP *master, SbBoolnotnotify = \fCFALSE\fP)" Connect ourself as slave to another object, while still keeping the other connections currently in place\&. .PP \fBSee Also:\fP .RS 4 \fBconnectFrom()\fP .RE .PP .SS "void SoField::disconnect (\fBSoField\fP *master)" Disconnect this field as a slave from \fImaster\fP\&. .SS "SbBool SoField::isConnectedFromField (void) const" Returns \fCTRUE\fP if we're a slave of at least one field\&. .PP \fBSee Also:\fP .RS 4 \fBisConnected()\fP, \fBisConnectedFromEngine()\fP .PP connectFrom(SoField *) .RE .PP .SS "SbBool SoField::getConnectedField (\fBSoField\fP *&master) const" Returns \fCTRUE\fP if we are connected as a slave to at least one other field\&. \fImaster\fP will be set to the source field in the last field connection made\&. .PP \fBSee Also:\fP .RS 4 \fBisConnectedFromField()\fP, connectFrom(SoField *), .PP appendConnection(SoField *) .RE .PP .SS "int SoField::getNumConnections (void) const" Returns number of fields this field is a slave of\&. .PP \fBSee Also:\fP .RS 4 \fBgetConnections()\fP .RE .PP .SS "int SoField::getForwardConnections (\fBSoFieldList\fP &slavelist) const" Appends all the fields which are auditing this field in \fIslavelist\fP, and returns the number of fields which are our slaves\&. .SS "int SoField::getConnections (\fBSoFieldList\fP &masterlist) const" Returns number of masters this field is connected to, and places pointers to all of them into \fImasterlist\fP\&. .PP Note that we replace the contents of \fImasterlist\fP, i\&.e\&. we're \fInot\fP appending new data\&. .PP \fBSee Also:\fP .RS 4 \fBgetNumConnections()\fP .RE .PP .SS "void SoField::disconnect (void)" Disconnect all connections from this field as a slave to master fields or engine outputs\&. .SS "SbBool SoField::isConnected (void) const" Returns \fCTRUE\fP if we're connected from another field, engine or interpolator\&. .PP \fBSee Also:\fP .RS 4 \fBisConnectedFromField()\fP, \fBisConnectedFromEngine()\fP .PP \fBconnectFrom()\fP .RE .PP .SS "void SoField::setContainer (\fBSoFieldContainer\fP *cont)" Let the field know to which container it belongs\&. .PP \fBSee Also:\fP .RS 4 \fBgetContainer()\fP, \fBSoFieldContainer\fP .RE .PP .SS "\fBSoFieldContainer\fP * SoField::getContainer (void) const" Returns the \fBSoFieldContainer\fP object 'owning' this field\&. .PP \fBSee Also:\fP .RS 4 \fBSoFieldContainer\fP, \fBsetContainer()\fP .RE .PP .SS "SbBool SoField::set (const char *valuestring)" Set the field's value through the given \fIvaluestring\fP\&. The format of the string must adhere to the ASCII format used in Coin data format files\&. .PP Only the value should be specified - \fInot\fP the name of the field\&. .PP \fCFALSE\fP is returned if the field value is invalid for the field type and can't be parsed in any sensible way\&. .PP \fBSee Also:\fP .RS 4 \fBget()\fP .RE .PP .SS "void SoField::get (\fBSbString\fP &valuestring)" Returns the field's value as an ASCII string in the export data format for Inventor files\&. .PP \fBSee Also:\fP .RS 4 \fBset()\fP .RE .PP .SS "SbBool SoField::shouldWrite (void) const" Returns \fCTRUE\fP if it is necessary to write the field when dumping a scene graph\&. This needs to be done if the field is not default (it has been changed from its default value), if it's ignored, or if it's connected from another field or engine\&. .SS "void SoField::touch (void)\fC [virtual]\fP" Notify the field as well as the field's owner / container that it has been changed\&. .PP Touching a field which is part of any component (engine or node) in a scene graph will lead to a forced redraw\&. This is useful if you have been doing several updates to the field wrapped in a pair of \fBenableNotify()\fP calls to notify the field's auditors that its value has changed\&. .PP \fBSee Also:\fP .RS 4 setValue(), \fBenableNotify()\fP .RE .PP .PP Reimplemented in \fBSoSFTrigger\fP\&. .SS "void SoField::startNotify (void)\fC [virtual]\fP" Trigger a notification sequence\&. .PP At the end of a notification sequence, all 'immediate' sensors (i\&.e\&. sensors set up with a zero priority) are triggered\&. .PP Reimplemented in \fBSoSFTrigger\fP\&. .SS "void SoField::notify (\fBSoNotList\fP *nlist)\fC [virtual]\fP" Notify auditors that this field has changed\&. .PP Reimplemented in \fBSoSFTrigger\fP, \fBSoMFPath\fP, and \fBSoSFPath\fP\&. .SS "SbBool SoField::enableNotify (SbBoolon)" This method sets whether notification will be propagated on changing the value of the field\&. The old value of the setting is returned\&. .PP \fBSee Also:\fP .RS 4 \fBisNotifyEnabled()\fP .RE .PP .SS "SbBool SoField::isNotifyEnabled (void) const" This method returns whether notification of changes to the field value are propagated to the auditors\&. .PP \fBSee Also:\fP .RS 4 \fBenableNotify()\fP .RE .PP .SS "void SoField::addAuditor (void *f, \fBSoNotRec::Type\fPtype)" Add an auditor to the list\&. All auditors will be notified whenever this field changes its value(s)\&. .SS "void SoField::removeAuditor (void *f, \fBSoNotRec::Type\fPtype)" Remove an auditor from the list\&. .SS "int SoField::operator== (const \fBSoField\fP &f) const" Checks for equality\&. Returns \fC0\fP if the fields are of different type or the field's value(s) are not equal\&. .SS "int SoField::operator!= (const \fBSoField\fP &f) const" Returns \fCTRUE\fP if the fields are of different type or has different value\&. .SS "void SoField::connectionStatusChanged (intnumconnections)\fC [virtual]\fP" Called whenever another slave attaches or detaches itself to us\&. \fInumconnections\fP is the difference in number of connections made (i\&.e\&. if stuff is \fIdisconnected\fP, \fInumconnections\fP will be a negative number)\&. .PP The default method is empty\&. Override in subclasses if you want do something special on connections/deconnections\&. .SS "SbBool SoField::isReadOnly (void) const" Returns \fCTRUE\fP if this field should not be written into at the moment the method is called\&. .PP This method is used internally in Coin during notification and evaluation processes, and should normally not be of interest to the application programmer\&. .SS "SbBool SoField::isSame (const \fBSoField\fP &f) const\fC [pure virtual]\fP" Check for equal type and value(s)\&. .PP Implemented in \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMFPath\fP, \fBSoSFImage\fP, \fBSoSFPath\fP, \fBSoSFTrigger\fP, \fBSoMFEngine\fP, \fBSoMFNode\fP, \fBSoSFImage3\fP, \fBSoMFColor\fP, \fBSoMFColorRGBA\fP, \fBSoMFMatrix\fP, \fBSoMFName\fP, \fBSoMFPlane\fP, \fBSoMFRotation\fP, \fBSoMFString\fP, \fBSoMFTime\fP, \fBSoMFVec2b\fP, \fBSoMFVec2d\fP, \fBSoMFVec2f\fP, \fBSoMFVec2i32\fP, \fBSoMFVec2s\fP, \fBSoMFVec3b\fP, \fBSoMFVec3d\fP, \fBSoMFVec3f\fP, \fBSoMFVec3i32\fP, \fBSoMFVec3s\fP, \fBSoMFVec4b\fP, \fBSoMFVec4d\fP, \fBSoMFVec4f\fP, \fBSoMFVec4i32\fP, \fBSoMFVec4s\fP, \fBSoMFVec4ub\fP, \fBSoMFVec4ui32\fP, \fBSoMFVec4us\fP, \fBSoSFBox2d\fP, \fBSoSFBox2f\fP, \fBSoSFBox2i32\fP, \fBSoSFBox2s\fP, \fBSoSFBox3d\fP, \fBSoSFBox3f\fP, \fBSoSFBox3i32\fP, \fBSoSFBox3s\fP, \fBSoSFColor\fP, \fBSoSFColorRGBA\fP, \fBSoSFEnum\fP, \fBSoSFMatrix\fP, \fBSoSFName\fP, \fBSoSFPlane\fP, \fBSoSFRotation\fP, \fBSoSFString\fP, \fBSoSFTime\fP, \fBSoSFVec2b\fP, \fBSoSFVec2d\fP, \fBSoSFVec2f\fP, \fBSoSFVec2i32\fP, \fBSoSFVec2s\fP, \fBSoSFVec3b\fP, \fBSoSFVec3d\fP, \fBSoSFVec3f\fP, \fBSoSFVec3i32\fP, \fBSoSFVec3s\fP, \fBSoSFVec4b\fP, \fBSoSFVec4d\fP, \fBSoSFVec4f\fP, \fBSoSFVec4i32\fP, \fBSoSFVec4s\fP, \fBSoSFVec4ub\fP, \fBSoSFVec4ui32\fP, \fBSoSFVec4us\fP, \fBSoMFBool\fP, \fBSoMFDouble\fP, \fBSoMFEnum\fP, \fBSoMFFloat\fP, \fBSoMFInt32\fP, \fBSoMFShort\fP, \fBSoMFUInt32\fP, \fBSoMFUShort\fP, \fBSoSFBool\fP, \fBSoSFDouble\fP, \fBSoSFFloat\fP, \fBSoSFInt32\fP, \fBSoSFShort\fP, \fBSoSFUInt32\fP, \fBSoSFUShort\fP, \fBSoMFBitMask\fP, and \fBSoSFBitMask\fP\&. .SS "void SoField::copyFrom (const \fBSoField\fP &f)\fC [pure virtual]\fP" Copy value(s) from \fIf\fP into this field\&. \fIf\fP must be of the same type as this field\&. .PP Implemented in \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMFPath\fP, \fBSoSFImage\fP, \fBSoSFPath\fP, \fBSoSFTrigger\fP, \fBSoMFEngine\fP, \fBSoMFNode\fP, \fBSoSFImage3\fP, \fBSoMFColor\fP, \fBSoMFColorRGBA\fP, \fBSoMFMatrix\fP, \fBSoMFName\fP, \fBSoMFPlane\fP, \fBSoMFRotation\fP, \fBSoMFString\fP, \fBSoMFTime\fP, \fBSoMFVec2b\fP, \fBSoMFVec2d\fP, \fBSoMFVec2f\fP, \fBSoMFVec2i32\fP, \fBSoMFVec2s\fP, \fBSoMFVec3b\fP, \fBSoMFVec3d\fP, \fBSoMFVec3f\fP, \fBSoMFVec3i32\fP, \fBSoMFVec3s\fP, \fBSoMFVec4b\fP, \fBSoMFVec4d\fP, \fBSoMFVec4f\fP, \fBSoMFVec4i32\fP, \fBSoMFVec4s\fP, \fBSoMFVec4ub\fP, \fBSoMFVec4ui32\fP, \fBSoMFVec4us\fP, \fBSoSFBox2d\fP, \fBSoSFBox2f\fP, \fBSoSFBox2i32\fP, \fBSoSFBox2s\fP, \fBSoSFBox3d\fP, \fBSoSFBox3f\fP, \fBSoSFBox3i32\fP, \fBSoSFBox3s\fP, \fBSoSFColor\fP, \fBSoSFColorRGBA\fP, \fBSoSFEnum\fP, \fBSoSFMatrix\fP, \fBSoSFName\fP, \fBSoSFPlane\fP, \fBSoSFRotation\fP, \fBSoSFString\fP, \fBSoSFTime\fP, \fBSoSFVec2b\fP, \fBSoSFVec2d\fP, \fBSoSFVec2f\fP, \fBSoSFVec2i32\fP, \fBSoSFVec2s\fP, \fBSoSFVec3b\fP, \fBSoSFVec3d\fP, \fBSoSFVec3f\fP, \fBSoSFVec3i32\fP, \fBSoSFVec3s\fP, \fBSoSFVec4b\fP, \fBSoSFVec4d\fP, \fBSoSFVec4f\fP, \fBSoSFVec4i32\fP, \fBSoSFVec4s\fP, \fBSoSFVec4ub\fP, \fBSoSFVec4ui32\fP, \fBSoSFVec4us\fP, \fBSoMFBool\fP, \fBSoMFDouble\fP, \fBSoMFEnum\fP, \fBSoMFFloat\fP, \fBSoMFInt32\fP, \fBSoMFShort\fP, \fBSoMFUInt32\fP, \fBSoMFUShort\fP, \fBSoSFBool\fP, \fBSoSFDouble\fP, \fBSoSFFloat\fP, \fBSoSFInt32\fP, \fBSoSFShort\fP, \fBSoSFUInt32\fP, \fBSoSFUShort\fP, \fBSoMFBitMask\fP, and \fBSoSFBitMask\fP\&. .SS "void SoField::fixCopy (SbBoolcopyconnections)\fC [virtual]\fP" This method is internally called after \fBSoField::copyFrom()\fP during scene graph copies, and should do the operations necessary for fixing up the field instance after it has gotten a new value\&. .PP The default method in the \fBSoField\fP superclass does nothing\&. .PP The application programmer should normally not need to consider this method, unless he constructs a complex field type which contains new references to container instances (i\&.e\&. nodes or engines)\&. Overriding this method is then necessary to update the reference pointers, as they could have been duplicated during the copy operation\&. .PP Reimplemented in \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMFPath\fP, \fBSoSFPath\fP, \fBSoMFEngine\fP, and \fBSoMFNode\fP\&. .SS "SbBool SoField::referencesCopy (void) const\fC [virtual]\fP" Returns \fCTRUE\fP if this field has references to any containers in the scene graph which are also duplicated during the copy operation\&. .PP Note that this method \fIonly\fP is valid to call during copy operations\&. .PP See also the note about the relevance of the \fBfixCopy()\fP method for application programmers, as it is applicable on this method aswell\&. .PP Reimplemented in \fBSoSFEngine\fP, \fBSoSFNode\fP, \fBSoMFPath\fP, \fBSoSFPath\fP, \fBSoMFEngine\fP, and \fBSoMFNode\fP\&. .SS "void SoField::copyConnection (const \fBSoField\fP *fromfield)" If \fIfromfield\fP contains a connection to another field, make this field also use the same connection\&. .SS "SbBool SoField::read (\fBSoInput\fP *in, const \fBSbName\fP &name)\fC [virtual]\fP" Reads and sets the value of this field from the given \fBSoInput\fP instance\&. Returns \fCFALSE\fP if the field value can not be parsed from the input\&. .PP The second argument is the field's context-specific \fIname\fP, which is typically its unique identifier in its field container\&. .PP \fBSee Also:\fP .RS 4 \fBset()\fP, \fBwrite()\fP .RE .PP .SS "void SoField::write (\fBSoOutput\fP *out, const \fBSbName\fP &name) const\fC [virtual]\fP" Write the value of the field to the given \fBSoOutput\fP instance (which can be either a memory buffer or a file, in ASCII or in binary format)\&. .PP \fBSee Also:\fP .RS 4 \fBget()\fP, \fBread()\fP, \fBSoOutput\fP .RE .PP .SS "void SoField::countWriteRefs (\fBSoOutput\fP *out) const\fC [virtual]\fP" This method is called during the first pass of write operations, to count the number of write references to this field and to 'forward' the reference counting operation to the field containers we're connected to\&. .SS "void SoField::setFieldType (inttype)" Set type of this field\&. .PP The possible values for \fItype\fP is: 0 for ordinary fields, 1 for eventIn fields, 2 for eventOut fields, 3 for internal fields, 4 for VRML2 exposedField fields\&. There are also enum values in \fBSoField\&.h\fP\&. .SS "int SoField::getFieldType (void) const" Return the type of this field\&. .PP \fBSee Also:\fP .RS 4 \fBsetFieldType()\fP .RE .PP .SS "SbBool SoField::getDirty (void) const" Do we need re-evaluation? .SS "void SoField::setDirty (SbBooldirty)" Mark field for re-evaluation (upon next read operation), but do not trigger a notification\&. .SS "void SoField::evaluate (void) const\fC [inline]\fP" Re-evaluates the value of this field any time a getValue() call is made and the field is marked dirty\&. This is done in this way to gain the advantages of having lazy evaluation\&. .SS "void SoField::valueChanged (SbBoolresetdefault = \fCTRUE\fP)\fC [protected]\fP" This method is always called whenever the field's value has been changed by direct invocation of setValue() or some such\&. You should \fInever\fP call this method from anywhere in the code where the field value is being set through an evaluation of its connections\&. .PP If \fIresetdefault\fP is \fCTRUE\fP, the flag marking whether or not the field has its default value will be set to \fCFALSE\fP\&. .PP The method will also notify any auditors that the field's value has changed\&. .SS "void SoField::evaluateConnection (void) const\fC [protected]\fP, \fC [virtual]\fP" If we're connected to a field/engine/interpolator, copy the value from the master source\&. .SS "SbBool SoField::readValue (\fBSoInput\fP *in)\fC [protected]\fP, \fC [pure virtual]\fP" Read field value(s)\&. .SS "void SoField::writeValue (\fBSoOutput\fP *out) const\fC [protected]\fP, \fC [pure virtual]\fP" Write field value(s)\&. .SS "SbBool SoField::readConnection (\fBSoInput\fP *in)\fC [protected]\fP, \fC [virtual]\fP" Read the master field of a field-to-field connection (and its field container)\&. .PP If input parsing is successful, this field will be connected as a slave to the master field\&. .PP Note that this slave field will \fInot\fP be marked as 'dirty' upon connection, i\&.e\&. it will retain its value until the first update of the master field is made \fIafter\fP the connection was set up\&. This to be in conformance with how the Inventor Mentor specifies how field connections should be imported (see page 270)\&. .SS "void SoField::writeConnection (\fBSoOutput\fP *out) const\fC [protected]\fP, \fC [virtual]\fP" Write out information about this field's connection\&. .SS "SbBool SoField::isDestructing (void) const\fC [protected]\fP" Can be used to check if a field is being destructed\&. .SS "\fBSoNotRec\fP SoField::createNotRec (\fBSoBase\fP *cont)\fC [protected]\fP, \fC [virtual]\fP" .PP Reimplemented in \fBSoMField\fP\&. .SH "Author" .PP Generated automatically by Doxygen for Coin from the source code\&.