Home Technical Talk

Methods for hard environment modeling - interiors

Heya,

New question for all you pros out there. I know environmental modeling takes different forms dependent on the game or scene being produced. Just to focus, though, let's use buildings as an example. In FPS buildings, is there a methodology to unwrapping any buildings, or even interior areas like hallways or rooms, that is different than unwrapping a typical object (like a mailbox or door)?

I've read several sites (such as www.poopinmymouth.com's tutorial on 'Thirding'), but I'm still somewhat confused. If you build a structure to use tiling textures, how do you unwrap something like that to be able to use tileable textures? And what do you do if your hallway or building isn't square or rectangular, but is curved or something a little less standard in shape?

With what I've studied so far, we haven't covered this type of environmental modeling very much. We've done tons of individual assets and a few characters, to include high-poly and normal mapping, but modeling full-blown scenes without having to use tons of high-res textures (such as a single texture for an entire wall) is alien to me.

Here's an example of what I'm talking about. Post-War Scene. (linked due to size) This is part of a project I finished up last semester. Total tri-count for the whole scene is around 15,000, including assets, which isn't too bad. The problem is with the textures. The grocery store in the center has 2048x2048 diff/spec/norm maps for just the walls, and uses another 10-12 smaller textures for other parts, which in my opinion is pretty ridiculous if I were shooting for more of a real-time style scene.

And that's the problem. I'm not really looking for critiques on this piece so much as a change to methods so I could become more efficient in my modeling and texturing. I'm fine on stand-alone assets, but if I want to do full-blown environments, I need to get some new techniques.

Replies

  • Eric Chadwick
    Options
    Offline / Send Message
    Some great tips from an artist who worked on Gears of War...
    http://boards.polycount.net/showflat.php?Number=91531
  • Droknar
    Options
    Offline / Send Message
    Thanks for the link, Eric. I'm currently working on a project that revolves around some higher-tech interior environments, and I've been focusing my modeling and normal mapping on modularity. It's been torture to get all of the different hallway sections to be seamless when butted up against each other, but it's moving along (albeit slowly).

    Seems a lot of the discussion on that thread is pretty high-level. As strange as it sounds, I understand that more than the simple, basic methodology behind the kind of environmental modeling Rorshach was talking about. He mentions getting 60-80 assets out of his modular designs, but how did he reuse these assets? Was it a simple 'just put this column somewhere else,' or was he able to mix and match the geometry and maps he'd already made in other assets?

    I suppose this is in essence what I'm looking for. How do you model something to be modular, or to be able to reuse the same small texture over larger portions of a structure or hallway? My current hallway segments are ring-shaped, unwrapped and essentially mirrored, with no problems on the normal map when I throw it into max. The walls, floor, and ceiling are all on the same unwrap, with pipe sections and lighting on a second unwrap.
  • Eric Chadwick
    Options
    Offline / Send Message
    Geometry is modular when the edge vertices match up, though you can also cheat by interpenetrating meshes, or by covering up an ungainly transition with a column/debris/whatever.

    Reusing textures, hmmm. If you don't understand "thirding" I'm not sure how to explain it.

    I recall seeing some more tips from Rorshach about modularity, I'll try to find the thread...
  • Eric Chadwick
  • Black_Dog
    Options
    Offline / Send Message
    Black_Dog polycounter lvl 17
    [ QUOTE ]
    how do you unwrap something like that to be able to use tileable textures?

    [/ QUOTE ]

    You can simply extend uv coords outside [0..1] to get tiling. UV coordinates will always map to some point in a texture, and the mapping is done so anything that is contiguous in uvspace will texture nicely. This means that for any axis in which a texture is seamless, you can freely ignore the texture boundary.

    Take the example of a quad that is 2048*512 units in size, on which you wish to tile a 512*512 seamless texture. You would do something like unwrap the quad to the full size of the 512, then scale the uvs by 400% on the x-axis.

    (sorry if you already understand these basics - it seemed to me that you didn't quite twig the way uvs work)
  • Droknar
    Options
    Offline / Send Message
    Ah, so in Max, the quad's actual unwrap would extend outside the blue bounding box, but the 512x512 texture tiles that direction anyway?

    And how do you ensure your geometry meets those exact dimensions so precisely?
  • Black_Dog
    Options
    Offline / Send Message
    Black_Dog polycounter lvl 17
    Yes, the uv vertices would be outside the texture's bounds in the uv window.

    Your geometry won't need to meet any criteria for this to work - you can unwrap pretty much any geometry and scale it outside the texture bounds just fine. Scaling doesn't have to be an exact multiple of the texture size (although you may want this if your texture is something like panels), as what is important is that uv coords are contiguous. I simply happened to choose nice values for my example so it would be clear.
  • Droknar
    Options
    Offline / Send Message
    What if you had a 2048 wall and two or three different 512 panel types, and wanted to mix and match?

    In that case would you have a multi-sub texture and simply apply different material IDs to each section of the wall, leaving the UVs the same?

    And I'm assuming you'd have to engineer your wall to support that by slicing the geometry into fourths, right?
  • Black_Dog
    Options
    Offline / Send Message
    Black_Dog polycounter lvl 17
    Cutting the geometry and applying different textures is how that is done, yes. Your other alternative would be to create and uv each of your sections separately (although making sure the edges match up), and then just copy them to plop into place as desired.

    Another common technique to break up tiling is to use the one seamless texture, but add points of interest using decals. In your scene http://students.guildhall.smu.edu/~mjones/wip/post_war_scene.jpg, you might have used that approach for the areas on the far right building where bricks show through the plaster. Combined with thirding or similar tiling schemes, you should be able to texture the whole building nicely without using too much space or too many draws.
  • Droknar
    Options
    Offline / Send Message
    Gotcha. I was told by our professor earlier that semester that using decals was one method, but I wasn't getting very convincing results. At the time, though, I wasn't using normal maps, so I may have been convinced if I were at the time. Thanks for the tip.
  • Eric Chadwick
    Options
    Offline / Send Message
    Good advice.

    You might also find some nuggets in "Beautiful, Yet Friendly" by Guillaume Provost.
  • coldwolf
    Options
    Offline / Send Message
    coldwolf polycounter lvl 18
    Wonderful thread, but I was wondering, do any game engines allow out-of-bounds vertices?
  • Black_Dog
    Options
    Offline / Send Message
    Black_Dog polycounter lvl 17
    Out of bounds? If you mean uv coordinates outside [0..1], then handling that is taken care of by the rendering API. AFAIK you just pass in texture coordinates as floats, and the hardware/driver figures out what texels to fetch from there.
  • coldwolf
    Options
    Offline / Send Message
    coldwolf polycounter lvl 18
    Yes, that's exactly what I was wondering. I'll test this in the Source engine later, and if it works then the biggest roadblock ever (building static props--like buildings--with tiling textures) will be cleared. Cheers Black_Dog.
  • adam
    Options
    Offline / Send Message
    adam polycounter lvl 19
    cold it'll be fine in Source. However, why are you create buildings as meshes with the Source engine? It's BSP based - use brushes with tiling textures to create the facades. Smaller static props can make up the smaller details.
  • coldwolf
    Options
    Offline / Send Message
    coldwolf polycounter lvl 18
    The Source engine hates brushes--they should only be used for primitive shapes. My building is not a simple shape and can't be done with brushes anyway, sooo... I'm meshin' it up (for the complicated parts).

    Source is pretty weird. Collision is tricky (to automate or manually generate, that is the question), displacement geometry is actually faster than blocky brushes, water is a bitch, and... well it's pretty annoying, but whatever. I can still make what I want, most of the time.
Sign In or Register to comment.