Jump to content
The Dark Mod Forums

Grafitti please


Hecateus

Recommended Posts

Just to let Bob and everyone know this hasn't been forgotten, now that it dropped off the front page. I did #1 and #2 last night. #3 should be a lot simpler than #2, so although I have very limited tdm time the next two days (travelling) I'll be back with results soon.

  • Like 1
Link to comment
Share on other sites

1. Glowing symbols (permanently visible)

...

2. Graffiti (stains on the wall)

...

3. Secret symbols (gleam in only one particular light)

...

I've not done (3) yet because it looks like ID never got round to implementing "spectrum" and neither have we! It's a material keyword, but there's no corresponding setting for lights, so unless we decide we want to fix that, it's unusable.

 

Here's a look at 1 and 2, and I'll post the mtr definitions too. These all use Bob's maps above without any tweaking (except that I re-saved them as tga. I'm not sure whether that was necessary or not). All can have their color adjusted using the "_color" spawnarg.

 

1: The easy one, glowing symbols unaffected by light or shadow. Lots of games use these of course, but it's not very TDM. Perhaps useful for occasional magic stuff:

post-29566-0-43994200-1436307311_thumb.jpg

 

2: Here's a material shader I think we'll like better: a filter blend that stains the wall behind:

post-29566-0-35195200-1436307327_thumb.jpgpost-29566-0-70599900-1436307329_thumb.jpg

 

The shaders:

 

 

// Thief / hobo signs found by Melan, images by Bob Necro, material defs by SteveL
// http://forums.thedarkmod.com/topic/17228-grafitti-please/

textures/darkmod/decals/graffiti/sign_leave_quickly_glowing
{
    description "Thief/hobo warning sign. Make the decal a func_static and use the _color spawnarg to set the colour."
    qer_editorimage textures/darkmod/decals/graffiti/sign_leave_quickly
    
    nonsolid
    DECAL_MACRO

    {
        blend add
        map textures/darkmod/decals/graffiti/sign_leave_quickly
        colored
    }
}


textures/darkmod/decals/graffiti/sign_leave_quickly_dark
{
    description "Thief/hobo warning sign. Make the decal a func_static and use the _color spawnarg to control the colour."
    qer_editorimage textures/darkmod/decals/graffiti/sign_leave_quickly
    
    nonsolid
    DECAL_MACRO
    
    // darken the underlying surface
    {
        blend gl_zero, gl_one_minus_src_color
        map textures/darkmod/decals/graffiti/sign_leave_quickly
        rgb 0.75    // the darkening factor, range 0->1. The bigger this is, the darker the stain
    }
    
    // then add a colored blend
    {
        blend gl_dst_color, gl_one
        map textures/darkmod/decals/graffiti/sign_leave_quickly
        colored
    }
}

 

  • Like 4
Link to comment
Share on other sites

I've not done (3) yet because it looks like ID never got round to implementing "spectrum" and neither have we! It's a material keyword, but there's no corresponding setting for lights, so unless we decide we want to fix that, it's unusable.

Isn't the keyword usable in light shaders?

 

Edit: I never tried the 'secret sign' idea, but I did try to use "spectrum" with shadow casting. Here's a room I showed on the 'What are you working on?' thread a while back: note the shadows running onto the far wall and down the portrait.

 

 

itb2.jpg

 

 

Since that room has eight overlapping lights, I tried using "spectrum" to keep the lights - and the shadow pattern on the ceiling - while using a single light to illuminate everything else. Here the shadows don't extend onto the wall and portrait:

 

 

spectrum.jpg

 

 

I'm not sure how much it did improve performance; f.p.s. numbers didn't shift much, but the room feels smoother to me. At any rate, "spectrum" does seem to have done something to affect which surfaces receive illumination from which lights.

Edited by VanishedOne
  • Like 1

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

Isn't the keyword usable in light shaders?

Doh! Yes of course, that'll be how it works. I was forgetting lights have a material too. I couldn't find any light property using spectrum, just a material property, and jumped to the wrong conclusion.

 

Time to reattempt #3

Link to comment
Share on other sites

Isn't the keyword usable in light shaders?

 

Edit: I never tried the 'secret sign' idea, but I did try to use "spectrum" with shadow casting. Here's a room I showed on the 'What are you working on?' thread a while back: note the shadows running onto the far wall and down the portrait.

 

 

itb2.jpg

 

 

Since that room has eight overlapping lights, I tried using "spectrum" to keep the lights - and the shadow pattern on the ceiling - while using a single light to illuminate everything else. Here the shadows don't extend onto the wall and portrait:

 

 

spectrum.jpg

 

 

I'm not sure how much it did improve performance; f.p.s. numbers didn't shift much, but the room feels smoother to me. At any rate, "spectrum" does seem to have done something to affect which surfaces receive illumination from which lights.

Height overlapping lights? Imo that's overkill, that means a single surface and object on that entire scene is being rendered eight times per frame, on idtech 4 the single feature most capable of killing performance is overlapping lights. The old rule in real time lighting based games was to not have more than 4 dynamic lights visible per frame, on deferred renders only true for shadow casting lights, the later not relevant for Darkmod tho because the engine (idtech 4) uses the "old" forward rendering technique.

 

quote from Frictional games developer very relevant for Darkmod

 

Forward Rendering

The engine powering Penumbra (HPL1) uses something called forward rendering. This type of rendering works by rendering the entire scene on an object basis. So when rendering a chair, wall, or any geometry in the world, this was done by drawing it one time for every light that touches it. So an object that is lit by three lights has to be drawn three times, and so on. This technique can be quite limiting when setting up scenes as you need to be very careful when adding lights. It might not actually be clear exactly how much impact on performance a single light will have and levels usually require quite some tweaking to get right. The complexity of a scene can be expressed as:

 

Draw calls = Objects * Lights

 

This means that the number of draw calls can easily get very large and only adding a single light, even if it has little effect on the scene visually, can have very negative effects on performance.

p.s - Darkmod engine does prefer small non overlapping and non shadow casting lights so in a sense it can almost replicate a deferred rendering engine, the later strength being its capability of rendering a large number of small non shadow casting lights, so the popular small points of lights jumping around demos.

Edited by HMart
Link to comment
Share on other sites

That's why I was experimenting with putting the ceiling display on its own spectrum (the theory being that while the light volumes are still touching objects with materials in the normal spectrum, they at least won't be interacting with their materials). Performance on my fairly modest machine seems reasonable.

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

That's right, lights using a specific spectrum will generate zero draw calls for any surfaces that they hit that don't use that spectrum. (I just checked in interaction.cpp to be sure). They don't have to be filtered off during the drawing phase: those mismatched light/surface combinations simply don't get added to the draw list for the frame in the first place.

  • Like 1
Link to comment
Share on other sites

I tried #3 -- secret graffiti lit only by moonlight etc -- but it looks like spectrum 2 lights cast shadows only from spectrum 2 surfaces. Which makes the feature much less usable, at least for this purpose :( We would want the glyph to be shadowed by all objects from all lights, so that moving a box to let the moonlight through could reveal a glyph that was invisible by candlelight or the player's lantern.

Link to comment
Share on other sites

The shadows on my library ceiling are actually cast by ordinary shadow2 cones (not by the visible spikes, which are too short for it; that room is complete smoke and mirrors). However, the cones cease to cast the shadows if I convert them to func_static.

 

I haven't managed to replicate the effect in my test map, though. :unsure:

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

  • 2 years later...

Well, i liked the signs/symbols in Thief Deadly Shadows, but, i wouldn't call that graffiti. Not everything modern fits in a Steampunk setting. At least i would find it a bit weird, especially when you put it in the quarters where rather the poor folks live. Graffiti is rather something i'd expect in more modern times, where people have "too much time at hand", which is not the case in this setting, as, especially the more poor folks have to do a lot to make a living. So, for me it would be - religious, occult, or other signs - yeah- Graffiti - weird - no.

 

As TDM already has symbols, and text on the walls in many missions anyway, i'd generally say no to this proposition.

Edited by chakkman
Link to comment
Share on other sites

There has always been graffiti throughout human history, it has been around since Pompeii, if not before that. I definitely think we need more options when it comes to decorating the greasy alleyways of Bridgeport, and these assets are nice. These should definitely be added to the core mod. If you don't want to use them, then don't, but I personally have a ton of ideas on how to use these, and the more options that are available to mappers, the better.

Link to comment
Share on other sites

Sure, up to the mapper. I think a big point of why the atmosphere is coming across so well is the design of the houses and city though. I haven't really seen much graffiti in a middle age context either. I guess it depends what you'd call "graffiti" though. Let's just say i wouldn't add it, if i was doing a map. I think the houses and city in TDM looks just fine, like in the original Thiefs.

Edited by chakkman
Link to comment
Share on other sites

These hobo symbols would look quite obscure to players, I guess. I don't think having all of them would be useful, making them on "per map" basis should do. Same goes for text, otherwise you might end up with situation a la Dishonored, the same "Blood from the eyes!" decals everywhere.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
    • OrbWeaver

      I like the new frob highlight but it would nice if it was less "flickery" while moving over objects (especially barred metal doors).
      · 4 replies
    • nbohr1more

      Please vote in the 15th Anniversary Contest Theme Poll
       
      · 0 replies
    • Ansome

      Well then, it's been about a week since I released my first FM and I must say that I was very pleasantly surprised by its reception. I had expected half as much interest in my short little FM as I received and even less when it came to positive feedback, but I am glad that the aspects of my mission that I put the most heart into were often the most appreciated. It was also delightful to read plenty of honest criticism and helpful feedback, as I've already been given plenty of useful pointers on improving my brushwork, level design, and gameplay difficulty.
      I've gotten back into the groove of chipping away at my reading and game list, as well as the endless FM catalogue here, but I may very well try my hand at the 15th anniversary contest should it materialize. That is assuming my eyes are ready for a few more months of Dark Radiant's bright interface while burning the midnight oil, of course!
      · 4 replies
×
×
  • Create New...