VoxelBlockyLibraryBase

Inherits: Resource

Inherited by: VoxelBlockyLibrary, VoxelBlockyTypeLibrary

Contains a list of models that can be used by VoxelMesherBlocky.

Description:

Models used by VoxelMesherBlocky must be baked before they can be used efficiently at runtime. The way this process happens depends on the implementation of this class. It can be a simple list of models, or a list of high-level types generating variant models. Check child classes for more information.

Properties:

Type Name Default
bool bake_tangents true

Methods:

Return Signature
void bake ( )
Material[] get_materials ( ) const

Constants:

  • MAX_MODELS = 65536
  • MAX_MATERIALS = 65536

Property Descriptions

bool bake_tangents = true

Enable this option if you need normal mapping on your voxels. If you don't need it, disabling can reduce memory usage and give a small speed boost.

Method Descriptions

void bake( )

Bakes the library. The data of models is optimized in order to combine them more efficiently when generating voxel meshes.

Material[] get_materials( )

Gets a list of all distinct materials found in all models of the library.

Note, if at least one non-empty model has no material, there will be one null entry in this list to represent "The default material".

Generated on Apr 06, 2024