const Tag Renderer::world_obj_normal_matrix_tag("world_obj_normal_matrix");
Renderer::Renderer():
- placeholder_texture(Resources::get_global().get<Texture>("_placeholder.png"))
+ placeholder_texture(Resources::get_global().get<Texture>("_placeholder.png")),
+ default_sampler(Resources::get_global().get<Sampler>("_linear_clamp.samp"))
{
state_stack.reserve(16);
shdata_stack.reserve(32);
res_mgr->resource_used(*tex);
if(!tex->is_loaded())
tex = &placeholder_texture;
+ if(!samp)
+ samp = &default_sampler;
}
+ else
+ samp = 0;
if(texture_stack.size()>state.texture_count)
{
std::vector<BoundProgramData> shdata_stack;
std::vector<BoundTexture> texture_stack;
const Texture &placeholder_texture;
+ const Sampler &default_sampler;
PipelineState *last_pipeline = 0;
Commands commands;