SamplerState g_textureSampler: register(s0,space1); Texture2D g_textures[]: register(t1, space1);