Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
3 registered members (Grant, TipmyPip, AndrewAMD), 12,724 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: The ultimate tree shader? [Re: Kartoffel] #426181
07/17/13 15:07
07/17/13 15:07
Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
txesmi Offline
Serious User
txesmi  Offline
Serious User

Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
thanks too! Definitively those functions go to my shader function library grin

The blue channel of a normalmap can be easily computed based in the relation between sine and cosine or Pythagorean trigonometric identity:

Originally Posted By: Pythagoras

pow ( sin A, 2 ) + pow ( cos A, 2 ) == 1
sin A == sqrt ( 1 - pow ( cos A, 2 ) )
cos A == sqrt ( 1 - pow ( sin A, 2 ) )

Code:
normal.b = sqrt ( 1 - ( normal.r * normal.r ) - ( normal.g * normal.g ) );



Of course, it will be always positive.

Re: The ultimate tree shader? [Re: ] #426196
07/17/13 17:59
07/17/13 17:59
Joined: Jul 2013
Posts: 22
S
Stratego Offline OP
Newbie
Stratego  Offline OP
Newbie
S

Joined: Jul 2013
Posts: 22
@Malice

I didn't actually do too much in that thread, just took advice from others and tested stuff out. From now on I will post about my tree work here exclusively, and if I do come up with some good stuff, I'll share it with the community. But understand, it may take me a while because I'm just doing it for fun.

Re: The ultimate tree shader? [Re: Stratego] #426207
07/17/13 22:22
07/17/13 22:22
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
I like the tree, looks nice. I doubt it will look better with normal mapping.


"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: The ultimate tree shader? [Re: Superku] #426209
07/17/13 23:40
07/17/13 23:40
Joined: Jul 2013
Posts: 22
S
Stratego Offline OP
Newbie
Stratego  Offline OP
Newbie
S

Joined: Jul 2013
Posts: 22
Thanks!

We'll see. I'm going to finish up the tree. I still am not happy with it, and then start applying shaders. (The tree already is looking quite a bit better)

What I'd like to get out of normal bump with specular:

1. Bark always looks good with normal mapping.
2. I'd like to get a "wet look" with the specular applied to the leaves.

First I'm going to finish the tree and all the maps, so I can test the finished product.

Last edited by Stratego; 07/17/13 23:44.
Page 2 of 2 1 2

Moderated by  Blink, Hummel, Superku 

Gamestudio download | 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