- Program *shprog=&coll.get<Program>(n);
- if(shprog) // Allow for unsupported shaders
- {
- RefPtr<ProgramData> shdata=new ProgramData;
- load_sub(*shdata, *shprog);
-
- obj.normal_pass->shprog=shprog;
- if(obj.normal_pass->shdata)
- delete obj.normal_pass->shdata;
- obj.normal_pass->shdata=shdata.release();
- }
+ obj.technique=coll.get<Technique>(n);
+ obj.textures.resize(obj.technique->get_n_textures());
+ obj.material=obj.technique->get_material();