Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Studio Chat / How do I export multiple meshes in one file from Blender 2.8?

Author
Message
Timshark
16
Years of Service
User Offline
Joined: 30th Jun 2007
Location: Oslo, Norway
Posted: 1st Dec 2019 11:54 Edited at: 1st Dec 2019 12:06
Hi there
I've searched and found a couple of threads with this subject in here - but I'm still unable to achieve anything.

I want to be able to export a geodesic dome of hexagons and pentagons. I have my model in blender 2.8 - where each hexagon is a single mesh:



When I try to export it to any format (dae, fbx.. etc) I get only one mesh in agk.
In some other threads here I've read that you need to make sure each object has a unique material before you export.
I have tried this with some of the hexagon objects but still no luck....

Anyone know how to do this?

Tim

Attachments

Login to view attachments
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 1st Dec 2019 12:22
Raven
19
Years of Service
User Offline
Joined: 23rd Mar 2005
Location: Hertfordshire, England
Posted: 4th Dec 2019 16:00
I'd recommend using the FBX Exporter... next be sure that 'Selected Objects' and 'Active Objects' are UNCHECKED., this will just output your entire scene "As-Is" to FBX.
There's no need to assign a material per se., but I would recommend creating a Base Material that you assign (even if you have no intention of using it)

Also., while I tend not to use Blender much for modelling., something I do out of habit today with Maya is with a new Scene, disable "Show Backfaces" because with Maya when this is on; this will show Front and Back Faces as if they're the same... but as most Renderers only support Single Sided Faces; this results in most being turned inside out (or unviewable) without writing a Double Face Shader.
Generally this means the Normal Faces need to be Flipped to become Forward Faces... this could potentially be an issue.
Another could be that you have automatic Show/Hide Objects with Selection; and the Export Function just does a "Raw" Dump of the Scene as an Exported Object; so if the Object is "Hidden" in Scene it's also "Hidden" in the Export.

Something else you could do though is to use a Rooted Object... so ensuring that all of the "Sub-Mesh" are part of a Main Object within the Scene.
In this regard typically speaking they'll all inherit properties from the Root Object.
Timshark
16
Years of Service
User Offline
Joined: 30th Jun 2007
Location: Oslo, Norway
Posted: 5th Dec 2019 13:42
Hi Raven. Thanks for the help.
I've done all you said but still only 1 mesh in agk.

Could it be the exporter in Blender 2.8 that combines the objects?

I will include the file in this post if someone want to try.

Tim

Attachments

Login to view attachments
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 5th Dec 2019 20:00 Edited at: 5th Dec 2019 20:04
If you want to save a scene in blender and load individual objects
you have to read the file and load the objects separately I posted a link that does this for you

Otherwise you have to select one object at a time and use the save as selected object option in blender
fubarpk
fubarpk on Itch...………...https://fubarpk.itch.io/
fubarpk on googleplay..https://play.google.com/store/apps/developer?id=fubarpk
Bengismo
6
Years of Service
User Offline
Joined: 20th Nov 2017
Location: Yorkshire, England
Posted: 5th Dec 2019 21:32 Edited at: 5th Dec 2019 21:40


Its a nightmare to do it and its really to do with AppGameKit and its loading......

Short answer is AppGameKit uses open asset importer to load 3d files and specifically it uses an optimisation step (aiProcess_OptimizeGraph)to group all your model parts into one mesh (if it can group them and they are not unique in anyway). Normally this is a good idea as it leads to faster rendering - less draw calls etc...

One way of stopping it is to make each object use individual textures/materials which does work. Another is to apply a unique bone to each part. I WOULD NOT want to do that for >640+ parts unless you want to automate that somehow in blender

The other option is to disable the optimise flag in AppGameKit which I did above to get the result shown in the pic. Its possible in Classic but I cant help you with studio as we cant recompile that.

As fubarpk says you could save many objects using the tool he linked to so that you have a model file for every hexagon which is separately loaded <--- this is probably your best option right now.
Timshark
16
Years of Service
User Offline
Joined: 30th Jun 2007
Location: Oslo, Norway
Posted: 6th Dec 2019 09:38
Hi all

Thank you all.
Finally I now understand more of what is going behind the curtains or why this is happening. I am very thankful for the efforts from all of you.

Great help-

Tim

Login to post a reply

Server time is: 2024-04-13 15:59:12
Your offset time is: 2024-04-13 15:59:12