Game Development Community

Yet more custom light maps for DTS files (now with TGE support)

by Adrian W · 01/03/2009 (12:12 pm) · 28 comments

First things first: Best Wishes to everyone for 2009!

I managed to get quite a bit done on the DTS merger (see Custom light maps for DTS files and More custom light maps for DTS files) over the Xmas break, so if all goes to plan this will be packaged up with some documentation and made available as a resource in the next few days. The main changes since I last posted are:

Standard TGEA materials are now supported. This means it no longer relies on a custom shader to work, which should hopefully make it a lot more user friendly. Custom materials and custom shaders are still supported as well.

TGE is now supported (it turned out that the engine already supports multiple UV channels in TSMesh, even though the DTS format doesn't use it).

There is now a GUI front end, again should make it a lot easier to use.

Anyway a picture is worth a thousand words so here here are plenty of screen shots (very image intensive):

This is the original courtyard model textured and lit in Max:

www.futurenation.net/glbase/images/courtyard_render.jpg
This is the model exported as DTS with diffuse textures, in ShowPro:

www.futurenation.net/glbase/images/courtyard_diff.jpg
This is the model exported again as DTS, with lightmap texture, completely different UV channel to the first export, in ShowPro:

www.futurenation.net/glbase/images/courtyard_lm.jpg
Then run the two models through the DTS merger:

www.futurenation.net/glbase/images/courtyard_merge.jpg
And load into a TGEA mission:

www.futurenation.net/glbase/images/courtyard_tgea.jpg
or a TGE mission (note that Kork is very tactfully not standing on the model in this shot as it doesn't have a collision hull yet and polysoup collision isn't supported in stock TGE):

www.futurenation.net/glbase/images/courtyard_tge_ogl.jpg
and finally, for TGEA only, edit the material script and put some bump maps and specular power on everything:

www.futurenation.net/glbase/images/courtyard_tgea_bmp.jpg
Many thanks to everyone who has given feedback on this or helped out with some testing.
Page «Previous 1 2
#1
01/03/2009 (12:30 pm)
Awesome stuff man.
#2
01/03/2009 (12:51 pm)
Very nice.
#3
01/03/2009 (1:33 pm)
DTS merge? is this program available to us?
#4
01/03/2009 (1:46 pm)
Cool. I always wanted to try out this idea, but never got round to doing the work. Might make some really nicely lit visuals possible now.
#5
01/03/2009 (3:30 pm)
This is very cool. Adrian, have you tested this procress with an interior space? I'd be curious to see what an interior DTS looks like with your custom lightmaps. If we add polysoup for collison and then use dynamic lights for interior lighting could this be a replacement for using portalized DIFs?
#6
01/03/2009 (4:19 pm)
Very nice, Adrian. Lighting is everything in my book and this simply rocks.
#7
01/03/2009 (4:39 pm)
I'd be curious to see what an interior DTS looks like...

Heres a shot of an interior model I've been working on

www.futurenation.net/glbase/images/corridor.jpg
But I think that with a large interior you'd still want to use portals to cut down the overdraw. What I found is that you can create a DIF with NULL textures that doesn't render at all, but it still portalizes the space into zones. Then you can drop TSStatics into the zones in the mission editor and they only render when a portal into their zone or zones is visible.

I'm hoping that with some helper MaxScripts this might lead to a workflow something like the one described in this article here www.gamasutra.com/view/feature/3870/an_environmental_pipeline_in_.php
www.lancet...
, but its early days yet.
#8
01/03/2009 (6:51 pm)
Well, keep rolling Adrian. If you can pull something like that off you'll be the hero of us all!
#9
01/03/2009 (7:19 pm)
see this is what we need to see more of. I gotta pick up a DTS editor.. now about this DTS Merge program... can you direct us to that?
#10
01/03/2009 (9:30 pm)
the DTS merge is the program that he is working on he says it will be a resource soon.
#11
01/03/2009 (11:46 pm)
Awesome! Man if I'd had this a year ago, the time I could have saved. I'd always wondered about the multiple UV channels in a dts file before.

This will be a very very welcome resource to artist around here.
#12
01/04/2009 (2:24 am)
This is great news Adrian, it will truly speed up things when it's released!

;-)
#13
01/04/2009 (9:31 am)
So would it be possible to activate/de-activate in runtime function? I ask because it would be nice to it would be nice to be able to have a choice of using this or ssao depending on performance of the system.
#14
01/04/2009 (11:19 am)
Yep, it can be toggled at run time in TGEA :

setUseAtsLightmaps(1 or 0);
reloadMaterials();
#15
01/05/2009 (2:13 pm)
Looking good. I'm working on something similar, but with a custom interior type rather than DTS.

(edit-nevermind, I figured it out)
#16
01/05/2009 (3:40 pm)
Cool, good luck with your project.
#17
01/06/2009 (10:07 am)
I'm interested in the mention of the engine supporting multiple UV textures already... is there any potential use for that outside shaders?
#18
01/06/2009 (12:00 pm)
"I'm interested in the mention of the engine supporting multiple UV textures already... is there any potential use for that outside shaders?"

The main advantage of having support for multiple UV maps is that it would allow you to use multiple texture channels using different sized textures.

imagine UV channel 1 being a 64 by 64 tiling texture and UV channel 2 being a detailed 512x512 UVmapped light map or even detail/grunge/whatever map.

You could do a building with a tiling concrete texture, a UV mapped high detail spraypaint grafitti texture, a UV mapped lightmap whatever. Each one optimized for maximum coverage and file size.

I'm not sure if this is what Adrian has implemented completely, but thats the potential of multiple UV channels. It allows you to change the way each texture is mapped to the object based on which UVset you use.

Hope that helps explain it. The potential is pretty broad depending upon how it gets implemented.
#19
01/06/2009 (5:56 pm)
Daniel,

As far as I know everything that gets displayed on the screen by TGEA is rendered by a shader, its just that its hidden from you in a nice way by the engine, which generates the shaders on the fly (so called procedural shaders) when it loads the materials.

If you mean are there other applications other than lighting and shadowing, then like William says, yes there is lots of other stuff you can do, but then you get into the area of writing your own shaders so you need to know HLSL, and how to set up custom materials.

I've tried to do the engine changes so that lightmapping is supported automatically using the procedural shaders, but also custom materials are supported for doing anything you can think of using an extra UV channel for. Thats the plan anyway!
#20
01/08/2009 (6:16 pm)
DTS Merger is now available for download along with mods for TGEA. I'll start a new blog when mods for TGE are up as well but for now here's a heads up:

www.futurenation.net/dtsMerger/tiki-list_file_gallery.php?galleryId=5

www.futurenation.net/dtsMerger/tiki-list_file_gallery.php?galleryId=4

rars have recovery records so use tools/repair archive if necessary
Page «Previous 1 2