Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 1,213 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Mtl_SpecBump: How to make the static shadows darker? #438909
03/23/14 11:43
03/23/14 11:43
Joined: Nov 2005
Posts: 112
M
miez Offline OP
Member
miez  Offline OP
Member
M

Joined: Nov 2005
Posts: 112
I have a small Shaderproblem with the standard mtl_specbump shader. Most of it works as I want it to, but the static shadows are too bright.



My Level has an Ambient of 16 and sun is at 9.
And my lightsource is 255 and with a range 1000.
When I compile the level with the light as static, the shadows are like expected,
but compiled with the dynamic flagged light the shadow appears to be
almost four times as bright as the levelambient value.
I played around in the shader, but could not figure it out myself. I read in the manual,
that there are parameters, thet can be changed for this shader, but how do I do it with levelgeometry.
What parameter or what part in the shadercode do I have to change?

Re: Mtl_SpecBump: How to make the static shadows darker? [Re: miez] #439149
03/27/14 17:52
03/27/14 17:52
Joined: Nov 2005
Posts: 112
M
miez Offline OP
Member
miez  Offline OP
Member
M

Joined: Nov 2005
Posts: 112
Has nobody even an idea what I can do about it?
Else I compile that thing with static lights and let the
player emit contantly dynamic light.
Not very elegant for me, but this way I can most parts of the level look as dark as I want it to.

Re: Mtl_SpecBump: How to make the static shadows darker? [Re: miez] #439152
03/27/14 18:15
03/27/14 18:15
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
This is simply a result of setting the light to dynamic because dynamic lights shine through all objects (contrary to static lights) and light all objects which are in range.
A fix for this (if I'm not mistaken) will only work when you don't move your dynamic lights because moving the lights somewhere closer to a darker area will have no visible effect then.
I'm not a big friend of changing the predefined shaders, I prefer to write it myself instead and not work with those macros and includes so I cannot really help here but the idea would be to multiply the whole final output (and thus including the dynamic/ specular light in your screenshot) with the TEXCOORD1 static shadow map.


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: Mtl_SpecBump: How to make the static shadows darker? [Re: Superku] #439160
03/27/14 20:33
03/27/14 20:33
Joined: Nov 2005
Posts: 112
M
miez Offline OP
Member
miez  Offline OP
Member
M

Joined: Nov 2005
Posts: 112
Thank you. So it looks like there isnīt any possibility without drawbacks.
I already had the suspicion that the dynamic light in itself could be the problem.
But now with that confirmation I can work around that for the moment.

But isnīt there any possible way with Acknex to have visible bumpmaps with
lightmaps with still useable dynamic lights?...

Would it be possible to use the static lights somehow, perhaps through the lightmaps, and still have it able to react to dynamic lights additionally?
How do other enginss have their levels bumpmapped with lightmaps AND working dynamic lights?

Re: Mtl_SpecBump: How to make the static shadows darker? [Re: miez] #439161
03/27/14 20:48
03/27/14 20:48
Joined: Jul 2008
Posts: 2,107
Germany
rayp Offline

X
rayp  Offline

X

Joined: Jul 2008
Posts: 2,107
Germany
whats about using shade-c ? just wondering ( did not read all )...


Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Re: Mtl_SpecBump: How to make the static shadows darker? [Re: rayp] #439165
03/27/14 21:31
03/27/14 21:31
Joined: Mar 2011
Posts: 3,150
Budapest
sivan Offline
Expert
sivan  Offline
Expert

Joined: Mar 2011
Posts: 3,150
Budapest
it is possible and not too tricky. I will release soon a new MapBuilder editor update, which will contain a normalmapping shader supporting 8 dynamic lights with optional specular mapping. I can do one that supports level lightmap too (just a little bit different skin setting is needed and an additional texture sampling). but first I have to finalize a couple of things, requiring maybe one more week...

to be honest I really don't understand why the included shader package is so limited and unchanged for years... and the shader workshops... some of them are good, but difficult to extend/customize, so normally you have to make your own shaders based on several information sources, due to your actual needs. it is a quite DIY style engine, but forum members are helpful laugh


Free world editor for 3D Gamestudio: MapBuilder Editor
Re: Mtl_SpecBump: How to make the static shadows darker? [Re: rayp] #439166
03/27/14 22:46
03/27/14 22:46
Joined: Nov 2005
Posts: 112
M
miez Offline OP
Member
miez  Offline OP
Member
M

Joined: Nov 2005
Posts: 112
I donīt like shade-c for now. I have enough to do with getting used to A8.
And I want to keep things as simple as possible.
I donīt need shade-cīs fancy effects for my first 3D Game, when I canīt create
the fancy content for it yet.
It is always a rediculous show, to see totally craptastic made beginners-games
that uses and are rendered in state of the art AAA effects and shaders.
Those pop up from Unity and UDK in most cases.


Sivan: Sounds very interesting. How would your approach work
in detail in my case? Would the lightmaps be still reacting to dynamic lights while having correct static shadows AND normalmapping shown without them?

Last edited by miez; 03/27/14 22:56.
Re: Mtl_SpecBump: How to make the static shadows darker? [Re: miez] #439167
03/27/14 23:03
03/27/14 23:03
Joined: Jul 2008
Posts: 2,107
Germany
rayp Offline

X
rayp  Offline

X

Joined: Jul 2008
Posts: 2,107
Germany
Quote:

to be honest I really don't understand why the included shader package is so limited and unchanged for years... and the shader workshops... some of them are good, but difficult to extend/customize, so normally you have to make your own shaders based on several information sources
...and using good looking std. dynamic lights : nearly impossible ( going through walls etc ).

good luck


Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Re: Mtl_SpecBump: How to make the static shadows darker? [Re: rayp] #439172
03/28/14 01:19
03/28/14 01:19
Joined: Apr 2005
Posts: 1,988
Canadian, Eh
DLively Offline
Serious User
DLively  Offline
Serious User

Joined: Apr 2005
Posts: 1,988
Canadian, Eh
Check under Ambient.

Look up how materials work, and its so simple from there

Last edited by DevoN; 03/28/14 01:20.

A8 Pro 8.45.4
YouTube: Create Games For Free
Free Resources: www.CGForFree.com
Re: Mtl_SpecBump: How to make the static shadows darker? [Re: DLively] #439174
03/28/14 07:34
03/28/14 07:34
Joined: Mar 2011
Posts: 3,150
Budapest
sivan Offline
Expert
sivan  Offline
Expert

Joined: Mar 2011
Posts: 3,150
Budapest
@rayp: dynamic lights go through thin walls even in unreal engine 4 (just checked yesterday evening), this is why ue4 utilizes static lights extensively. there are still limitations in computer graphics... sounds like a Jcl answer grin


Free world editor for 3D Gamestudio: MapBuilder Editor
Page 1 of 2 1 2

Moderated by  Blink, Hummel, Superku 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1