Difference between revisions of "Mike notes"

From Bo3b's School for Shaderhackers
Jump to: navigation, search
Line 17: Line 17:
 
I hope this stuff helps, I basically don't realize consciously nowadays what it is that I look for so writing this stuff down is useful for me too :-)
 
I hope this stuff helps, I basically don't realize consciously nowadays what it is that I look for so writing this stuff down is useful for me too :-)
  
 +
Good link from Mike_ar69: [https://forums.geforce.com/default/topic/513190/3d-vision/how-to-fix-disable-shaders-in-games-dll-guide-and-fixes-/post/4069271/#4069271 Shadows.]
  
 
Related awesome post from DarkStarSword regarding fixing shadows:[https://forums.geforce.com/default/topic/766890/3d-vision/bo3bs-school-for-shaderhackers/post/4715553/#4715553 Shadow fixing]
 
Related awesome post from DarkStarSword regarding fixing shadows:[https://forums.geforce.com/default/topic/766890/3d-vision/bo3bs-school-for-shaderhackers/post/4715553/#4715553 Shadow fixing]
 
And [https://forums.geforce.com/default/topic/766890/3d-vision/bo3bs-school-for-shaderhackers/post/4722833/#4722833 The followup.]
 
And [https://forums.geforce.com/default/topic/766890/3d-vision/bo3bs-school-for-shaderhackers/post/4722833/#4722833 The followup.]

Revision as of 02:37, 20 December 2015

Shadows

Hi bo3b - yeah this is not the right shader for shadow rendering ;-) It's not always obvious, but a few clues are:

- There is a ShadowMap sampler in there somewhere

- There is a SomethingXXXToShadow or SomethinXXXToLight matrix in there (or the reverse!)

- A World Coordinate is contructed from EyePos or CamPos, and a 3-comp texcoord

- There is an InvView or InvProjView in there (usually generating something in world coords)

- Recognize that you may not see the word "shadow" in a shader that actually plots shadows. As noted above you often need to look for matrices with "light" in them. This makes more sense because these matrices do a coordinate transformation to the "view" of where the light source is that either casts shadows or enhances the light on a surface, say like a spotlight (very much the same as the View transformation moving to the POV of the camera).

I hope this stuff helps, I basically don't realize consciously nowadays what it is that I look for so writing this stuff down is useful for me too :-)

Good link from Mike_ar69: Shadows.

Related awesome post from DarkStarSword regarding fixing shadows:Shadow fixing And The followup.