FOnline Development > 3D Development

Shaders and effects

<< < (3/16) > >>

Johnnybravo:
Try to add  'CalculateTangentSpace' in your fo3d along with using normal map effect.
Here's example in documentation

--- Code: ---Model    Box.3ds
CalculateTangentSpace
Subset 0 Texture 0 DED.tga
Subset 0 Texture 1 DEN.tga
Subset 1 Texture 0 DrD.tga
Subset 1 Texture 1 DIntrN.tga
Subset -1 Effect 3D_NormalMapping.fx

--- End code ---
I did not check what format is normal map in, but expect it to be quite the same as in every other game.
Just find some random normal map on internet and slap it on box model, or any other surface where it would be apparent.
EDIT: and no sorry haven't tried it yet.

Karpov:
Here is a demo video for those who haven't seen this in action yet.

http://www.youtube.com/watch?v=_vCQhklJpvE

I've been tinkering with ambient color and light direction. I got some nice outdoor/sunlight shading. It needs to be set in every model you want it to appear, but if somehow it could be set globally, it could be a great feature, like different light setups during the day. Anyway, shaders are very good, thumbs up to the author.

Luther Blissett:
Johnnybravo - I will have a look at this, see if I can get something to work
Karpov - Very good - much clearer example with a video than screenshots. Regarding global effects, there must be some sort of default effect applied to the models, as they had a basic light and shadow working to begin with - I wonder if this could be replaced, or if you can find the file that "points to" the default shader, to "point it" to the path of the new one instead? Also agreed, thumbs up for this work - very important step forward.

Johnnybravo:
API supports it, so that it shouldn't be problem to propagate some functions to script so that modders can play with it.
Unfortunately as far as I understand community behind engine is the russian part related to TLA server.
Might be a little harder to make related requests.

But it could be nice if script could chose techniques (I might want to have something else than a model + shadow, like ghost effect or lower detailed lighting to make game faster on ancient hardware (like stuff as old as GeForce 3/4 might have hard time calculating it all, anything older does not even have shaders to begin with :d)) and propagate variables.
There might be some more interesting things like lights (dunno how D3D deals with it, but GL has related structures available without need to propagate anything).

As the matter of fact it'd be probably the best to set light 0 structure for global illumination (sun and stuff - directional lighting that is already there) and have other lights used for dynamic (point) lighting.

However scripters should always be aware that scenery WILL be 2D, so changing global light direction will be highly contraproductive.

EDIT: Thanks for the vid Karpov, really nice showcase, it makes MA appear much better than even I expected.

Karpov:
You are right, the scenery and buildings would not change , it would look weird. Anyway, your shader seems to improve a lot the looks of non shiny surfaces too.
I changed the standard shader as suggested by Luther, so now all models use this one. Take a look.



In my opinion , the new one looks much better. What do you guys think?
Also the skin is mapped, just a bit of shine over the body, and some more on the head.

As for the global illumination, I used ambient color with a blueish tint. Of course, it's not the same as an additional light, but it softens the dark shadows.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version