コード例 #1
0
 protected void postsetup(Slot ps, Buffer t) {
   gstates = getgstates();
   Slot pp = curp;
   try {
     curp = ps;
     for (GLState.Global gs : gstates) {
       t.copy(ps.cs);
       gs.postsetup(this);
     }
   } finally {
     curp = pp;
   }
 }
コード例 #2
0
 public void render(GOut g) {
   for (GLState.Global gs : gstates) gs.prerender(this, g);
   drawn = instanced = instancified = 0;
   int i = 0;
   while ((i < cur) && list[i].d) {
     Slot s = list[i];
     if (s.skip) {
       i++;
       continue;
     }
     g.st.set(s.os);
     render(g, s.r);
     if (s.disp != null) s.disp.dispose();
     if (s.instnum > 0) {
       instanced++;
       instancified += s.instnum;
     } else {
       drawn++;
     }
     i++;
   }
   for (GLState.Global gs : gstates) gs.postrender(this, g);
 }