Different ways to pass Textures into HLSL shaders

Posted by codymanix on Game Development See other posts from Game Development or by codymanix
Published on 2013-10-24T07:25:57Z Indexed on 2013/10/24 10:15 UTC
Read the original article Hit count: 275

Filed under:
|
|
|
|

The GraphicsDevice class of xna 4 has the properties Textures and VertexTextures.

What is the exact difference? I don't really understand what MSDN tells me about this.

I usually use Effect parameters to pass textures to my HLSL shaders. What are the differences between these methods, which is faster?

My Scenario: I am working on a minecraft like game, which means lots of separate DrawPrimitives calls and change current Texture often since I have lots of different block types. Since I use an Octtree to organize the world, I cannot easily sort by texture.

© Game Development or respective owner

Related posts about XNA

Related posts about xna-4.0