Skip to main content

Max Vertex Count

Check if the mesh exceeds a specified maximum vertex count and correct it if necessary.

Parameter table

paramunitrequireddescription
meshNamenoThe name of the mesh to be checked.
meshKeyNamenoThe key of the name of the mesh to be checked. This will be used if mesName is undefined.
maxVertexCountyesThe maximum allowed number of vertices for the mesh.

Detailed description

This rule checks if a mesh's vertex count exceeds the specified maximum vertex count (maxVertexCount). If the mesh does exceed this number, the rule applies a correction to reduce the vertex count.

It can be used to ensure that meshes are optimized for performance by keeping vertex counts within acceptable limits.

This rule is particularly useful in scenarios where performance optimization is crucial, such as in game development and real-time rendering applications, where excessive vertex counts can adversely affect performance and load times.

Correction

The correction process aims to decrease the number of vertices without significantly compromising the mesh's visual and structural integrity.

The correction process uses decimation techniques to reduce vertex counts efficiently while maintaining the mesh's overall shape and features.

How to setup

The 'Max Vertex Count' rule is designed to help maintain mesh complexity within optimal performance boundaries by enforcing a maximum vertex count.

** Key parameters include: **

  • maxVertexCount: This parameter sets the upper limit for the number of vertices a mesh can have. It is crucial to select a value that balances performance with the necessary level of detail for meshes.
  • meshName: This parameter specifies the name of the mesh to be checked.

Evaluate the performance constraints of your application or project. Lower vertex counts are generally better for performance, but too low can compromise the visual quality.

Creator tips

When preparing your meshes, aim to keep vertex counts as low as possible without sacrificing necessary detail. This practice ensures better performance across various platforms.

Consider using mesh decimation tools and techniques during the modeling process to control vertex counts effectively.

After applying corrections, visually inspect the mesh to ensure that the reduction in vertex count has not adversely affected its appearance or function.

Examples

valuevalidmaxVertexCountmeshNamedescription
die1000DiceThis die is composed of approximately 9k vertices.
die-decimated1000DiceAfter appliying decimate modifier, the die is now composed of approximately 700 vertices.