Page 4 of 6
Re: Render to Framebuffer
Posted: Mon Aug 08, 2022 8:52 pm
by Griff
Ha that's awesome!
Just needs "Incoming missile" written in the style of those silent movie caption cards and we could claim Oolite came out before the BBC micro original
Re: Render to Framebuffer
Posted: Tue Aug 09, 2022 10:59 am
by cbr
another_commander wrote: ↑Mon Aug 08, 2022 9:24 am
OK, now I am just fooling around with it, but this is awesome! It's crazy what this post-processing stuff can generate. Here is Oolite in old style silent film format:
Is there also an underwater mode?
Re: Render to Framebuffer
Posted: Tue Aug 09, 2022 12:25 pm
by another_commander
Not ready to call this a feature yet - it is still a bit buggy and very intense, affects the gui too and reminds me of the first 3D Prince of Persia game which was completely flooded by it. I think it may require bringing our shaders up to modern glsl grammar standards to get it fully under control, but hey, it's a start. It's blooming!
Re: Render to Framebuffer
Posted: Tue Aug 09, 2022 4:31 pm
by another_commander
cbr wrote: ↑Tue Aug 09, 2022 10:59 am
Is there also an underwater mode?
Yessir!
Re: Render to Framebuffer
Posted: Tue Aug 09, 2022 8:13 pm
by Cody
Voyage to the Bottom of the Sea [ping] starring Richard Basehart [ping]
Re: Render to Framebuffer
Posted: Wed Aug 10, 2022 8:20 pm
by cbr
wow...
That would make (for) an interesting planet...
Are the effects only applicable to the entire view screen or also on individual objects?
Re: Render to Framebuffer
Posted: Wed Aug 10, 2022 8:26 pm
by another_commander
Entire screen.
Re: Render to Framebuffer
Posted: Wed Aug 10, 2022 8:31 pm
by Slartibartfast
Hello
I don't think this is "water"
probably "spacetime distortions"
cheers
Re: Render to Framebuffer
Posted: Sat Aug 13, 2022 10:31 pm
by another_commander
Milestone achieved ladies and gents. Bloom is in!
I finally managed to get it to apply gently and subtly in the scene and is noticeable only when it is needed. It still affects the HUD (slightly), but that's something to worry about later. In the animations below you can see it in action. The video start with a pan of the camera to the left, where everything is set like up till now. Then the camera stops, bloom is activated and it pans back to the right. Notice the difference in specular reflections this time round?
For those who want to test it, I have uploaded a test package
here. It contains:
- The changed source files.
- The latest version of the shaders reauired to run it.
- A patch file done against the latest trunk.
- Updated keyconfig2.plsit which contains the setting for the F9 key.
- A Windows test executable. You can use F9 to toggle bloom on and off. Note that, due to the complexity of calculations involved, bloom is an expensive operation. On one of my test systems, CPU usage goes from 50 to 88 percent when I activate it, but thankfully without change in fps or in GPU temperature. On the other, which is low-end, I see around 40% fps drop at the Extras detail level when I activate it.
And a few screenies showing a random scene without and with bloom. Notice the intensified glow at the parts of the ship reflecting light the most.
Re: Render to Framebuffer
Posted: Sun Aug 14, 2022 8:14 pm
by another_commander
An improved version of the bloom implementation has been uploaded
here for anyone interested. It contains today's revisions of the files that were uploaded yesterday and, of course, a new Windows exe for those who would like to see it.
Re: Render to Framebuffer
Posted: Wed Aug 17, 2022 8:47 am
by another_commander
I have uploaded a new test executable and shaders
here for those who have already downloaded the previous message's package and are willing to follow the development of the feature as it moves ahead. Unzip the files to their corresponding locations, overwriting the previous ones.
In this episode:
- The cloaking device has now been assigned a post processing effect all of its own. The effect is based on the night vision one, but renders in blue instead of green (remember, the codename of the cloaking device is "Blue Alert"). To test, just go out in space and activate / de-activate it normally.
- Activation of post processing effects is now possible from scripts. In this first iteration, you can use the read/write JSGlobal object postFX to query and set the currently active effect. When setting an effect, you must assign postFX an integer value corresponding to the desired effect. Cuurently there are 5 available:
1. Cloak vision
2. Colorblindness correction (Protanopia)
3. Colorblindness correction (Deuteranopia)
4. Colorblindness correction (Tritanopia)
5. Grayscale
To set grayscale, for example, use postFX = 5
. For cloak vision use 1 etc. Executing postFX = 0
will reset to normal rendering sans fx. Values out of range will reset to no fx too.
- The default bloom has been raised just a tad.
- Fixed a bug that would cause screen corruption when setting detail level below "Shaders Enabled".
Re: Render to Framebuffer
Posted: Fri Aug 19, 2022 3:49 pm
by another_commander
We are almost ready to make this official. Pull request is up on github:
https://github.com/OoliteProject/oolite/pull/407
Before the final merge, please test and ensure that the code in the above PR works and runs OK for you. This is basically for Lunux (and maybe Mac? anyone?) users, as testing on Windows seems to have produced no blockers. We'll let quite a few days for testing and if there are issues we'll hold the merge until resolved.
I should also note that, as far as Windows is concerned, the feature will be implemented only for 64-bit versions of the OS. I think it is time we retire the (obsolete, really) 32-bit version, which is not scheduled to receive any new features from now on, unless someone interested in maintaining it steps in.
I once again want to express my sincere thanks to both Mauiby de Fug, who made the first attempt at this and kept the flame burning, and tsoj, who bit the bullet and actually made the darn thing work. Evrything I added after that was just fluff, really
. So, thank you guys, this is something I wanted to see for a long, long time!
Re: Render to Framebuffer
Posted: Fri Aug 19, 2022 3:51 pm
by Cholmondely
another_commander wrote: ↑Fri Aug 19, 2022 3:49 pm
We are almost ready to make this official. Pull request is up on github:
https://github.com/OoliteProject/oolite/pull/407
Before the final merge, please test and ensure that the code in the above PR works and runs OK for you. This is basically for Lunux (and maybe Mac? anyone?) users, as testing on Windows seems to have produced no blockers. We'll let quite a few days for testing and if there are issues we'll hold the merge until resolved.
I should also note that, as far as Windows is concerned, the feature will be implemented only for 64-bit versions of the OS. I think it is time we retire the (obsolete, really) 32-bit version, which is not scheduled to receive any new features from now on, unless someone interested in maintaining it steps in.
I once again want to express my sincere thanks to both Mauiby de Fug, who made the first attempt at this and kept the flame burning, and tsoj, who bit the bullet and actually made the darn thing work. Evrything I added after that was just fluff, really
. So, thank you guys, this is something I wanted to see for a long, long time!
I'd love to try it out. But how? I can't compile for toffee - I need an Apple version which I can just download...
Re: Render to Framebuffer
Posted: Fri Aug 19, 2022 3:52 pm
by another_commander
Cholmondely wrote: ↑Fri Aug 19, 2022 3:51 pm
I'd love to try it out. But how? I can't compile for toffee - I need an Apple version which I can just download...
Yeah, believe me I know... but that's exactly the problem...
Re: Render to Framebuffer
Posted: Fri Aug 19, 2022 5:51 pm
by Cholmondely
another_commander wrote: ↑Fri Aug 19, 2022 3:52 pm
Cholmondely wrote: ↑Fri Aug 19, 2022 3:51 pm
I'd love to try it out. But how? I can't compile for toffee - I need an Apple version which I can just download...
Yeah, believe me I know... but that's exactly the problem...
Is there any way in which I could take over Getafix's transmogrification duties? What would I need? And how much would I need to know?