Difference between revisions of "Game Programming Class14"
esse quam videri
(New page: ==Mixing 2D and 3D== I forgot to show you last week that the spritebatch draw code need to be modified slighty in order top mix 2D and 3D <pre> spriteBatch.Begin(Spri...) |
(→Lighting) |
||
Line 8: | Line 8: | ||
==Lighting== | ==Lighting== | ||
− | The xna basic effect is a simple implementation of a | + | The xna basic effect is a simple implementation of a [http://msdn.microsoft.com/en-us/library/bb509561%28VS.85%29.aspx HLSL] effect. |
− | HLSL is | + | HLSL is Microsoft's High level implementation of FFE Fixed Function Pipeline implemented in video hardware.</p> |
GPU Hardware does two things The vertexr shader runs first and is rasterized to 2D then the pixel shaders run. | GPU Hardware does two things The vertexr shader runs first and is rasterized to 2D then the pixel shaders run. | ||
Line 17: | Line 17: | ||
Lighting Demo with Basic Effect IntroMeshLights.zip | Lighting Demo with Basic Effect IntroMeshLights.zip | ||
− | + | ||
− | |||
=HLSL= | =HLSL= | ||
HLSL Demo | HLSL Demo |
Revision as of 18:41, 3 May 2009
Contents
Mixing 2D and 3D
I forgot to show you last week that the spritebatch draw code need to be modified slighty in order top mix 2D and 3D
spriteBatch.Begin(SpriteBlendMode.AlphaBlend, SpriteSortMode.Deferred, SaveStateMode.SaveState);
Lighting
The xna basic effect is a simple implementation of a HLSL effect.
HLSL is Microsoft's High level implementation of FFE Fixed Function Pipeline implemented in video hardware.</p> GPU Hardware does two things The vertexr shader runs first and is rasterized to 2D then the pixel shaders run.
- Vertex Shader
- Pixel Shader
Lighting Demo with Basic Effect IntroMeshLights.zip
HLSL
HLSL Demo
SkyBox
<a href="http://www.ziggyware.com/readarticle.php?article_id=71">http://www.ziggyware.com/readarticle.php?article_id=71</a>
<a href="ClassSource/Projects/IntroMeshLightsSkyBox.zip">IntroMeshLightsSkyBox.zip</a>
?? http://www.planetside.co.uk/terragen/
</div>