본문 바로가기
LibGdx

libgdx-loading page implementation 5

by ses jeon 2019. 11. 17.

============== Continue from previous post ====================

First we'll put some big data in order to get a bit like the actual loading screen.
The model made with the blender looks fine.

Blender modeling is another area, so let's move on. This post describes the modeling part.
Please note.

Export-> FBX as follows. In the setting, only the size is 1/100. The fbx transform is said to be 100 times the original size. So 0.01 times to come back to the original size.

This article is about converting the blender model in libgdx.

https://github.com/libgdx/fbx-conv

 

libgdx/fbx-conv

Command line utility using the FBX SDK to convert FBX/Collada/Obj files to a custom text/binary format for static, keyframed and skinned meshes. - libgdx/fbx-conv

github.com

The conversion process.

Now put the converted g3dj file in the assets folder. Then go to the loading page.

Add the assetManager and position it to load the resource, as in step 1. You can then refresh the progress bar by measuring the execution percentage of assetManager # 2 in rendering. Very easy. Yes, the loading page we implemented through our long blog starts to look the end.

If you run it, the loading bar will appear to move one step. To make it look more practical, let's create several resources. Since we're simulating a run, let's just change the old name of human.g3dj and add it. And after 100%, we'll change the page.

Now if you run it, it will run very smoothly.

Finally, let's look at the resource dispose.

Here the resources used have been dispose. The part to look at is that resource. Instead of disposing the image, the original disposes of a texture called img. myFont disposes the font, not the label. The previous post also disposes the model and instance did not. And if you use skin and asset, you only need to dispose skin and asset. The progress bar with the skin and the model loaded from the asset did not work.

Dispose of memory management, called dispose, can be annoying, but you can expect this to be easier if you use the last skin or assetManager. Because you manage big chunks, not every single one. That's right. In practice, you will most likely use skin or assetManager to gain some speed. Resource management will be more organized and easier.

We finished the loading screen five times. The topic is one topic, but it seems to have covered quite a bit. All you need to do is refer to libgdx's wiki and documentation whenever you need it.

Now let's put the asset manager that we've loaded into the global, and you'll see the basic formula flow as we call it in our new screen. I think the basic settings are good enough.

Attach the model.

human.g3dj
5.35MB

 

 

 

 

 

댓글