other versions
- wheezy 3.1.3-2.2
SoSTLFileKit(3) | Coin | SoSTLFileKit(3) |
NAME¶
SoSTLFileKit - SoSTLFileKit is a class for using STL files with Coin.SYNOPSIS¶
#include <ForeignFiles/SoSTLFileKit.h> Inherits SoForeignFileKit.Public Types¶
enum Colorization { GREY, MATERIALISE, TNO_VISICAM }
Public Member Functions¶
virtual SoType getTypeId (void) const
Static Public Member Functions¶
static SoType getClassTypeId (void)
Public Attributes¶
SoSFString info
Protected Member Functions¶
virtual const SoFieldData * getFieldData (void) const
Static Protected Member Functions¶
static const SoFieldData ** getFieldDataPtr (void)
Protected Attributes¶
SoSFNode shapehints
Detailed Description¶
SoSTLFileKit is a class for using STL files with Coin.- •
- STL models should represent complete solids - it is the user's responsibility to give models of solid data to readScene(), and not readScene()'s responsibility to check the incoming data.
- •
- STL models should have all triangles in counterclockwise order. This is not enforced either.
- •
- STL models should reside in the positive octant of the coordinate space. This is also the user's responsibility to ensure, although adding functionality for translating the model should be easy, so it might get implemented.
Coin 3.0
Constructor & Destructor Documentation¶
SoSTLFileKit::SoSTLFileKit (void)¶
Constructor.SoSTLFileKit::~SoSTLFileKit (void) [protected], [virtual]¶
Destructor.Member Function Documentation¶
SoType SoSTLFileKit::getClassTypeId (void) [static]¶
This static method returns the SoType object associated with objects of this class. Reimplemented from SoForeignFileKit.SoType SoSTLFileKit::getTypeId (void) const [virtual]¶
Returns the type identification of an object derived from a class inheriting SoBase. This is used for run-time type checking and 'downward' casting. Usage example:void foo(SoNode * node) { if (node->getTypeId() == SoFile::getClassTypeId()) { SoFile * filenode = (SoFile *)node; // safe downward cast, knows the type } }For application programmers wanting to extend the library with new nodes, engines, nodekits, draggers or others: this method needs to be overridden in all subclasses. This is typically done as part of setting up the full type system for extension classes, which is usually accomplished by using the pre-defined macros available through for instance Inventor/nodes/SoSubNode.h (SO_NODE_INIT_CLASS and SO_NODE_CONSTRUCTOR for node classes), Inventor/engines/SoSubEngine.h (for engine classes) and so on. For more information on writing Coin extensions, see the class documentation of the toplevel superclasses for the various class groups. Reimplemented from SoForeignFileKit.
const SoFieldData ** SoSTLFileKit::getFieldDataPtr (void) [static], [protected]¶
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer. Reimplemented from SoForeignFileKit.const SoFieldData * SoSTLFileKit::getFieldData (void) const [protected], [virtual]¶
Returns a pointer to the class-wide field data storage object for this instance. If no fields are present, returns NULL. Reimplemented from SoForeignFileKit.const SoNodekitCatalog * SoSTLFileKit::getClassNodekitCatalog (void) [static]¶
Returns the nodekit catalog which defines the layout of this class' kit. Reimplemented from SoForeignFileKit.const SoNodekitCatalog * SoSTLFileKit::getNodekitCatalog (void) const [virtual]¶
Returns the nodekit catalog which defines the layout of this class' kit. Reimplemented from SoForeignFileKit.const SoNodekitCatalog ** SoSTLFileKit::getClassNodekitCatalogPtr (void) [static], [protected]¶
Returns the pointer to the pointer of the nodekit catalog for this class. Reimplemented from SoForeignFileKit.void SoSTLFileKit::initClass (void) [static]¶
Initializes class and registers file identification functions. Reimplemented from SoForeignFileKit.SbBool SoSTLFileKit::identify (const char *filename) [static]¶
Returns wether or not filename is identified as an STL file.SbBool SoSTLFileKit::readFile (const char *filename) [virtual]¶
Reads in an STL file. Both ascii and binary files are supported. For binary files, the color extensions are not implemented yet. Returns FALSE if filename could not be opened or parsed correctly. See also:canReadFile, canWriteScene,
writeScene
SbBool SoSTLFileKit::readScene (SoNode *scene) [virtual]¶
Converts a scene graph into an SoSTLFileKit. Useful for creating STL files. See also:canReadScene, canWriteFile,
writeFile
SbBool SoSTLFileKit::writeFile (const char *filename) [virtual]¶
Writes the STL model to an STL file. See also:binary, info, canWriteFile, canReadScene
SbBool SoSTLFileKit::writeScene (SoNode *&root, const char *format = NULL) [virtual]¶
Converts the STL model into a native scene graph. See also:canWriteScene
void SoSTLFileKit::reset (void) [protected]¶
Resets the STL model so it contains nothing.SbBool SoSTLFileKit::addFacet (const SbVec3f &v1, const SbVec3f &v2, const SbVec3f &v3, const SbVec3f &n) [protected]¶
Adds one triangle to the STL model. See also:reset, organizeModel
void SoSTLFileKit::organizeModel (void) [protected]¶
Should be called after the STL model is completely set up in the SoSTLFileKit through import from a file or from a scene graph. The model will then be optimized for fast rendering. See also:addFacet, reset
Author¶
Generated automatically by Doxygen for Coin from the source code.Wed May 23 2012 | Version 3.1.3 |