Animated textures discussion

Ask questions, discuss ideas, get answers
User avatar
Apache Thunder
Posts: 1213
Joined: Mon Oct 19, 2009 2:48 am
Location: Levelland Texas, USA
Contact:

Re: Animated textures discussion

Post by Apache Thunder »

I tested the settings recently on the river mesh and didn't notice much of a difference in terms of how it blended with the fog, so it seems that issue will still be present if the blend mode method of alpha is used.

As for the max scene, I did spend last night bringing it up to spec in regards to how my night maps are now done. It does not have any m2 meshes. I coded things into the map that removes any m2 meshes used in the map. (basically used active command to remove/disable the lod objects used on some of the buildings)


But it does have all the statics lightmapped. Even some that aren't lightmapped in vanilla BF1942. Some objects like the rope spindle thing-a-ma-jig didn't originally have a lightmap channel or corresponding samples file. This also includes those little concrete pillar things strewn about the map. I added the modified meshes with proper lightmap UVs to the map and modified the object coding to use the custom geometries. (you can't override an existing geometry template map side it seems, so all the objects I modified used new geometry templates)

I even lightmapped the med-lockers and ammo boxes which also don't get lightmapped normally. ;)

The only thing still off about the max scene is most of the interior lights are copies and not instances. Non of the statics have textures either as I removed them back when I still used the "CompleteMap" setting for the lightmap files. This was before I used skylights in my scenes and back then I didn't know why unlit surfaces were too dark. So I made a work around by modifying the rexman scripts to set up the objects with the CompleteMap element type instead and removed the textures to prevent them from being present in the resulting lightmap files. Adding the skylight and switching the statics to the LightingMap element type as well as using higher resolution output settings (since I plan to render them out as DDS files) was one of the things I spent last night adding to the old max scene. Oh and the max scene has since been saved as a new file and will require Max 10 or newer to open since I use Max 10 for lightmapping.

About the only statics that may suffer from this are a few buildings that used alpha in the balcony fence thing and a few fence gates used on the edges of the map. But since I used the original map's terrain textures, the shadows were already baked in and those particular objects did not really effect nearby objects in terms of where their shadows were, so I did not make any attempt to fix them. :P
ImageImageImage
I have cameras in your head!
User avatar
fo0k
Posts: 1434
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: Animated textures discussion

Post by fo0k »

good pointers thanks :)

quick vid of a bit of lightning!

http://youtu.be/C84QSVEdj5I
User avatar
fo0k
Posts: 1434
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: Animated textures discussion

Post by fo0k »

soo.. apparently biks do sync.. when they feel like it :(

Very curious. Used the same bik as this building for detail map as a sync test.. perfect sync.

Created a copy of the same bik.. renamed and used as detail.. Not only does it not sync but it plays faster! like a a constant 10% increase in frame rate of the detail bik even though a direct copy.

but fine if both pulling the same tex!

I thought maybe just some precaching would have fixed it to sync at start but this speed difference basically blows that out of the water :(


I guess the only way to have some lightning on sky, objects and detail.. all synced.. is to use one bik for all!

now, this could be done.. possible to uvmap things like skybox and buildings but the detail map uses the entire texture.. unless theres some way to get around that? :/

edit.. I guess remove terrain altogether and have it as static mesh. actually.. yeah that would do it.. no great loss of dynamic shadows in a map like this anyway.
but does mean the entire buildings etc will lightup.. inside and out :/

or create a monster 2048x2048 bik and allocate 64x64 pixels per building as a lightmap! giving space for 1000 objects... lols :)


edit:edit.. actually a 64x64 lightmap for this purpose looks surprisingly good!
lowreslightning.gif
lowreslightning.gif (7.36 MiB) Viewed 21768 times
User avatar
fo0k
Posts: 1434
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: Animated textures discussion

Post by fo0k »

possible to give skybox a lightmap?
User avatar
Apache Thunder
Posts: 1213
Joined: Mon Oct 19, 2009 2:48 am
Location: Levelland Texas, USA
Contact:

Re: Animated textures discussion

Post by Apache Thunder »

Probably not, but you wouldn't need too. A vanilla skybox easily be re-uvmapped to use a lightmap channel on channel 1 without much loss in quality. Skydomes however tend to already use a single texture. ;)

Skyboxes have RS files like normal meshes.


Also, I wonder what happens if you load a BIK texture via the WaterShader.rs file?

EDIT: Yep you can. I used the BIK used on the creek and it seems to work. It will animate as well. (it tiles the texture in the same manner normally done in the Init.con water coding) ;)
ImageImageImage
I have cameras in your head!
User avatar
fo0k
Posts: 1434
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: Animated textures discussion

Post by fo0k »

heheh thats cool.. will try water.

With skybox what I'm getting at is that for this lightning to work.. in sync. then the mesh's (including the ground which will need to be a mesh) and the sky need to run from the same bik file.

Berlin has 430 (ish) objects total.
2048 x 2048 bik has space for 1000 64x64 lightmaps (so every object..) and that then leaves a 2048x1024 space on the bik lightmap for ground and skybox. should be enough but the ground could be hungry for size
and would have been nicer to have high res skybox images with a lightmap to do the flashes.

The big issue is with the main building textures which need to be 2048x2048 minimum full uvmapped to retain comparable quality to the original mapping using many textures.. this appears to be pushing the map size to easily 500mb :/
soo... Im thinking I can light all objects from above (a cloudy skylight) and then use the same texture on duplicate buildings... but light the texture as such for detail.. then the lightmap will just handle the lightning shadows..

ultimately though, I think this can all work on one lightmap (it's gonna be one hell of a lightmap!)

I tested a 2048x2048 bik and it was smooth as.


edit: can the player models/weapons have lightmaps?
User avatar
Swaffy
Posts: 1715
Joined: Sun Aug 29, 2010 9:25 pm
Location: Cibolo, Texas

Re: Animated textures discussion

Post by Swaffy »

So, you're saying ... we can have lightning in the skybox to go with da thundaarrrr?

You should have a seizure house that has this kind of animated texture in it:
(Forum Thread|Download) Swaffy'sMod v0.34 | Download link to come Soon™
User avatar
fo0k
Posts: 1434
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: Animated textures discussion

Post by fo0k »

Swaffy wrote:You should have a seizure house...
heheh, actually that would make an amazing disco for interstate mod.
User avatar
Swaffy
Posts: 1715
Joined: Sun Aug 29, 2010 9:25 pm
Location: Cibolo, Texas

Re: Animated textures discussion

Post by Swaffy »

Alright. So I want to make a flashy texture (like the beginning of that video) for my Stg44. How can that be done?
(Forum Thread|Download) Swaffy'sMod v0.34 | Download link to come Soon™
User avatar
fo0k
Posts: 1434
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: Animated textures discussion

Post by fo0k »

easy way avoiding complex video editing etc..

1. google 'how to download youtube videos'.. find a website that will automatically do it for you and spit out a download.

2. download radtools http://www.radgametools.com/bnkdown.htm

3. open radtools.. single click the file you downloaded from youtube then click 'Bink it!'

There are many options but basically you should select a 'compress to a % of the original' data rate and make it equate to under 10mb (based on the file size downloaded from youtube.. and for a small object like weapon maybe just a couple of mb will do..)
Adjust the width/height on the far right to 256x256 (ample for a gun.. could probably go 128x128)
If you like, select a frame range - rather than process entire video (grab 500 frames for example)

then hit Bink!

drop the bik file into your 'mods/'modname'/movies folder (cannot be contained in the map rfa)
change the texture/s in your objects rs file to point at the video. e.g.

Code: Select all

	texture "Mods\interstate\movies\myvideoname";
load up game and enjoy.

this will also convert audio (and be heard in game).. but there is an option in the main radtools window to 'Convert a file' where you can elect to remove (not convert) audio from a file... then follow the process above.
Post Reply