Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 1,403 guests, and 6 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19055 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: Where's my error here? [Re: Rhuarc] #53944
09/02/05 17:38
09/02/05 17:38
Joined: Oct 2002
Posts: 8,939
planet.earth
ello Offline
Senior Expert
ello  Offline
Senior Expert

Joined: Oct 2002
Posts: 8,939
planet.earth
Quote:

Actually... it's -vecSunDir.zyx if I remember right- for some reason the light vector is flipped funny in A6....
-Rhuarc




omg (ZYX)! thats why i always get so strange results and dont had any idea about Why!! man, how did you find that out??


www.earthcontrol.de
quoted: We want to maintain a clean, decent, American family suited forum look... which means you may post zombies or chainsaw massacres, but no erotic.
Re: Where's my error here? [Re: Rhuarc] #53945
09/02/05 19:28
09/02/05 19:28
Joined: Aug 2005
Posts: 107
NMS Offline OP
Member
NMS  Offline OP
Member

Joined: Aug 2005
Posts: 107
Quote:

Actually... it's -vecSunDir.zyx if I remember right- for some reason the light vector is flipped funny in A6....
-Rhuarc




its a float4
it has to have more than xyz...


so i putt like this? vecSunDir = (x,y,z) or external float4 vecsundir.xyz???


http://www.coniserver.net/ubbthreads/showflat.php?Cat=0&Number=560847&an=0&page=0#560847 Cmon every one! Help me building this camera script! The first of its kind in 3dgs! Thnkx to everyone who helped me in my questions
Re: Where's my error here? [Re: ello] #53946
09/02/05 23:25
09/02/05 23:25
Joined: Mar 2001
Posts: 3,298
Beverly, Massachusetts
Rhuarc Offline
Expert
Rhuarc  Offline
Expert

Joined: Mar 2001
Posts: 3,298
Beverly, Massachusetts
Quote:

Quote:

Actually... it's -vecSunDir.zyx if I remember right- for some reason the light vector is flipped funny in A6....
-Rhuarc




omg (ZYX)! thats why i always get so strange results and dont had any idea about Why!! man, how did you find that out??




I was being driven INSANE by it, and I just knew it was A6 being idiotic. So I figured it was an axis conversion and swapped Y and Z (A6 flips these axis from dX9). No luck, reversed the whole thing.. and BINGO! ^_^.

Quote:


its a float4
it has to have more than xyz...
so i putt like this? vecSunDir = (x,y,z) or external float4 vecsundir.xyz???



That doesn't matter. You could change float4 to float3 and it would be just fine. When you use vecSunDir.zyx, it automatically converts it to float3.

vecSunDir.zyx
is exactly the same as
float3(vecSunDir.z,vecSunDir.y,vecSunDir.x)

It's called swizzling- look it up on MSDN.

-Rhuarc


I no longer post on these forums, keep in touch with me via:
Linkedin.com
My MSDN blog
Page 2 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