Actually only 8 textures will be bound but Blender support up 18 texture slots.
The patch change the texture limit to 18 to allow to use more textures if supported.
Actually I am unsure about this patch because there is a comment that increasing will slow don the rendering.
I have done this patch because I had some user requests about increasing the texture amount,
What should I write to your comment? Actually I also don't know if it is useful or not. But sometimes you are need more then 8 textures. when you use GLSL shader (Cubemap 6, normal map (actually video texture can't render a cube map), light map, texture map, cone step map or relief map, specular map, roughness map, ID map, shadow map, noise texture, ........) or stencil maps.
If you and the other think is not useful, we don't need to apply it.
Also you requested changes, what I should change here?
This makes our verts a lot larger and is wasted space if we're not using the extra textures, which is common. This patch increases our vertex size by 75%, which is 75% more bandwidth needed to upload vertex data, and 75% more VRAM when using VBOs. It's also not 32-byte aligned, which AMD cards aren't too fond of (or at least they used to be, I don't know about GCN).
I have a question regarding the limitation of texture slots.
My company is using blender to render fabric and we are currently using the texture slots to add images (logos) to the garments. These logos need to be independent (not a combined texture map) so that they can be individually modified by the user (position, scale, and rotation). Because of this need to be able to modify them individually, each one currently uses one texture slot. This limits us to a small number of logos that can be applied to garments. We would like to be able to add a great deal more logos to our garments as some contain several sequins or buttons etc...
Does anyone have any thoughts about the best approach for this? After reading the above comments and concerns about memory usage, I'm hesitant to update the Blender Source code to add more texture slots.
I appreciate any input that you all may have.