/[gzz]/gzz/gfx/librenderables/renderables.py
ViewVC logotype

Diff of /gzz/gfx/librenderables/renderables.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.146 by jvk, Wed Nov 13 20:52:12 2002 UTC revision 1.147 by tjl, Wed Nov 20 19:22:20 2002 UTC
# Line 172  rs = [ Line 172  rs = [
172  },  },
173    
174  {  {
175        "Type": "2",
176        "Name": "CopyPixels",
177        "Data" : "GLenum type; int w,h; ",
178        "Params" : "int w, int h,  GLToken type",
179        "ParamCode" : """
180            this->w = w;
181            this->h = h;
182            this->type = type;
183        """,
184        "RenderCode" : """
185            glPushAttrib(GL_PIXEL_MODE_BIT);
186            glPushClientAttrib(GL_CLIENT_PIXEL_STORE_BIT);
187            glPixelStorei(GL_PACK_ROW_LENGTH, 0);
188            glPixelStorei(GL_PACK_ALIGNMENT, 1);
189    
190            ZPt pfrom = coords1.transform(ZPt(0,0,0));
191            glRasterPos3f(pfrom.x, pfrom.y, pfrom.z);
192            float ras[4];
193            glGetFloatv(GL_CURRENT_RASTER_POSITION, ras);
194    
195            ZPt p = coords2.transform(ZPt(0,0,0));
196            glRasterPos3f(p.x, p.y, p.z);
197    
198            glCopyPixels((int)ras[0], (int)ras[1], w, h, type);
199            GLERR
200            glPopClientAttrib();
201            glPopAttrib();
202        """,
203    },
204    
205    
206    {
207      "Type": "1",      "Type": "1",
208      "Name" : "TextureMatrix",      "Name" : "TextureMatrix",
209      "RenderCode" : """      "RenderCode" : """

Legend:
Removed from v.1.146  
changed lines
  Added in v.1.147

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26