Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2

Author Topic: Transparent Sky: Update to the rendering engine  (Read 3877 times)

Jeoshua

  • Bay Watcher
  • God help me, I think I may be addicted to modding.
    • View Profile
Transparent Sky: Update to the rendering engine
« on: April 30, 2012, 09:31:18 am »

This game is ASCII, right?  But it uses OpenGL to render that.  So instead of just having the standard CGA colors, it actually has 16.7 million colors (256 red x 256 green x 256 blue).

What if instead of showing an "open tile" when the space per Z-level is empty, one were to show a darker version of what is one z-level below.  And if the tile below that is empty, show what's below that a little darker still, so on and so forth until the color would be fully washed out to the target color and it would just show a solid color.

Here's a mockup of what that might look like, using the current cyan "open space" color as an additive:

Zoomed out, with the lower levels faded, you can see here that it's really not too much information for a player to handle.  That there is representative of 10 Z-levels of what, formerly, was sky.

Each level is clearly defined, and you can even see the curve of the slope as it falls into the (now frozen) lake.

I really think this would be:
1) Fairly simple to do with the current engine
2) Totally within the ASCII style of the original game
3) A great use of the OpenGL rendering engine
4) Incredibly worthwhile.

Rendering this would not hurt the frame rate, either.  Basically nobody ever has any problem rendering the game due to it's Graphical FPS.  All current frame rate bottlenecks are entirely calculations based, and this rendering technique would add very few new calculations.  It would just read more squares per frame.

===

This suggestion has been brought up several times before:
http://www.bay12forums.com/smf/index.php?topic=41266.0
https://www.youtube.com/watch?v=rVhsIGGg3QE
http://www.bay12forums.com/smf/index.php?topic=30114.0
http://www.bay12forums.com/smf/index.php?topic=1788.msg27962#msg27962

And is on the Eternal Suggestions list at a far lower priority than it probably ought to be, given how relatively simple the suggestion would be to complete vs how focused the suggestion is and how long it's been desired:
http://www.bay12games.com/forum/eternal_voting.php

My further suggestion is to deffinitely use the color of the Open Space tile for the fading, as that will allow both above ground "fog" and below ground "gloom" within the same system.  A user could change the behavior simply by changing the color of the Open Space/Chasm tiles in d_init.txt.
« Last Edit: May 01, 2012, 03:57:08 pm by Jeoshua »
Logged
I like fortresses because they are still underground.

slothen

  • Bay Watcher
    • View Profile
Re: Some minor (and very easy) tweaks to the rendering engine
« Reply #1 on: April 30, 2012, 09:39:33 am »

do want
Logged
While adding magma to anything will make it dwarfy, adding the word "magma" to your post does not necessarily make it funny.
Thoughts on water
MILITARY: squad, uniform, training
"DF doesn't mold players into its image - DF merely selects those who were always ready for DF." -NW_Kohaku

Jeoshua

  • Bay Watcher
  • God help me, I think I may be addicted to modding.
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #2 on: April 30, 2012, 10:14:47 am »

It has come to my attention that the Linux engine hack "[PRINT_MODE:SHADER]" actually already does this, further proving the fact that this is very possible, and if it can be done in a hack, actually relatively simple to do and requiring almost no changes to the basic game engine at all.
« Last Edit: April 30, 2012, 10:16:47 am by Jeoshua »
Logged
I like fortresses because they are still underground.

Starver

  • Bay Watcher
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #3 on: April 30, 2012, 10:41:33 am »

This is such a good idea that... yes, it's been mentioned before[1].

(InB4 Footkerchief? ;) Well, I'll let him do the links.)




[1] Not that "It's been mentioned before" means "It's a good idea", but in this case I think it happens to correlate.
Logged

Escapism

  • Bay Watcher
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #4 on: April 30, 2012, 11:22:34 am »

Marvelous. Makes following units that run over hills less painful.
« Last Edit: April 30, 2012, 12:16:47 pm by Escapism »
Logged

Jeoshua

  • Bay Watcher
  • God help me, I think I may be addicted to modding.
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #5 on: April 30, 2012, 11:38:15 am »

I believe I've mentioned it before, actually.

It's just I didn't have a mockup to show people what I meant before.
Logged
I like fortresses because they are still underground.

Rtyh-C

  • Bay Watcher
  • Slaughtering elves in low Earth orbit
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #6 on: April 30, 2012, 12:11:20 pm »

Yes, I've seen it before (with a mockup as well, actually).

Just goes to show that we really want it, right?

Quote
It has come to my attention that the Linux engine hack "[PRINT_MODE:SHADER]" actually already does this

??? Please clarify?
Logged
By that logic, you shouldn't be able to play dwarves because they don't show thinking ability.

Brotato

  • Bay Watcher
  • Beware the Destroyer of Threads!
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #7 on: April 30, 2012, 12:45:39 pm »

This is beautiful! Easily allowing me to follow the progress of migrants, soldiers, and enemies without the normal confusion included.
Logged
Dwarf Fortress: The only game where people will hold a logical discussion about why dwarves are putting on clothes.
OK, I have to reload the save.
There was a bit of a problem regarding flashfreezing, a ballistae, and a barrel of dwarven ale. Gonna fix it up.

JanusTwoface

  • Bay Watcher
  • murbleblarg
    • View Profile
    • jverkamp.com
Re: Transparent Sky: Update to the rendering engine
« Reply #8 on: April 30, 2012, 12:58:09 pm »

Mike Mayday has a nice thread back on 1 September 2009 with a similar picture.

Then there was this YouTube video of a concept that included that and automatically scrolling between levels.

Also, I'm pretty sure that Stonesense can do a thing like that so far as third party viewers go, although I can't find an image at the moment.

So yeah, it's been suggested before. But personally, I think this is one of the few things I don't mind seeing brought up again and again. :)
Logged
You may think I'm crazy / And I think you may be right
But life is ever so much more fun / If you are the crazy one

My blog: Photography, Programming, Writing
Novels: A Sea of Stars, Confession

Jeoshua

  • Bay Watcher
  • God help me, I think I may be addicted to modding.
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #9 on: April 30, 2012, 03:13:08 pm »

Thing is me, clunky slow human that I am, was able to do this in 1 minute with Photoshop and some screenshots.  If I can do it in a minute, you know that a computer that's told the technique to do it could do it about 500 times a second.

The thing is that there are no extra calculations that need to be done.  All the Z-levels are already loaded into memory.  All animals and plants and whatnot on them are already being updated once per frame.  Everything is already there and in place, all data exists, and everything is right there.  All it takes is a routine that says, instead of "is this tile empty? Display empty tile" and change it to "is this tile empty? what about below that? and below that? Fade it and display the bottom tile."

So you'd see a lowering of maximum graphical FPS... but if you ever uncapped that in the init.txt file you'd notice that you're pulling in about 200 graphical frames per second anyways.  Nobody needs more than 60, ever, so there is a lot of wiggle room there.  Implementing something like this would not affect anyone's frame rate in the slightest.

Quote
please clarify?
Go over to the mod forums and look for [PRINT_MODE:SHADER].  They implemented something much like this as an external engine hack.  It only runs on linux, unfortunately, and is not updated for the current version of DF.
Logged
I like fortresses because they are still underground.

Silverionmox

  • Bay Watcher
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #10 on: April 30, 2012, 04:40:37 pm »

Depth by darkening, in the Eternal Suggestions list as "Depth by darkening / misting / blurring", currently at 45 votes.
Logged
Dwarf Fortress cured my savescumming.

JanusTwoface

  • Bay Watcher
  • murbleblarg
    • View Profile
    • jverkamp.com
Re: Transparent Sky: Update to the rendering engine
« Reply #11 on: April 30, 2012, 04:47:51 pm »

Wow. If you go from there, you have links back even further to a 19 August 2007 post by Toady One seeing if he could "try the gradated skies out" and a mock up from a few days later. So it's been thought of for at least 5 years, now the real question is why hasn't it been done?
Logged
You may think I'm crazy / And I think you may be right
But life is ever so much more fun / If you are the crazy one

My blog: Photography, Programming, Writing
Novels: A Sea of Stars, Confession

Jeoshua

  • Bay Watcher
  • God help me, I think I may be addicted to modding.
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #12 on: April 30, 2012, 05:18:58 pm »

Good God.

I've gone past thinking this is a good idea, now, to believing it's something that is ABSOLUTELY needed.

We have new cities that can appear on terrain that is completely not able to be visualized without some way to see multiple Z-levels at once.

We have rivers that one cannot tell if they can swim through in Adventurer mode without being able to see multiple Z-levels at once.

It's been suggested and even considered by Toady for 5 years, reliably proven now.

It's been DONE on Linux, without modifying the original game engine and only changing out the renderer.

Not "Do Want"

"Must Have"
Logged
I like fortresses because they are still underground.

Footkerchief

  • Bay Watcher
  • The Juffo-Wup is strong in this place.
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #13 on: May 01, 2012, 01:29:01 pm »

Depth by darkening, in the Eternal Suggestions list as "Depth by darkening / misting / blurring", currently at 45 votes.

Yep.  Please vote for it if you like this idea!
Logged

Jeoshua

  • Bay Watcher
  • God help me, I think I may be addicted to modding.
    • View Profile
Re: Transparent Sky: Update to the rendering engine
« Reply #14 on: May 01, 2012, 03:40:10 pm »

I hope sincerely that anyone looking at this follows some of the links, sees the possibilities (especially mine and that BRILLIANT Youtube video), and votes/changes votes on the Eternal Suggestions.  Seeing is believing, and after seeing it in action in the video, seeing screenshots of [PRINT_MODE:SHADER], and thinking about the actual difficulty of this, I hope more people realize just how much this is needed.

My biggest issue with the Eternal Suggestions list is thus:

Large, sweeping improvement suggestions, such as "Full Graphics Support" (No qualifiers, just... "Full") or "Improved Hauling" (Minecarts, Crates, etc etc ad nauseum) are obviously going to get more votes than other, more focused suggestions because they cover more ground and therefore more people will find something within their scope to vote on.

On the other hand, small, focused, easilly implemented suggestions are much further down the list because for example "Make Minecarts" will appeal to fewer people than "Improve the Whole Hauling System with all kinds of different stuff"

As another more specific example, "Depth by Fog" could be considered to be a "Graphics Support" improvement, so many people will vote for just plain "Better Graphics" than a specific suggestion of what would be better, ala "Depth By Fog" or "Item Graphics Icons"
« Last Edit: May 01, 2012, 04:06:19 pm by Jeoshua »
Logged
I like fortresses because they are still underground.
Pages: [1] 2