Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Page 1 of 2 12 LastLast
Results 1 to 10 of 19

Thread: Warcraft 3 landscape texturing....

  1. #1
    Intern Contributor
    Join Date
    Aug 2000
    Location
    Epinay sur Seine, France
    Posts
    94

    Warcraft 3 landscape texturing....

    Hi,

    well, may be someone has an idea about this :
    i'm sure you've already seen some warcraft 3 pictures . How the hell the texture is performed ?? huge textures ?? small textures blended with alpha tiles set ?? multitexturing (sure )?? something else ??

    How would you handle this kind of landscape texturing ??
    One life for hate , one eternity for love [img]/forum/images/%%GRAEMLIN_URL%%/smile.gif[/img]

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Feb 2000
    Location
    France
    Posts
    1,118

    Re: Warcraft 3 landscape texturing....

    I don't know, but on the site you pointed out, I read:

    "WarCraft III will be compatible with Direct3D and Glide 3D APIs. Direct 3D was chosen over OpenGL for superior features of hardware transformation and lighting skinned models."

    Stupid...

    So they don't use OpenGL... That being said, I am sure some people here will have ideas on how to reproduce the effect you describe !

    Regards.

    Eric

  3. #3
    Senior Member OpenGL Guru
    Join Date
    Feb 2000
    Location
    Sweden
    Posts
    3,115

    Re: Warcraft 3 landscape texturing....

    OpenGL or Direct3D, the way to go is still the same. I have no clue what so ever what they do, but to get similar effects, you can use multitexturing with greyscale masks, along with multipass rendering. It's not that difficult once you understand. Detail textures is/can be used to get the effect of very high-resolution textures when you are close to the specific geometry being textured.

    I have some code at home that does multipass rendering, with multitexturing using the textures along with a greyscale mask. Tell me if you want some code. Just some pieces ready to cut-n-paste, no working program source. And no detail textruing.

  4. #4
    Intern Contributor
    Join Date
    Aug 2000
    Location
    Epinay sur Seine, France
    Posts
    94

    Re: Warcraft 3 landscape texturing....

    from Bobyou can use multitexturing with greyscale masks, along with multipass rendering
    Yeah, it's seems to be the obvious thing to do....
    Lately i was implementing my multitex code. I was thinking that each texture level had his own blending and i finally understood that it was not the case (or may be i did something wrong....) So multipass seems to be the right thing to do, but this may cost a lot for landscape rendering....
    One life for hate , one eternity for love [img]/forum/images/%%GRAEMLIN_URL%%/smile.gif[/img]

  5. #5
    Senior Member OpenGL Guru
    Join Date
    Feb 2000
    Location
    Sweden
    Posts
    3,115

    Re: Warcraft 3 landscape texturing....

    First time I did this in my landscape engine, I drew the whole landscape (well, only the visible stuff) twice, once for each texture (I had two textures along with a greyscale mask). And I was amazed that the performace hit was as small as it really was when drawing the landscape twice instead of only one time. I was expecting nearly halved framerate. Now I don't remember the numbers, but it wasn't as much as 50% (on a TNT by the way).

    I improved this by making simple checks to make sure I'm not drawing loads of areas twice, when only one texture is visible.

    If you got some sort of height-based, or similar, method to determine what textures to draw, you can check the primitives height, and then only draw the textures that is visible on the given height.

    If using height-based, or anything else, you can make it so that any given primitive in the landscape is never affected by more than two textures. Then you can easily setup a blending function to perform C=(T1*G)+(T2*(1-G)), and then draw the primitive. C is the resulting texture color, T1 and T2 is your two textures, and G is the greyscale mask. G can be a 1D textur if you like.

    Anyways, just a few tips. This is at least how I managed to perform multipass multitexturing without much performance hit compared to one repeated texture and one pass.

    [This message has been edited by Bob (edited 01-08-2001).]

  6. #6
    Senior Member OpenGL Pro
    Join Date
    May 2000
    Location
    Hannover, Germany
    Posts
    1,258

    Re: Warcraft 3 landscape texturing....

    I'm still laughing about your:
    It's not difficult once you understand.

    Bob, that remembers me of some teachers... Well, don't get me serious today, sorry.
    - Michael Steinberg

  7. #7
    Senior Member OpenGL Guru
    Join Date
    Feb 2000
    Location
    Sweden
    Posts
    3,115

    Re: Warcraft 3 landscape texturing....

    Hehe, no worries, I know it sounds silly.

    But in this case, I think it's somewhat true. I have experienced cases where the it's-not-difficult-once-you-understand-thinge doesn't apply, and then I'm talking about those nasty Laplace-transformations in the wonderful world of mathematics. I understand them, but I find them IN NO WAY easy to use.

    Never mind, just talking some bullsh*t again.

  8. #8
    Senior Member OpenGL Pro
    Join Date
    Feb 2000
    Location
    France
    Posts
    1,118

    Re: Warcraft 3 landscape texturing....

    Originally posted by Bob:
    [B]those nasty Laplace-[B]
    That's a good example !
    I also have Topology (in the mathematical sense) of functions... Hard to understand... Even harder once you understood...

    Regards.

    Eric

  9. #9
    Senior Member OpenGL Guru zed's Avatar
    Join Date
    Jul 2000
    Location
    S41.16.25 E173.16.21
    Posts
    2,609

    Re: Warcraft 3 landscape texturing....

    looks pretty simular to what im doing
    (though mines better cause "opengl was chosen over d3d for superior features of hardware transformation and lighting skinned models"
    heres my site http://members.nbci.com/myBollux
    check out the combine extensions demo's also gotterdammerung is what im working on at the moment. though ive gotta say those screenshots are a bit dated now.

  10. #10
    Senior Member OpenGL Pro
    Join Date
    May 2000
    Location
    Hannover, Germany
    Posts
    1,258

    Re: Warcraft 3 landscape texturing....

    What the hell are you talking about? Laplace?
    - Michael Steinberg

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •