Structures#
Internal data handler module. Provides dataclass-based structures representation.
🧮 Flags#
Enum for 3D scene flags.
🏞️ Scene#
Dataclasses for scene of 3D models.
- class SceneScales(position=1.0, texture=1.0, unknown=1.0, filtering=0.1)[source]#
Multiplier values for scene components.
-
position:
float= 1.0#
-
texture:
float= 1.0#
-
unknown:
float= 1.0#
-
filtering:
float= 0.1#
-
position:
- class SceneCounts(meshes=0, bones=0, clips=0)[source]#
Quantifying of scene elements.
-
meshes:
int= 0#
-
bones:
int= 0#
-
clips:
int= 0#
-
meshes:
- class ModelScene(scale=<factory>, count=<factory>, meshes=<factory>, skeleton=<factory>, animation=<factory>)[source]#
Complete 3D model container with geometry, skeleton and animation.
-
scale:
SceneScales#
-
count:
SceneCounts#
-
skeleton:
ModelSkeleton#
-
animation:
ModelAnimation#
- property total_vertices#
- property total_polygons#
-
scale:
🕸️ Mesh#
Dataclasses for 3D model geometry.
- class MeshCounts(vertices=0, polygons=0, links=0, bones=0)[source]#
Quantifying of mesh elements.
-
vertices:
int= 0#
-
polygons:
int= 0#
-
links:
int= 0#
-
bones:
int= 0#
-
vertices:
- class MeshOrigin(position=<factory>, rotation=<factory>, scale=0.0)[source]#
-
position:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
rotation:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
scale:
float= 0.0#
-
position:
- class ModelMesh(name='name', material='material', count=<factory>, origin=<factory>, bones=<factory>, positions=<factory>, textures=<factory>, normals=<factory>, links_ids=<factory>, links_weights=<factory>, polygons=<factory>)[source]#
3D mesh geometry container.
-
name:
str= 'name'#
-
material:
str= 'material'#
-
count:
MeshCounts#
-
origin:
MeshOrigin#
-
bones:
dict[NewType(LocalBoneId,int),NewType(SkeletonBoneId,int)]#
-
positions:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
textures:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
normals:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
links_ids:
Annotated[ndarray[tuple[Any,...],dtype[uint8]]]#
-
links_weights:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
polygons:
Annotated[ndarray[tuple[Any,...],dtype[uint32]]]#
-
name:
🦴 Skeleton#
Dataclasses for 3D model armature.
- class SkeletonBone(id=0, name='bone', parent_id=-1, position=<factory>, rotation=<factory>, children=<factory>)[source]#
Single skeleton bone with transform data.
-
id:
int= 0#
-
name:
str= 'bone'#
-
parent_id:
int= -1#
-
position:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
rotation:
Annotated[ndarray[tuple[Any,...],dtype[float32]]]#
-
children:
List[Self]#
- property is_root: bool#
- property quaternion: Annotated[ndarray[tuple[Any, ...], dtype[float32]], Ellipsis, 4]#
-
id:
- class ModelSkeleton(bones=<factory>)[source]#
Skeleton bones container.
-
bones:
List[SkeletonBone]#
- property roots: List[SkeletonBone]#
-
bones:
🎬 Animation#
Dataclasses for skeletal animation (clips/actions).
🧱 Texture#
Dataclasses for game specific textures.
- class Texture[source]#
Bases:
ABCBase dataclass representing texture.
- abstract property image: bytes#
- abstract property linear_size: int#