Normal maps?
Moderator: InsideQC Admins
3 posts
• Page 1 of 1
Normal maps?
Not really programming it, but how's it programmed to DarkPlaces? Which colour is top, which left? Or does it matter?
zbang!
-

jim - Posts: 599
- Joined: Fri Aug 05, 2005 2:35 pm
- Location: In The Sun
It's standard. RGB=XYZ.
R=0 -> X=-1
R=0.5 (128) -> X = 0
R = 1 (255) ->X = 1
And they're tangent space.
+X=right, +Y=down, +Z=away from the surface. (note that it's also common to have +Y=up, but DarkPlaces has +Y=down).
To get plain Phong shading (as if you had no normal mapping), all the normals should point 'out', which is positive Z. The normal should be 0,0,1, therefore the colour should be 0.5,0.5,1 (aka 128,128,255). It's a light bluish-purple that you commonly see on normal maps.
R=0 -> X=-1
R=0.5 (128) -> X = 0
R = 1 (255) ->X = 1
And they're tangent space.
+X=right, +Y=down, +Z=away from the surface. (note that it's also common to have +Y=up, but DarkPlaces has +Y=down).
To get plain Phong shading (as if you had no normal mapping), all the normals should point 'out', which is positive Z. The normal should be 0,0,1, therefore the colour should be 0.5,0.5,1 (aka 128,128,255). It's a light bluish-purple that you commonly see on normal maps.
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
- Sajt
- Posts: 1215
- Joined: Sat Oct 16, 2004 3:39 am
3 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 1 guest