fastest 3D software for linux

Linux 3D
interactive ray-tracing
[1 introduction] [2 overview] [3 reference] [4 GUI]

Index

 E3dVertexNodes_New
 E3dVertexNodeAttribute_Add
 E3dVertexNodeAttribute_Offset
 E3dVertexNodeAttribute_GetIndex

E3dVertexNodes_New

Allocate VertexNodes

Syntax
E3dVertexNode* E3dVertexNodes_New(const int PNumOfVertexNodes, const E3dVertexNodeSize PVertexNodeSize)

Arguments
PNumOfVertexNodes The number of VertexNodes to allocate PVertexNodeSize The size of a VertexNode in bytes
Description
Allocates VertexNodes for the given Polygon. For performance reasons, the VertexNodes will not be initialized. It's up to the caller to do that.

Return value
A pointer to the allocated array of VertexNodes or NULL in case of an error

See also
E3dPolygon_AddVertexNode

E3dVertexNodeAttribute_Add

Add a Vertex attribute to a list

Syntax
int E3dVertexNodeAttribute_Add(EResourceList* PList, const char* PName, const char* PSemantic, const int PIndex, const EResource* PCustomAttr, EResource** PVARet)

Arguments
PList Pointer to the list PName The name of the new attribute PSemantic The semantic string of the new attribute PIndex Index of the new attribute. Only applies to texture coordinates PCustomAttr If not NULL, it specifies a custom vertex attribute PVARet Pointer to return the new attribute
Description
Adds a vertex attribute, such as normals, or texture coordinates. The most common use is adding a vertex attribute to a PolyGroup. For example: E3dVertexNodeAttribute_Add(&LPolyGroup->VertexAttributes, E3dVtxAttribute_Normal, 0, NULL, NULL); By default, PolyGroups don't have vertex normals, to save memory on potentially large Meshes. All renderers will use the Polygon normals, in this case. To add normals, this function should be called like shown above, or you can simply use E3dPolyGroup_VertexAttributeAdd() If PCustomAttr is NULL, a built-in attribute is assumed, such as: - E3dVtxAttribute_Normal - E3dVtxAttribute_Color - E3dVtxAttribute_ST - E3dVtxAttribute_UV - E3dVtxAttribute_Tangent

Return value
E_SUCCESS if successful, E_NOTHING_TO_DO if the VertexAttribute already exists

See also
E3dPolyGroup_VertexAttributeAdd

E3dVertexNodeAttribute_Offset

Compute offset of a VertexNode attribute, specified by semantic and index

Syntax
E3dVertexNodeSize E3dVertexNodeAttribute_Offset(const EResourceList* PList, const char* PSemantic, const int PIndex)

Arguments
PList VertexNodeAttribute list PSemantic Semantic PIndex Attribute index (if there are multiple Attributes with the same Semantic, e.g. multiple ST sets)
Description
Returns the byte offset of the given VertexAttribute.

Return value
None.

E3dVertexNodeAttribute_GetIndex

Compute the index of a VertexNode attribute, specified by semantic and index

Syntax
EIndex E3dVertexNodeAttribute_GetIndex(const EResourceList* PList, const char* PSemantic, const int PIndex)

Arguments
PList VertexNodeAttribute list PSemantic Semantic PIndex Attribute index (if there are multiple Attributes with the same Semantic, e.g. multiple ST sets)
Description
Returns the index of the given VertexAttribute in PList. For example, if there's a position attribute, a normal and 3 texture coordinate sets, this will return an index of 3 (2 + 1): E3dVertexNodeAttribute_GetIndex(List, E3dVtxAttribute_ST, 1);

Return value
None.
© 1996-2024 By Gabor Nagy