Home Technical Talk

One or Multiple Meshes?

Hello Polycount!

Just recently I decided to start learning 3D-modeling so I'm still a newbie. I'm using Maya 2012 and so far I've started off by getting fimiliar with the most basic tools like extrude, cut, merge, setting up image planes etc. 3 days ago I begun modeling my first "real" model which is a F4 Phantom. This has actually gone pretty well, however, I've came across a question that I can't find an answer to.

I can't remember where, but I think that I once heard that when creating a model for a game the model must be one single piece in order for the rendering to work. So my question is:

When creating models for a game, must the model be one single piece or can it consist of multiple pieces? For instance, when creating a jet, I find it a bit difficult to keep a good shape for both the jets body, its engines and the wings. How is the "correct" way that this should be done in? Can these parts be splitted up in mutiple pieces that are just aligned together or won't that work when the model is later going to be imported and drawn in a game? For instance, in a proffesional game, are the models just consisting of one single piece or multiple pieces?

I'm using the word "piece" here as I'm not entirely sure if I should use polygon, mesh or component. I havn't learned the difference between these yet. What I mean by "piece" is simply 2 different pieces of geometry. Imagine a lollipop made out of 1 cylinder and 1 sphere (2 pieces) or 1 sphere where the bottom is extruded into a cylinder (1 piece).

I hope that you understand what I mean and thanks in advance :)

Replies

  • Kimon
    Options
    Offline / Send Message
    Kimon polycounter lvl 6
    If you're doing something as complex as a jet you probably want to make a proper high poly and bake that thing. As for the high poly, just think about how the pieces are put together in real life. Is it built up by a lot of different plates and pieces? Then model it that way! Have 400 meshes in your high poly if that's how it looks in real life. There's no point in having a super complex high poly with crazy edge flow if it's seperate pieces in real life, like plates on a tank or whatever.

    As for the low poly; Will it cause any real problems or errors to have intersecting pieces everywhere? No, but it is however good practice to keep as much as possible connected and 'water tight' on your lowpoly because if you have stuff intersecting, you still have the underlaying geometry there, which means more unwrapping, more difficult to bake, and more wasted texture space.

    Sure, to have a lot of stuff connected and continuous on your low poly can mean that you end up with a few more tris, but with todays gaming machines the textures (memory) is on a waay tighter budget than the polys. Polygons are hardly a problem anymore (but it's always good to keep stuff optmized, ofc) but textures and memory still are.

    So I say:

    For the high poly, model it as it looks in real life. No reason to have edges going everywhere if you don't need to.

    For the low poly: keep as much as possible connected, except for small parts, like grips or handles or whatever, that you wish to place all around your mesh. Those things will benefit greatly from sharing texture space and that will more than make up for the texture space they waste underneath them.

    Well, that's my two cents anyway :)
  • cryrid
    Options
    Offline / Send Message
    cryrid interpolator
    so my question is: When creating models for a game, must the model be one single piece

    Long story short, no.
  • falcon93
    Options
    Offline / Send Message
    Thanks for your replies :)
    Kimon wrote: »
    If you're doing something as complex as a jet you probably want to make a proper high poly and bake that thing.

    This is new to me, so I'll have to ask; Why creating a high poly and a low poly? Are there any special reasons to why this should be done? I thought that only the actual model that would be used in the game was modeled? :)

    Kimon wrote: »
    As for the low poly; Will it cause any real problems or errors to have intersecting pieces everywhere? No, but it is however good practice to keep as much as possible connected and 'water tight' on your lowpoly because if you have stuff intersecting, you still have the underlaying geometry there, which means more unwrapping, more difficult to bake, and more wasted texture space.

    Ok, so I'll try to model everything that is not too complex as one single piece. So for instance, when I model the jet, I should not make the wings as separate pieces but instead try to extrude them from the jets body?

    However, I just started to think about another thing. Let's imagine a tank, where the turret should be rotatable and the threads should animate in the game. Then the model should be 3 pieces, the body, the turret and the threads, correct?

    Also, when it comes down to DirectX (I'm using directX 11), do I need to handle a model consisting of 1 single piece different compared to a model consisting of multiple pieces?

    Thanks for your help :)
  • Chael
    Options
    Offline / Send Message
    In most games that I've worked with if you have intersecting geometry you will have z-fighting (http://en.wikipedia.org/wiki/Z-fighting). It gets worse the farther the objects are from the origin (0/0/0).

    Yes, a tank turret should be a separate piece (two if your barrel has pitch). As for tank treads I'm not so sure; I've only seen them done with animated UVs (texture coordinates), so I don't think there's a need to have them as a separate mesh.

    What game engine are you using/planning to use?
  • falcon93
    Options
    Offline / Send Message
    Chael wrote: »
    In most games that I've worked with if you have intersecting geometry you will have z-fighting (http://en.wikipedia.org/wiki/Z-fighting). It gets worse the farther the objects are from the origin (0/0/0).

    Yes, a tank turret should be a separate piece (two if your barrel yaws). As for tank treads I'm not so sure; I've only seen them done with animated UVs (texture coordinates), so I don't think there's a need to have them as a separate mesh.

    What game engine are you using/planning to use?

    Thanks for your reply.

    Currently I'm trying to learn DirectX 11 aswell so I'm trying to write my own engine :)

    Edit: With separate pieces (for instance the tank turret and the barrel), does the pieces need to be saved and exported separately or can they be placed in the same file but as separate pieces (meshes)?
  • s6
    Options
    Offline / Send Message
    s6 polycounter lvl 10
    falcon93 wrote: »
    Edit: With separate pieces (for instance the tank turret and the barrel), does the pieces need to be saved and exported separately or can they be placed in the same file but as separate pieces (meshes)?

    Yes, multiple objects can exist in the same scene and will export with one another.

    The reason you would create a highpoly is to transfer high resolution details to the low resolution geometry (your lowpoly) via "render to texture" AKA baking. This is done through normal maps, ambient Occlusion, Cavity/convexity, World space normals, Etc etc. All of these texture maps are capable of different things, but they all create the illusion that the lowpoly has something it doesn't such as surface detail or lighting information.

    For Example, here is a shotgun I baked last night. The first image is the highpoly. Millions of polygons that would never be able to run efficiently in an engine. The Second image is the 6,672 triangle lowpoly, with a baked normal map, which wouldn't look nearly as polished and detailed if it didn't have a normal map/highpoly bake. The surfaces would all be faced, there would be no details such as bolts and pins, or surface damage on the grip.

    In addition, this shotgun is several different meshes. It bakes, renders, exxports, and animates just fine as long as you know a few rules.

    Wyu1JF.png

    N2gTRX.png


    The highpoly allows you to add an extreme amount of detail to you're model at a relatively low tax on modern engines. Unless your restricted on the amount of texture memory you can use (if your developing for mobile perhaps) maybe you're better off with just lowpoly. Otherwise, learn highpoly modeling! :thumbup: it's fun too :poly124:

    Be sure to post WIPs in the pimping and preview section when you have some progress and need feedback.
  • Chael
    Options
    Offline / Send Message
    If you're writing your own engine you can just try this stuff out. More meshes per asset will probably mean more render calls, which means lower FPS. If you have separate meshes for each part, you can just combine them into one mesh as long as they don't need to move relative to each other. If there are multiple texture files for a model, each set of faces with a texture will have to be rendered as a separate object, meaning more render calls. Just write it to work the way you want; you'll figure it out.
  • Chael
    Options
    Offline / Send Message
    Oops, doublepost...

    Any visible issues from multiple meshes will be the result of intersecting geometry, so just don't do that (unless you have to, or if it won't be visible and helps performance). There are ways to tell one object to always render in front of another such as depth bias, but it's not perfect. I'm not sure if they use a different method for things like roads on terrain.

    Hope this helps.
Sign In or Register to comment.