DX11 and multiple shader Textures

Started by
1 comment, last by cr88192 11 years, 1 month ago

So I have been going through other games recently to see how they allow people to modify their elements and one that struck me as odd was Dota2. In their "mod" tools documentation they have setup a process for two mask textures to be applied, each of those textures have an RGBA setup and each channel is used for a different shader reference. This seems interesting as I thought that this type of process would bog down the draw calls and make the system more memory intensive.

What are your thoughts on this, and is there a better method to implementing more than 3 shaders? Currently we use a diffuse texture and the rest of the shaders are associated with the specular texture. Thanks for any advice you can provide in advance.

Reference Link:

http://media.steampowered.com/apps/dota2/workshop/Dota2ShaderMaskGuide.pdf

Advertisement

ah that's cool it looks like they have a lot of flexibility with all those masks. i think you may misunderstand though. each of those channels doesn't mean they are using different shaders for different parts of the character. the character could be rendered with one draw call and a shader which computes all 8 material properties and uses the 8 masks to control those properties. so using the same shader and different weights in those mask channels you can achieve very different looking materials on the different parts of the character. hope this helps

ah that's cool it looks like they have a lot of flexibility with all those masks. i think you may misunderstand though. each of those channels doesn't mean they are using different shaders for different parts of the character. the character could be rendered with one draw call and a shader which computes all 8 material properties and uses the 8 masks to control those properties. so using the same shader and different weights in those mask channels you can achieve very different looking materials on the different parts of the character. hope this helps

pretty much.

depending on how they do the shader, it may be possible to feed in a bunch of various maps as textures, and then enable/disable features or use defaults for maps which aren't present.

something like a "generic material lighting shader" may still end up with a lot of inputs, while still being a single shader.

This topic is closed to new replies.

Advertisement