Exemple #1
0
// Get the approximated storage required by an imported asset
func (s *Scene) MemoryRequirements() MemoryInfo {
	mi := new(C.struct_aiMemoryInfo)
	C.aiGetMemoryRequirements(
		s.c,
		mi,
	)
	return MemoryInfo{
		uint(mi.textures),
		uint(mi.materials),
		uint(mi.meshes),
		uint(mi.nodes),
		uint(mi.animations),
		uint(mi.cameras),
		uint(mi.lights),
		uint(mi.total),
	}
}
Exemple #2
0
func (scene *Scene) GetMemoryRequirements() MemoryInfo {
	var meminfo C.struct_aiMemoryInfo
	C.aiGetMemoryRequirements((*C.struct_aiScene)(scene), &meminfo)
	return MemoryInfo(meminfo)
}