Project Declension 2008 (Yes! Crepuscular rays)

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Project Declension 2008 (Yes! Crepuscular rays)

Post by jingquan »

Older Comments:
It has been a great 2 years working on this, which started out as an ambitious aim for a game engine, and now, it's more of a shader/model testing platform where I dump whatever things I learned or made in there. Irrlicht is a great engine, but the main reason I choose it over others is its support for different languages, especially .NET. Keep up the great work!

Current rendering features:

- Lighting
Per-pixel, normalmap, custom rim for ambient, envmap for fake GI
- Postprocess!
All sorts of blur, dof, motion, bloom
Tonemapping
Lens artifacts
Ambient Occlusion
- A few materials which I forgot (probably not working)
- Shadows
Crappy PCF and stencil

Here's a latest screenshot of my cafeteria scene, my very mediocre modelling skills, with only cubic mapping and few textures stolen from elsewhere. It running pretty fast (94fps) at 1024x768 on my ATI3850.

EDIT:

I've released a demo recently for the community to work on the art and improve on anything possible if you feel like it. :D License is...uhh free for the Irrlicht community. Unfortunately the player model and its texture is copyrighted so I don't think you can use them in commercial projects. A few colormaps are remakes/edits from the original, other than that everything is ok to use. There's tons of shaders available too you can check those out as well.

If you'd like to use anything in your projects, a credit as a link to my site I'll be very happy. :D

You can config some basic options in dec.ini (resolution..AA...etc.) I've got more instruction in the text file.

If you'd like, you can improve on the model or textures or shaders of the map to get it to look as real as possible.

Rule of the game: Fill up the cafeteria with cubes to take revenge on the rude janitor. :lol:

Download Link: Link Outdated.

Recently I've stopped working on it for other things, but I'll still be updating the graphics from time to time, with one goal in mind: photo-realism at >60fps. :D

Oh forgotten: My website: http://www.orandysoftware.com/ where I post all my works in there. BTW, anyone interested to link up....for the PR? (if you're marketing fanatic :D )

EDIT2:

Lately I decided to recode my game “engine”, which is more of a graphics/physics sandbox, into a proper expandable game engine with organized classes and files, the way it’s meant to be done. Every map and entity has a property file which assigns the mesh and the material. The map file contains extra attributes such as object position, rotation, lighting…etc. This way, anyone could easily integrate their custom contents in the engine without opening up Visual Studios. In fact this allows integrating with my mapeditor possible and I’ll definitely be making one someday.

I made a few changes to the shaders, improved SSAO, made the game more scalable and removed the cheap lens ghosting filter. There’s a new minigame included too: Clear out every object in the map with your companion psy-cube! I think there’s enought screenshots of my cafeteria so I’ll save it.

Download: http://www.orandysoftware.com/user_file ... ne2008.zip

Controls:

Esc - Quit
F11 - Take Screenshot (saved in Screenshots folder)
wasd - move camera
1 - toggle firstperson view
2 - toggle chase cam (Nausea warning)
Left click - repel psycube
Right click - attract psycube
c - clone it!

You can tweak the game inside DeclensionEngine.ini, the main setting file. For the map, check out those folders that starts with a capital letter. They are the ones containing map/object configure file (a text file), the rest of the folders are game files.

Check it out, runs 200+fps on my HD3850 (default setting and cam view).

EDIT3:

Been testing a few free lightmapping tools but everytime I load my mesh in-game or even in the editor, all the materials screws up. What is wrong with Cinema4D??? Could someone lightmap my mesh please? :( Simply assign the lightmap texture to texture4 for the generic material as it's using the 2nd texcoord of the mesh.

I've got DOF working now and fixed some rtt alignments. You can change the far dist, range, blur offset in the setting file. To load your own map, create a folder and a .dmap file with the same name as your mesh, then head over to EngineSettings.ini and call the meshname and extension. Oh and I'll make DOF optional in the next update.

BTW, does phpbb have a tag that can hide a block of text? This first post is beginning to get lengthy. I've deleted over-sized images to keep this page neat. :D

Download: http://www.orandysoftware.com/user_file ... ne2008.zip

New Controls:

0 - Increase Blur
9 - Decrease Blur
p - Increase DOF
o - Decrease DOF

EDIT4:

I just got this easy to implement but costly technique working last night and can't wait to show everyone! I think what I did is wrong since it should be a radial blur around the light source and not blurring vertically. Anyway, it's indoors and it makes a good volumetric light.

The engine configuration file has been split into two, another is for the postprocessing, for the fans of unblurry images, dof and light scattering is optional. The light shafts are more visible ingame when the camera is moving. Now for the shots:

Image

Image

Download: http://www.orandysoftware.com/user_file ... ne2008.zip
Last edited by jingquan on Wed Jun 11, 2008 1:29 am, edited 17 times in total.
xray
Posts: 231
Joined: Fri Feb 02, 2007 1:06 pm
Location: Germany, Munich
Contact:

Post by xray »

Your screenshots are not bad also the shaders, but your pictures are a little bit blured.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

Wow the screenshots are not bad, I like the website design too, what CMS are you using?

I see that you are interested in Shadow Mapping, it is infact very easy to integrate (Although difficult to calibrate to many different kinds of scenes). Check out my shadow mapping wrapper: http://irrlicht.sourceforge.net/phpBB2/ ... hp?t=23638 , I hope looking at the shaders and Irrlicht implementation will give you some hints. (Although I see that you are using .NETCP so you probably can't slot the wrapper right in (Else it would be too easy :P )

Ok, good luck.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Monochrome
Posts: 122
Joined: Thu Oct 19, 2006 11:43 am

Post by Monochrome »

holy schite, its another bloom shooter project!
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Post by jingquan »

Sourceforge seems to be slower than usual and finally I could login. :?

Thanks for all your comments. I'm sure I'll improve whatever I can.

I've played with your shadowmap a long while ago (the demo) and it's fantastic, but that time, I wasn't quite fully sure how it worked, anyway, I've improved in my shaders coding. :D I'll convert it to C# and use it with my game soon.
what CMS are you using?
I integrated wordpress with my site, so I can easily publish stuff, and edit them, on the go.
its another bloom shooter project!
No, fortunately. :D It's not another shooter. I'm thinking of a unique gameplay where you won't use bullets. The model is just there to show off :wink: , a placeholder actually.

I had some HDR shaders written, bloom filter, downsample, brightpass and tone. Unfortunately, Irrlicht.net cp (and Irrlicht) doesn't supports some high range textures yet, and I'm still trying to render to textures (correctly and efficiently) for postprocess.

Actually, I'll rather use bloom rather than nothing, it softens edges/colors and it looked like antialiasing is right there. A comparison:
Last edited by jingquan on Mon Jun 09, 2008 4:57 am, edited 1 time in total.
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Post by jingquan »

I've got a few questions. Can I use world space lighting and still have some meshes rotate and get correct lighting? Right now, when I rotate my player, the lighting dosen't seem to be correct in some angles.

Also, how can I use multipass for postprocess and multi-light? For more than one light, should I have them written in the shader itself, or use multipass?

Thank you for your time.
TheGameMaker
Posts: 275
Joined: Fri May 12, 2006 6:37 pm
Location: Germany

Post by TheGameMaker »

You should use worldspace lighing just for static objekts.. rotating etc objekts should have objectspace lighting or Tangenspace...
I figured out its protty much possibe to use 4(5 lights per pass. Than you render the scene 2 times, and add the resulting images together -> so you can render 8 lights.. however this will cut your FPs down to an half.. so its probably not the best salution..
you should use a light manager that finds the 4 most importand lights for every objekt (or subobjekt.. thats wehre it gets tricky)
agi_shi
Posts: 122
Joined: Mon Feb 26, 2007 12:46 am

Post by agi_shi »

Sorry, but the second screen-shot (non-bloom) looks TONS better. Also, is all that media from F.E.A.R.? Really resembles it, especially all of the textures.

You can use world-space lighting on everything, it works wonders. And it's quite useful for certain things. Just make sure everything is in world space before you use it. I'm guessing your normals are still in object space. Just transform them by your world matrix (either make the normal a 4D vector or turn the world matrix into a 3x3 rotation matrix). Other than that, you'll need your light position in world space (should already be there) as well as your vertex position (will be in object space).

Other than that, it looks quite nice!
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Post by jingquan »

Ok, I see. I'll try to add more lights and use world space. Just wondering, why does the one without bloom looks better? Is bloom too bright and blur?

Yeah, i got the textures form some fear mod tool, but I made most of the bumpmaps and specmaps. I'll definately be creating my own textures for my game.

Thanks.
agi_shi
Posts: 122
Joined: Mon Feb 26, 2007 12:46 am

Post by agi_shi »

jingquan wrote:Ok, I see. I'll try to add more lights and use world space. Just wondering, why does the one without bloom looks better? Is bloom too bright and blur?
The one without bloom is sharper, clearer... just plainly looks better, in my opinion. I like it with the details nice and sharp. The bloom, on the other hand, blurs it too much. It's almost like a soft "after-life" or something.
Yeah, i got the textures form some fear mod tool, but I made most of the bumpmaps and specmaps. I'll definately be creating my own textures for my game.

Thanks.
I used to work with WorldEdit, I love F.E.A.R. :D. I'll recognize it *anywhere*.

Sorry if I sounded negative or something, your stuff looks great! Quite resembles F.E.A.R.'s quality, good job!
lostclimategames
Posts: 331
Joined: Sat Sep 02, 2006 4:11 am
Location: Michigan
Contact:

Post by lostclimategames »

the issue with your bloom is that your doing it wrong, what you need to do is take all the highlights in your scene, add contrast with the surrounding areas, and then only blur those areas. You dont blur the whole scene tho.

heres the part that should have higher contrast and be blurred:

Image
___________________________
For all of your 3D/2D resource needs:
Image
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Post by jingquan »

Ok, I see. I'll try to get HDR in the engine. But how can I render textures then taking them all for tonemap? I'm guessing it's: first render the downsampler, fliters...into quads where you cannot see, then get each quad's textures for tonemap?

Oh and btw, the lighting are currently all in world space.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

No, you don't need HDR. What you do is, you render the normally, and then you render the scene blurred. Then you combine those two based on a formula of how luminant the pixel is.

Off the top of my head, a half decent formula is:
Color = Unblurred * 0.6 + blurred * (0.5 * luminance).

Luminance is obtained through (0.29 * red + 0.58 * green + 0.11 * blue).
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Post by jingquan »

Alright, got some shader working. Now, I'm not sure how to apply my bloom's texture as the 2nd layer of the luminance material. Any help in C++ would be fine.

Here's my obviously wrong postprocessing code:

Code: Select all

Sloved!
Many Thanks.
jingquan
Posts: 222
Joined: Sun Aug 20, 2006 4:10 am
Contact:

Post by jingquan »

How does this look now, I used this formular:

Code: Select all

lerp( sharp, blur*blur, 0.4f );
Last edited by jingquan on Mon Jun 09, 2008 4:57 am, edited 1 time in total.
Post Reply