SoNormalGenerator - Online Linux Manual PageSection : 3
Updated : Mon Jan 25 2021
Source : Version 3.1.3
Note : Coin
NAMESoNormalGenerator − The SoNormalGenerator class is used to generate normals.
SYNOPSIS
#include <include/Inventor/misc/SoNormalGenerator.h>
Public Member FunctionsSoNormalGenerator (const SbBool ccw, const int approxVertices=64)
~SoNormalGenerator ()
void reset (const SbBool ccw)
void beginPolygon ()
void polygonVertex (const SbVec3f &v)
void endPolygon ()
void triangle (const SbVec3f &v0, const SbVec3f &v1, const SbVec3f &v2)
void quad (const SbVec3f &v0, const SbVec3f &v1, const SbVec3f &v2, const SbVec3f &v3)
void generate (const float creaseAngle, const int32_t *striplens=NULL, const int numstrips=0)
void generatePerStrip (const int32_t *striplens, const int numstrips)
void generatePerFace (void)
void generateOverall (void)
int getNumNormals () const
void setNumNormals (const int num)
const SbVec3f * getNormals () const
const SbVec3f & getNormal (const int32_t i) const
void setNormal (const int32_t index, const SbVec3f &normal)
Detailed DescriptionThe SoNormalGenerator class is used to generate normals. FIXME: document properly
Constructor & Destructor Documentation
SoNormalGenerator::SoNormalGenerator (const SbBool isccw, const int approxVertices = 64)Constructor with isccw indicating if polygons are specified in counter clockwise order. The approxVertices can be used to optimize normal generation.
SoNormalGenerator::~SoNormalGenerator ()Destructor.
Member Function Documentation
void SoNormalGenerator::reset (const SbBool ccwarg)Resets the normal generator, making it possible to reuse it without allocating a new one. This function is an extension for Coin, and it is not available in the original SGI Open Inventor v2.1 API.
Since Coin 2.0
void SoNormalGenerator::beginPolygon (void)Signals the start of a new polygon. See also SoNormalGenerator::polygonVertex() SoNormalGenerator::endPolygon()
void SoNormalGenerator::polygonVertex (const SbVec3f & v)Adds a vertex to the current polygon. See also SoNormalGenerator::beginPolygon() SoNormalGenerator::endPolygon()
void SoNormalGenerator::endPolygon (void)Signals the end of a polygon. See also SoNormalGenerator::beginPolygon() SoNormalGenerator::polygonVertex()
void SoNormalGenerator::triangle (const SbVec3f & v0, const SbVec3f & v1, const SbVec3f & v2)Convenience method for adding a triangle.
void SoNormalGenerator::quad (const SbVec3f & v0, const SbVec3f & v1, const SbVec3f & v2, const SbVec3f & v3)Convenience method for adding a quad
void SoNormalGenerator::generate (const float creaseAngle, const int32_t * striplens = NULL, const int numstrips = 0)Triggers the normal generation. Normals are generated using creaseAngle to find which edges should be flat-shaded and which should be smooth-shaded. If normals are generated for triangle strips, the striplens and numstrips must be supplied. See src/nodes/SoTriangleStripSet.cpp (generateDefaultNormals()) for an example on how you send triangle strip information to this generator. It's not trivial, since you have to know how OpenGL/Coin generate triangles from triangle strips.
void SoNormalGenerator::generatePerStrip (const int32_t * striplens, const int numstrips)Generates one normal per strip by averaging face normals.
void SoNormalGenerator::generatePerFace (void)Generates the normals per face. Use this when PER_FACE normal binding is needed. This method is not part of the OIV API.
void SoNormalGenerator::generateOverall (void)Generates one overall normal by averaging all face normals. Use when normal binding is OVERALL. This method is not part of the OIV API.
int SoNormalGenerator::getNumNormals (void) constReturns the number of normals generated.
void SoNormalGenerator::setNumNormals (const int num)Sets the number of generated normals. This method is not supported in Coin, and is provided for API compatibility only.
const SbVec3f * SoNormalGenerator::getNormals (void) constReturns a pointer to the generated normals.
const SbVec3f & SoNormalGenerator::getNormal (const int32_t i) constReturns the normal at index i. See also SoNormalGenerator::getNumNormals()
void SoNormalGenerator::setNormal (const int32_t index, const SbVec3f & normal)Sets the normal at index index to normal. This method is not supported in Coin, and is provided for API compatibility only.
AuthorGenerated automatically by Doxygen for Coin from the source code. 0
Johanes Gumabo
Data Size : 23,764 byte
man-SoNormalGenerator.3coin3Build : 2024-12-05, 20:55 :
Visitor Screen : x
Visitor Counter ( page / site ) : 2 / 190,671
Visitor ID : :
Visitor IP : 18.227.105.110 :
Visitor Provider : AMAZON-02 :
Provider Position ( lat x lon ) : 39.962500 x -83.006100 : x
Provider Accuracy Radius ( km ) : 1000 :
Provider City : Columbus :
Provider Province : Ohio , : ,
Provider Country : United States :
Provider Continent : North America :
Visitor Recorder : Version :
Visitor Recorder : Library :
Online Linux Manual Page : Version : Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.05
Online Linux Manual Page : Library : lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page : Library : lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base : Version : Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base : Library : lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36
Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.