16Mar/100
If you break it, break it good. XNA 4 Breaking changes.
Shawn has written about the breaking changes in XNA 4.0. He brushes over a brief history lesson of XNA which sets up the scene to talk about the breaking changes that XNA 4.0 brings to developers.
Read the full post here
"I’ll be writing more about these changes and the reasons behind them over the coming weeks, but here is a quick summary of the more significant breaking changes:
- Replaced StorageContainer.TitleLocation with a new OpenStream API
- Replaced individual graphics renderstates with a new state objects API
- Premultiplied alpha is now enabled by default
- Made it easier to use SpriteBatch with custom renderstates and custom shaders
- No more SpriteBatch vertex shader magic, so you can easily position SpriteBatch text in a 3D world using BasicEffect
- Vertex buffers are now strongly typed, each one having an associated VertexDeclaration
- You no longer need to specify a VertexDeclaration before drawing, because this is implicit in your choice of vertex buffer
- Vertex buffer sizes are now specified as number of vertices rather than bytes
- Replaced GraphicsDevice.Vertices with a new SetVertexBuffer API
- Each rendertarget now has an associated depth buffer: no more DepthStencilBuffer type
- RenderTarget2D now inherits Texture2D: no more GetTexture method
- SetRenderTarget atomically sets all rendertargets, rather than changing just one layer
- Replaced Effect.Begin and End with a new EffectPass.Apply method
- Removed the low level shader APIs (VertexShader, PixelShader, Set*ShaderConstant)
- Removed EffectPool, StateBlock, GammaRamp, ClipPlane
- Removed triangle fans
- Removed point sprites
- Changed the Color type from BGRA to RGBA byte ordering"