Stock effects HLSL source code

Stock effects HLSL source code

  • Comments 6

Want to see how we implemented the five built-in effects (BasicEffect, SkinnedEffect, EnvironmentMapEffect, DualTextureEffect, and AlphaTestEffect) in Game Studio 4.0?

Curious what the default SpriteBatch shader looks like?

Want to customize these shaders for your needs, without having to recreate them from scratch?

Look no further…

  • So, what are the DX11 shader model 4 macros all about? I thogh xna used DX9 under the hood and you had to use DX10/11 to use SM4. Is it possible to use SM4 in DX9/Xna, or are these there for future use?

    Tim

  • > I thogh xna used DX9 under the hood

    We use different underlying implementation technologies on every target platform (D3D9 on Windows, Xbox D3D on Xbox, and a variant of D3D11 9_1 profile on Windows Phone). Because we compile these same shader sources for all platforms, we need some trickery to make them work with the various different shader compilers.

  • So does this mean that we can write our own shaders for Windows Phone 7?

  • > So does this mean that we can write our own shaders for Windows Phone 7?

    No. Windows Phone only supports these five built-in shaders. Custom shaders are available on Windows and Xbox 360.

  • These links don't seem to work any more, and I can't find an updated link on the xna website. Is there anywhere I can still get them?

  • If anybody else finds this page when looking for the stock effect code, the download from the broken link in the article has been moved to here:

    create.msdn.com/.../stock_effects

Page 1 of 1 (6 items)
Leave a Comment
  • Please add 4 and 4 and type the answer here:
  • Post