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 Classic Chat / AGK 3dmodels/texture pipeline?

Author
Message
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 22nd May 2020 20:01 Edited at: 23rd May 2020 00:28
Hello, I would like to reach out to AppGameKit developers with this message.

I think AppGameKit is a solid, agile and stable engine for creating video games.

Note that loading 3D models is a complicated topic, which I think generates frustration and a bottleneck in users who are not expert shaders, 3D and texturing and achieving materials with acceptable graphic results.

I managed to do in these two weeks with AppGameKit great adventures, but I am frustrated trying to find a way to load my 3D models easily and suitable for the use I need in a fairly complex video game.

In the forum I found and shared different ways of loading models, others have done work on it but it is not available.
I also found that there are many discussions about which file format to use.

it is like to go a little crazy with this theme, I am currently a new user and I don't have enough agk experience to create my own loader and editor of objects, elements, textures and effects to bridge between 3d soft and AGK.

With code you can texture, and materialize objects, but on many occasions, there are 3D models that require a different type of work dynamics, and the ideal is to have a suitable tool to do this type of work, efficiently and dynamically.


I think it would help AppGameKit a lot to resolve this issue.
many users have problems with this and this is evident in the final quality of the work, since many non-advanced users in this area cannot achieve results due to not having the right tool.

I am currently having difficulties in:

- load the 3D models, define a format,
- that the load respects the scale (metric in my case), 1 unit in agk = 1 meter. (this I suppose depends on each format?)
- texture the models efficiently, easily and dynamically.
- be able to obtain names and mesh materials or sub-elements of the object, with their respective pivot, axes, rotation, and materials.
since using loadmesh or loadmeshwithchildrens, I am still not managing to get element names which is crucial.

So far the format that works best for me is .x
but I understand that it is an old format.

It does not seem to me that the method of generating multiple files with elements is a suitable solution, since it greatly complicates the editing and manipulation and the work with it.

Many times, it is practical to manipulate objects, elements, textures, colors, properties and effects of entities from the code, but that is very useful when you really need it, and very cumbersome if you want to achieve advanced graphics.

I think that a solution would be to generate an editor of materials and elements, that works in the same way as Lumion, where you import a 3D model, edit it, and if you update the 3D model, the materials are still updated automatically.

that also allows renaming elements, manipulating their pivots, changing materials, and that all this is automatically loaded in a friendly and simple function.

So users who are not advanced in these topics, in which I include myself, since I am not being able to load my plane properly, would have a definitive solution to this problem that I see years ago exists in the forum.


--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

conclusion, I think that AppGameKit has a bottleneck here, at this point, which greatly limits the graphic quality in 3D video games, that having a pipeline could be solved and help many users.

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

what I propose is the following.

I don't know how to program scripts, nor in anything other than basic.

My only way to achieve this is to do it with AppGameKit or B3D, so I think it is best to do it directly in AGK.

Even so, there are many things that I do not know, about shaders, I never used them, about file formats, I never understood them, but I do know a lot about 3dsmax and how to work a model to have good results with few resources.

I will try to do it, it would be ideal to do it together with other interested parties, so that AppGameKit can have it, and that the developers of AppGameKit help too. but I would definitely need help from people who know more about this than I do.


-----------------------------------------------------------------------------------------------------
Objective, would be to load with a simple function, 3D models and that are already finished, I share graphic examples of .b3D models that I model with 3dmax, using standard materials of max and some of the b3D pipeline in 3dsmax9, using the exporter b3dpipeline. and loaded into b3d using loadmesh () or loadanimmesh (), and then I just had to use Findchild () to get my parts and manipulate them like nodes, objects, wheels, spoilers, collisions, LODS etc.

Cockpit 3D, i use loadanimmesh, and i have all functions elements only need to use findhild to get the object from this 3d, then i use a update_cockpit to give live to all gauges.



Warship, i made this model in 3dsmax9 for my simulator naval, i only have to use findchild to get the objects, torrets, cannon, proppelers, helm, cranes, collision.


in this case, the 3D objects, have all elements, and manual bone mesh, the ropes and other things use nodes objects, and many propiertys of the sail works using the 3D data directly export from 3dmax9.


This ones, show, how other users can make models, and can add boats with just giving names to elements for work, if the don't put an "helice" the boat dosent have engine.
the materials, are automatic loading by the sim


This have more complex element, the n3, m3, n4... etc, works like bone to control the sails vertexs.
This works very good if you have many diferent kinds of elements, and the user can add own models.



ok, i just write to much today. look this like foward thing to do, no a critic to agk.

so, what do you thing?, what can be do?
blink0k
Moderator
7
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 23rd May 2020 00:03
Unfortunately very few people who use AppGameKit use 3DSmax. It's a bit too pricey (not free).
Most people tend to use blender or some other cheap tools like Ultimate unwrap, Wings etc
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 23rd May 2020 00:17
yes, but if we use a soft who read the 3d file, you can use any soft 3d
blink0k
Moderator
7
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 23rd May 2020 00:41
Ultimately you need to be able to load and save an object with AGK.
In order to do that you need to decipher the mesh memblock from CreateMemblockFromObjectMesh() and understand the layout of whatever 3D file format you target (.obj, .3ds, .fbx .x etc)
As far as i can see that's a very tall order and to date i have not seen anything that can save ALL the data from CreateMemblockFromObjectMesh() to a file

If you don't need bones or animation then my scene splitter should do he job (.obj format). It comes with source code so you can tailor/improve it
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 23rd May 2020 03:43 Edited at: 23rd May 2020 03:50
Are you familiar with how Lumion works?

you would not modify the 3D file. you only read the 3d file with the normal agk functions...

The idea is :
With the "materializer, to call it somehow", one loads the file "avion.x", and you can add textures, blends, alphas, you can modify where the pivots of each mesh will be, you can assign a new name to the mesh, which will be the childs in AGK.

All this, the only thing it does, is to generate a data file, with which the function within AppGameKit of load_model_3d should work.

You can also say that a mesh must be invisible, or that you delete it when loading it in agk, this has many uses.

then in agk, the mesh is loaded
all the changes that were arranged in the "materializer" are automatic applied to it. by the functions, who reads the data file we create with the materializer.

the file "avion.x" should only have been read once by the "materializer"
the file to call it "avion.mat" would be something like this.

The advantage of this is that if in the future you make a change to your 3D file, all the changes you already worked on in your .mat file are automatically applied to it, so you save a lot of production time.


file, plane.x
object1, fuselage
object1_color_r, 255
object1_color_g, 255
object1_color_b, 15
object1_alpha, 120
object1_LOD_assign, 0
object1_pivot_fix, 1.42,0.222,0 // new pivot position
texture1, t_diffuse.png
texture1_blend, 2
texture1_shine, 60
texture1_uvmap_metodh, 1
texture2, t_color_airplane_squad_4.png
texture2_blend, 2
texture2_shine, 60
texture2_uvmap_metodh, 1
texture3, t_normal.png
texture3_method, do that normal thing ...., I don't know how to do it in agk yet.

object2, prop_1
obje2_new_name, helice // the new name when i load in agk of this mesh
object2_color_r, 255
object2_color_g, 255
object2_color_b, 255
object2_alpha, 0.5
object2_LOD_assign, 0
object2_pivot_fix, 0,0,0
object2_pivot_rot, 90,0,0


It is a rough example, tomorrow I will start with the design of this program, it will be open source, and so that everyone can use it, and to collaborate those who want will be welcome.
blink0k
Moderator
7
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 23rd May 2020 04:19
Ok. Sounds awesome. I am looking forward to it
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 23rd May 2020 20:11
the concept idea, how i want to do this



blink0k
Moderator
7
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 24th May 2020 00:58
Can you interpret the underlying .3d file format yet?
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 24th May 2020 14:00
hi Blink, can you make the questions in other words?, i don't understand what mean with interpeter the format.

my english and my brains plays allways in the other team
blink0k
Moderator
7
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 24th May 2020 21:31
Can you understand the 3d file format you want to save to?
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 25th May 2020 00:41 Edited at: 25th May 2020 00:49
the idea is not write, or save, or modify the 3D file, just read it.

the idea is help to AppGameKit to load the 3D file, apply materiales who you put previusly in this soft and manage the childs, mesh, pivots, new parents upload in the load, extra data you want to add.

Today, soft use this method, like lumion, is like a new fashion, is amazing to work.

because you don't touch the 3d file
and if you change something in the 3D files, all changes you make in the materializer, automatic upgrate.

and another very good thing, is, in the 3D modeller softwares, anyone, you don't need to put textures, only give a color or material to mesh and objects, and the materializer read that info, and split mesh by materiales ID.



nother good thing of this. is...

if you have a war tanks game, you make 1 tank first, in 3d.

in the materializer you put textures to that tank, and save the .mat..

in AppGameKit you loadobject the tank.3d and next you apply the .mat that you work..


the good part, is, when you make others tanks, you only need to use the same name or color in the 3D objects, and automaticly you put the .mat materials, and all textures, blends, pivots, parts, and others things upgrate automaticly.

so, like you use a css file in webpage, this is like the same thing.
blink0k
Moderator
7
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 25th May 2020 00:59
I still don't think i understand but i look forward to seeing your progress
Good luck
nz0
AGK Developer
13
Years of Service
User Offline
Joined: 13th Jun 2007
Location: Cheshire,UK
Posted: 30th May 2020 01:16
I think I know what he means... (!)

Perhaps he's looking to generate metadata for the object (any format) and apply the properties after loading the base model.
However, I've spent some time trying to do vertex painting for instance and found issues with shared vertices on adjacent polys which is going to be a problem.

There's a nice plugin I have in lightwave which can split surfaces (meshes) into separate objects and I suppose it could be useful for assembling your own bones.
I also did something along those lines, but it was pretty painstaking and the names and orders of children changed / reset frequently for unknown reasons.

I will also be interested to see any results on this.

Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 2nd Jun 2020 15:36
Quote: "Perhaps he's looking to generate metadata for the object (any format) and apply the properties after loading the base model."

hi!, yes, this is what i trying to do


But I'm still learning AppGameKit, so it will take me some time to accomplish this.
Go to HelloWorld!
6
Years of Service
User Offline
Joined: 21st Oct 2013
Location: Skyrim,...and lost in it!
Posted: 16th Jun 2020 16:43
This is EXTREMELY INTERRESTING! I am using Blender but importing models into it is a pain. I know an Add-on to do this but it doesn't work with version 2.83 that i have with Steam. Very Annoying. And i totally agree; if AppGameKit wants to become 'used' by people making 3d games, it needs to be able to import and duplicate models easily (like the Tank idea talked about here) so you can have just to switch textures if you want, while still using only one Tank based Model.
You could then just ;
-change texture used
-change mesh geometry (individually) so you can make a bunch of new 'entity' while still using only one BASE Tank model.
etc...

yes, you would need to be able to extract exactly the right part of the 3dfile of that model and localize it... will be a problem since naming always change (as said by someone already).

You guys are really trying to make it works, it is incredibly motivating to see others who actually CARES for AGK.

I wish i could contribute but i am not advance enough in AGK. I had created a 3d Design World creator tool in the past with Dark Basic Classic, but it was only able to load an object, texture it, and save it. It was not that complex. You are looking at playing with the data of that file object directly... Impressive!!!
janbo
11
Years of Service
User Offline
Joined: 10th Nov 2008
Location: Germany
Posted: 19th Jun 2020 17:56 Edited at: 19th Jun 2020 18:01
Hey,

So Santiago3D is right, there is defenately a bottle neck in loading object with all its attributes.
I know shader, AGK's object format (its using Assimp) not so much the thousand different 3D file formats which have differences for every exporter again, .X files aren't always the same.
and I'm willing to create a Viewer/Converter/Editor for AppGameKit in AppGameKit (reason is WYSIWYG) but I'm not willing to create the GUI funktions for it as TGC had time enough to implement it.
So I'm waiting for the last survey to come into effect...hope you all voted for GUI commands

I could implement a Wireframe view, scale, rotate, offset, textures for all stages, maybe raw shader, trying to make vertex colors working again, I can generate soft normals and hard edges and save as much as the file format allows in the .x file itself and for the rest an extra file for like shader/materials.
But I'll defenately wait for AGKs GUI Commands... until then I'm happy to anser questions regarding assimps raw object format and shaders.
Would also be happy to colaborate with people for this project.

@nz0 if you look into SP_MeshManipulation of my shader pack you find a SP_ReadMeshMemblockfunktion inside of it is a if condition "if SP_GetMask(BitMask,ATTRIBUTE_HARDEDGE)" this should produce a memblock with seperate vertices and normals.
not sure if you mean this or something along the lines of this: YouTube - Drawing on Mesh Surface

@Santiago3D
at least one can find the diffuse images used in the model file with:
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 19th Jun 2020 19:38
Hello everyone

I am not clear how this works. I do not know who is who, I do not know if there is officially someone from AppGameKit who is on this topic in the forum, or we are only the users who are on this topic.

For my part, I have already emailed AppGameKit on this matter, and I am preparing a "Wish List" about my opinion on this and how it could be resolved. Although I know this is not something that will be solved now.

Although, honestly speaking, the answer to all this is very easy.

The loading of 3D models should be 100% optimized so that the human user can use it without being an expert on the subject.

When loading a 3D file, it should be loaded with the textures, at least the "diffuse", the same with its colors, and all the properties that AppGameKit can support.

It is clear to me, that there is not a single 3D file format that does not have problems in one way or another, .x, .b3d .3ds .dae ... this is what I see in the forum, and according to what other users tell me . also adding that the way of loading the file, with the scales, the childs, the bones and the mesh, has its inconsistencies.

So each user does what they can, with what they have and with what they know. There is no adequate process, we are all patching up with what we have on hand so that this does not stop development.

There should be 1 format that works 100% and a function, added by AppGameKit, that at least temporarily helps us load the 3D models until this is addressed in any update.

To give an example, in Blitz3D, one usually uses the .b3d format, which exports from 3dsmax with multi-textures, gloss, transparency, blend, etc., all the qualities of the 3D model are loaded by blitz3d, either with a "loadmesh" or "loadanimaesh" for the treatment of childs, bones, or skin.



Currently, I am implementing my own system to load my models and texture or materialize them.

In my 3D program, I try to generate my 3D model optimized for loading in AppGameKit, adding KEY-frames to it to recognize the childs, and naming the objects.

I have all my textures in PNG in the 3D file directory

Manually "for the moment" I create a .txt file where I tell it what texture or material I want to assign to each object, child, or whatever.

My 3D load function, load the file
my materialize function, check the file.txt and the names of each child, and if it finds the texture and the assigned child, it applies the texture

If there is a material that must be glass, I go to a function called "Materialize (material, object)" where I have generated standard materials, transparency, color, and I assign all those properties to the object.

I still could not safely resolve the issue of scales, because I am still testing with different export settings .dae "the only format that works for me", and the issue of scales affects the position and scale of the childs , which appear displaced.

Little by little, I am optimizing the process, and I am rearranging all my 3D models so that my AppGameKit game can load them properly.

When I have time, and enough AppGameKit experience I will try to do something about the pipelane I mentioned above.

now, fix it with a simple .txt file
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 19th Jun 2020 19:48 Edited at: 19th Jun 2020 19:50
I still have to learn to generate metallic materials, with reflections, but I will solve that in the future.

At the moment, this is the inelegant way I found to load my cockpit model that has multiple textures.

In the future, I will optimize it.



but this would be the first small step.

Then, imagine that instead of just having the info of a texture, you could add glitters, shaders, transparencies, colors, other textures, mapping, etc.







the idea, is, use a .txt to apply materials, textures, shaders, and all kind of thing in the future
for the moment, is a simple first step
and need to learn about how is the best way to load textures, where, how, and optimize that too

Jack
15
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 21st Jun 2020 13:42 Edited at: 21st Jun 2020 13:42
Hey Santiago3D,
nice screenshots

Iam looking forward to read more about simulators from you.
Do you try to utilize the 3d physics of AppGameKit? This would be awesome.

Right now I modify my level export plugin "Filebakery" in order to import vehicles and airplanes from 3dsMax.
I have managed to export the vehicles to a simple json file, that can be loaded by AppGameKit directly into a type array.
Still something to port.
I will not add the distance culling system to the AppGameKit loader as it may have bad results. But the LOD objects are still exportable from my 3dsMax plugin.
The optional prebaked lightmaps on UVW 2 still do exist, but will also not be utilized by the AppGameKit loader.
But it already does instancing and opacity.

Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 22nd Jun 2020 16:40
Hi Jack!, im new in AppGameKit, so, i using my own physics "very simple force vectors" because i just learning to use AGK.

in an airplane game there is not much physics but in collisions, which are, let's say, catastrophic.
but to move planes, in the air, I think it is not necessary

if it would be good for objects, already crashed planes that fall, or that crash into an object, there assemble the physical object and let it flow

At the moment, my LOD's are 2.
the high plane, and a very ugly model with the approximate shape of the plane in 3d, with very few polygons.

which I use to cast shadow, receive shots, and other basic functions.

the truth, that I see very tempting the option to make a function of AUTO-LOD's detail, ingame.
something like what "World of tanks" uses, which seems to have the function of optimizing 3dsmax within the game.

working LOD's today, doing everything alone, is too much work, that's why I'm not doing it in the classic style used for LODs


This is the first game I make in AppGameKit, I already had it previously advanced in BLITZ3D.

reason why I am working in the simplest possible way, and the problems that I find if I cannot solve them, I leave them temporarily so as not to stop the entire project.

now i'm working on the situation and strategy MAP
prebriefing.

It is the first time that I use Sprites in AGK.
Jack
15
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 24th Jun 2020 23:12 Edited at: 24th Jun 2020 23:19
The current state of the importer:



It just misses the point entities, in order to define the third person camera position behind the plane or
the points where the bullets should leave the wings
This exporter Supports .3ds .Obj, .Dae and .Fbx just select your favorite format, as I already mentioned it by mail,
each model type has advantages and disadvantages.

It will take some time to implement a simple entity system

Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 25th Jun 2020 15:38
Hi Jack! It looks great!
the idea of approaching the concept in this way seems great to me.

This importer you are working sounds like a lot of work!

A thought that I have is, do not focus only on airplanes, since in games there can be planes, helicopters, ships, tanks, cars, motorcycles, robots, in some way, your work should be something generic that can be applied to any type of objects, right?

My other question is, do you do this as a hobby? It sounds like a job to do this, which is something that many surely need.

Well, here I am in case you need something, or you can write to me by mail.

my greetings
Santiago
Jack
15
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 26th Jun 2020 11:22 Edited at: 29th Jun 2020 08:11
Quote: " This importer you are working sounds like a lot of work! ... It sounds like a job to do this..."

I did a xml child export for a customer once, I just had to rewrite the xml to a json. But it was once a lot of work^^

Quote: "generic that can be applied to any type of objects, right?"

Yes, it exports all sort of vehicles and even buildings with lightmaps.
For now, I just implement the Airplane management in AGK. It should be an example how to utilize the exported media.
It will be not hard at all to add ships, vehicles or airplanes. Once you see the code and know where to add your modifications

The greatest part is the freedom of format. Added export plugins to 3dsMax can be utilized aswell. So you can even export as .x file (Direct X 3D format, with plugin)

There is a FBX Export Plugin for 3dsMax somewhere on the internet where you can export the animations based on sequence names. Its well suited for AppGameKit Objects
with multiple animations.

Right now I have to create an entity system. The problem is, that a human person loves to define stuff by text and not by decimal numbers (or hex). So the plugin should utilize strings, while the entity system converts them to integers because games do not like string operations in realtime

EDIT:


I found the time to implement a simple entity system. For the sake of simplicity, I've added a dummy box object for point entities. It's way easier to get the correct position and rotation with moving/ attached parts.
Point entities are created by a 3dsMax dummy object for example. My plugin provides an interface where you can define each object as an entity.
Mesh entities are just meshes with entity definitions, just like the point entities


I just have to add shader support, make the image loading more efficient and improve the rotation system so you just have to input a value beween 0.0 and 1.0 in order to modify control surfaces.

Attachments

Login to view attachments
Go to HelloWorld!
6
Years of Service
User Offline
Joined: 21st Oct 2013
Location: Skyrim,...and lost in it!
Posted: 1st Jul 2020 00:21
I think this make no sense... i mean you could load an object with its texture in Dark Basic Classic if you had the .x object. How difficult is there to have a function that load an object with its animation and texture? Really. I totally agree that this is frustrating. I want to use AppGameKit but this is impeding my effort a lot.

You guys are really heros of everyone here if you can solve this!
Santiago3D
User Offline
Joined: 11th May 2020
Location: Argentina
Posted: 2nd Jul 2020 23:50
I currently improvise a method, something complex, rough, clumsy and not optimal, but it works.

It is not in the developers' plans to fix this, since they are with other more important issues according to what they answered me.

As I mentioned before, this problem is longstanding, and I don't see any interest in solving it in the future.

To the users, I wish that they are experts in 3D, and that they understand programming well to be able to load a 3D car, an airplane, a ship, a weapon, an animated character, a tree, any object that has more than one texture .

I just wish you luck ...

it's just what they need
obviously, my message has a frustrating tone.
Go to HelloWorld!
6
Years of Service
User Offline
Joined: 21st Oct 2013
Location: Skyrim,...and lost in it!
Posted: 4th Jul 2020 00:28
So well said... indeed.

Honestly, last week i pass all my free time on trying to understand and solve this. I even put two files in notepad and try to find the difference between an object that load ok with a texture and the ones i am making that drop their texture as soon as i animate them in blender. I am still investigating this, and i am gonna keep at this next week. I am sure that if i can find the difference between;

1-an object (character) that came from Game Guru with animation and texture that load perfectly fine in AppGameKit AND an object that i created in blender with animation that work in AppGameKit but lost his texture.
2-the .MTL files for both objects
3-and maybe the .fpe files (although this seems more like the parameter for GameGuru importer).

I could find the missing settings we need...

if anyone else have knowledge about this and have free time, this would help our community tremendously. I sadly have to keep with a full time job so i have limited time. I will still pursue this as far as i can. AppGameKit is a wonderful program, but for 3D, this is a real big Wall.

Login to post a reply

Server time is: 2020-07-04 16:38:42
Your offset time is: 2020-07-04 16:38:42