lv_gltf_data_internal.hpp API reference for lv_gltf_data_internal.hpp
Setters (2) Functions that modify object properties
Getters (18) Functions that read object properties
Other (18) Constructors, destructors, and utilities
std::vector < uint32_t > * lv_gltf_data_animation_get_channel_set (std:: size_t anim_num , lv_gltf_model_t * data , fastgltf::Node * node ) Parameters Retrieve a specific texture from the GLTF model data.
GLuint lv_gltf_data_get_texture ( lv_gltf_model_t * data , size_t index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. indexsize_tThe index of the texture to retrieve.
Returns: GLuint — Pointer to the texture object.
Retrieve the minimum bounds (X/Y/Z) of the model from the GLTF data.
fastgltf::math::fvec3 lv_gltf_data_get_bounds_min ( const lv_gltf_model_t * data ) Parameters Returns: fastgltf::math::fvec3 — Pointer to a 3-element float array representing the minimum bounds.
Retrieve the maximum bounds (X/Y/Z) of the model from the GLTF data.
fastgltf::math::fvec3 lv_gltf_data_get_bounds_max ( const lv_gltf_model_t * data ) Parameters Returns: fastgltf::math::fvec3 — Pointer to a 3-element float array representing the maximum bounds.
Retrieve the center coordinates of the GLTF data object.
fastgltf::math::fvec3 lv_gltf_data_get_center ( const lv_gltf_model_t * data ) Parameters Returns: fastgltf::math::fvec3 — Pointer to an array containing the center coordinates (x, y, z).
Retrieve the filename of the GLTF model.
const char * lv_gltf_get_filename ( const lv_gltf_model_t * data ) Parameters Returns: const char * — Pointer to a constant character string representing the filename.
Retrieve a specific primitive from a mesh.
lv_gltf_primitive_t * lv_gltf_data_get_primitive_from_mesh ( lv_gltf_mesh_data_t * mesh , size_t index ) Parameters Name Type Description meshlv_gltf_mesh_data_t *Pointer to the MeshData structure containing the mesh data. indexsize_tThe index of the primitive to retrieve.
Returns: lv_gltf_primitive_t * — Pointer to the primitive data.
Retrieve the asset associated with the GLTF model data.
fastgltf::Asset * lv_gltf_data_get_asset ( lv_gltf_model_t * data ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data.
Returns: fastgltf::Asset * — Pointer to the asset data.
Retrieve mesh data for a specific index from the GLTF model data.
lv_gltf_mesh_data_t * lv_gltf_data_get_mesh ( lv_gltf_model_t * data , size_t index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. indexsize_tThe index of the mesh data to retrieve.
Returns: lv_gltf_mesh_data_t * — Pointer to the MeshData structure containing the mesh data.
Retrieve the skin texture index for a specific entry in the GLTF model data.
GLuint lv_gltf_data_get_skin_texture_at ( lv_gltf_model_t * data , size_t index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. indexsize_tThe index of the entry for which to retrieve the skin texture index.
Returns: GLuint — The skin texture index.
Retrieve the size of the skins in the GLTF model data.
size_t lv_gltf_data_get_skins_size ( lv_gltf_model_t * data ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data.
Returns: size_t — The size of the skins.
Retrieve a specific skin from the GLTF model data.
size_t lv_gltf_data_get_skin ( lv_gltf_model_t * data , size_t index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. indexsize_tThe index of the skin to retrieve.
Returns: size_t — The skin index.
Retrieve the center point of a specific mesh element from the GLTF model data.
fastgltf::math::fvec3 lv_gltf_data_get_centerpoint ( lv_gltf_model_t * gltf_data , fastgltf::math::fmat4x4 matrix , size_t mesh_index , size_t elem ) Parameters Name Type Description gltf_datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. matrixfastgltf::math::fmat4x4The transformation matrix to apply when calculating the center point. mesh_indexsize_tThe index of the mesh from which to retrieve the center point. elemsize_tThe specific element index within the mesh.
Returns: fastgltf::math::fvec3 — The center point as a fastgltf::math::fvec3 structure.
lv_gltf_mesh_data_t * lv_gltf_get_new_meshdata ( lv_gltf_model_t * _data ) Parameters fastgltf::math::fvec4 lv_gltf_get_primitive_centerpoint ( lv_gltf_model_t * data , fastgltf::Mesh & mesh , uint32_t prim_num ) Parameters Retrieve the pixel data for a specific texture in a GLTF model.
bool lv_gltf_data_get_texture_pixels ( void * pixels , lv_gltf_model_t * data_obj , uint32_t model_texture_index , uint32_t mipmapnum , uint32_t width , uint32_t height , bool has_alpha ) Parameters Name Type Description pixelsvoid *Pointer to the memory where the pixel data will be stored. data_objlv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. model_texture_indexuint32_tThe index of the texture in the model. mipmapnumuint32_tThe mipmap level to retrieve pixel data for. widthuint32_tThe width of the texture. heightuint32_tThe height of the texture. has_alphaboolFlag indicating whether the texture includes an alpha channel.
Returns: bool — True if the pixel data was successfully retrieved, false otherwise.
uint32_t lv_gltf_data_get_animation_total_time ( lv_gltf_model_t * data , uint32_t index ) Parameters lv_gltf_model_node_t * lv_gltf_model_node_get_by_internal_node ( lv_gltf_model_t * model , const fastgltf::Node * fastgltf_node ) Parameters Check if the validated skins contain a specific entry.
bool lv_gltf_data_validated_skins_contains ( lv_gltf_model_t * data , size_t index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. indexsize_tThe index of the skin to check.
Returns: bool — True if the validated skins contain the entry, false otherwise.
Validate a specific skin in the GLTF model data.
void lv_gltf_data_validate_skin ( lv_gltf_model_t * data , size_t index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. indexsize_tThe index of the skin to validate.
Drop the draw lists built by a previous parse of this model.
The lists are rebuilt from the model every time it is parsed for a viewer, so they have to be emptied first or a model parsed twice would draw every primitive twice.
void lv_gltf_data_clear_node_primitives ( lv_gltf_model_t * data ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data.
Add an opaque node primitive to the GLTF model data.
void lv_gltf_data_add_opaque_node_primitive ( lv_gltf_model_t * data , uint32_t material_index , fastgltf::Node * node , size_t primitive_index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. material_indexuint32_tThe index of the primitive to add. nodefastgltf::Node *Pointer to the NodePtr representing the node to add. primitive_indexsize_tThe specific parameter associated with the primitive.
Add a blended node primitive to the GLTF model data.
void lv_gltf_data_add_blended_node_primitive ( lv_gltf_model_t * data , uint32_t material_index , fastgltf::Node * node , size_t primitive_index ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. material_indexuint32_tThe index of the material to add. nodefastgltf::Node *Pointer to the NodePtr representing the node to add. primitive_indexsize_tThe specific parameter associated with the primitive.
Ingest and discover defines for a specific node and primitive in the GLTF model data.
void lv_gltf_data_injest_discover_defines ( lv_gltf_model_t * data , fastgltf::Node * node , fastgltf::Primitive * prim ) Parameters Name Type Description datalv_gltf_model_t *Pointer to the lv_gltf_data_t object containing the model data. nodefastgltf::Node *Pointer to the node for which to ingest defines. primfastgltf::Primitive *Pointer to the primitive for which to ingest defines.
lv_gltf_model_t * lv_gltf_data_create_internal ( const char * gltf_path , fastgltf::Asset && asset ) Parameters Name Type gltf_pathconst char *assetfastgltf::Asset &&
lv_gltf_model_t * lv_gltf_data_load_internal ( const void * data_source , size_t data_size , lv_gltf_model_loader_t * loader ) Parameters fastgltf::math::fvec3 get_cached_centerpoint ( lv_gltf_model_t * data , size_t index , int32_t element , fastgltf::math::fmat4x4 matrix ) Parameters void lv_gltf_data_delete_textures ( lv_gltf_model_t * data ) Parameters GLuint lv_gltf_data_create_texture ( lv_gltf_model_t * data ) Parameters void lv_gltf_model_node_init ( lv_gltf_model_t * model , lv_gltf_model_node_t * node , fastgltf::Node * fastgltf_node , const char * path , const char * num_path ) Parameters void lv_gltf_model_node_deinit ( lv_gltf_model_node_t * node ) Parameters void lv_gltf_data_animation_matrix_apply ( float timestamp , std:: size_t anim_num , lv_gltf_model_t * gltf_data , fastgltf::Node * node , fastgltf::math::fmat4x4 & matrix ) Parameters Name Type timestampfloatanim_numstd::size_tgltf_datalv_gltf_model_t *nodefastgltf::Node *matrixfastgltf::math::fmat4x4 &
void lv_gltf_model_send_new_values ( lv_gltf_model_t * model ) Parameters
Name LV_GLTF_NODE_PROP_POSITIONLV_GLTF_NODE_PROP_ROTATIONLV_GLTF_NODE_PROP_SCALE
Used by 1 function
lv_gltf_data_get_primitive_from_mesh — param mesh
Member Type Description filenameconst char *assetfastgltf::Assetnodeslv_array_tnode_by_light_indexNodeVectortransformsNodeTransformMapopaque_nodes_by_material_indexMaterialIndexMapblended_nodes_by_material_indexMaterialIndexMapibm_by_skin_then_nodeIbmBySkinThenNodeMapvalidated_skinsstd::vector< size_t >skin_texstd::vector< GLuint >local_mesh_to_center_points_by_primitiveNodePrimCenterMapviewerslv_array_tmeshesstd::vector< lv_gltf_mesh_data_t >texturesstd::vector< GLuint >channel_set_cachestd::map< fastgltf::Node *, std::vector< uint32_t > >view_matfastgltf::math::fmat4x4view_posfastgltf::math::fvec3vertex_maxfastgltf::math::fvec3vertex_minfastgltf::math::fvec3vertex_cenfastgltf::math::fvec3animation_update_timerlv_timer_t *current_animationsize_tanimation_speed_ratiouint32_tlast_anim_numint32_tbound_radiusfloatcurrent_animation_max_timeuint32_tlocal_timestampuint32_tlast_tickuint32_tcamerauint32_ttransforms_changedboolis_animation_enabledboolwrite_ops_pendingboolwrite_ops_flushedboollinked_view_sourcestruct _lv_gltf_model_t *
using UintVector = std::vector <uint32_t>
using IntVector = std::vector <int32_t>
using LongVector = std::vector <int64_t>
using NodePtr = fastgltf::Node *
using NodeIndexPair = std::pair < NodePtr, size_t>
using NodeIndexDistancePair = std::pair <float , NodeIndexPair >
using NodePairVector = std::vector < NodeIndexPair >
using NodeDistanceVector = std::vector < NodeIndexDistancePair >
using MaterialIndexMap = std::map <uint32_t , NodePairVector >
using StringNodeMap = std::map < std::string, NodePtr >
using NodeIntMap = std::map < NodePtr, uint32_t>
using NodeVector = std::vector < NodePtr >
using NodePrimCenterMap = std::map <uint32_t , std::map <uint32_t , fastgltf::math::fvec4 > >
using IbmBySkinThenNodeMap = std::map <int32_t , std::map < fastgltf::Node * , fastgltf::math::fmat4x4 > >
#define LV_GLTF_NODE_CHANNEL_X 0
#define LV_GLTF_NODE_CHANNEL_Y 1
#define LV_GLTF_NODE_CHANNEL_Z 2
#define LV_GLTF_NODE_CHANNEL_W 4
Includes (10) Included By (1) Transitive (3)
Last updated on