- obj.meshes[0]=coll.get<Mesh>(n);
-}
-
-void Object::Loader::pass(const string &n)
-{
- unsigned id=Tag(n).id;
- if(obj.passes.count(id))
- throw KeyError("Duplicate pass name");
- ObjectPass p;
- load_sub(p, coll);
- obj.passes[id]=p;
-}
-
-void Object::Loader::shader(const string &n)
-{
- 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();
- }