From: <mat...@us...> - 2003-12-05 00:19:20
|
Update of /cvsroot/crystal/CS/scripts/python In directory sc8-pr-cvs1:/tmp/cvs-serv22612 Modified Files: testevhdlr.py testpymod.py tutorial2.py tutorial3.py Log Message: blind fix to python examples which didn't use engine.GetBeginDrawFlags which caused headaches for lots of people imitating these examples. If it doesn't work revert it. Index: testevhdlr.py =================================================================== RCS file: /cvsroot/crystal/CS/scripts/python/testevhdlr.py,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- testevhdlr.py 21 Oct 2003 02:54:30 -0000 1.3 +++ testevhdlr.py 5 Dec 2003 00:19:15 -0000 1.4 @@ -47,7 +47,7 @@ if kbd.GetKeyState(CSKEY_DOWN): view.GetCamera().Move(CS_VEC_BACKWARD * 4 * speed) # Tell 3D driver we're going to display 3D things. - if not myG3D.BeginDraw(CSDRAW_3DGRAPHICS): + if not myG3D.BeginDraw(engine.GetBeginDrawFlags() | CSDRAW_3DGRAPHICS): sys.exit(1) if view: view.Draw() Index: testpymod.py =================================================================== RCS file: /cvsroot/crystal/CS/scripts/python/testpymod.py,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- testpymod.py 21 Oct 2003 02:54:30 -0000 1.5 +++ testpymod.py 5 Dec 2003 00:19:15 -0000 1.6 @@ -47,7 +47,7 @@ if kbd.GetKeyState(CSKEY_DOWN): view.GetCamera().Move(CS_VEC_BACKWARD * 4 * speed) # Tell 3D driver we're going to display 3D things. - if not myG3D.BeginDraw(CSDRAW_3DGRAPHICS): + if not myG3D.BeginDraw(engine.GetBeginDrawFlags() | CSDRAW_3DGRAPHICS): sys.exit(1) if view: view.Draw() Index: tutorial2.py =================================================================== RCS file: /cvsroot/crystal/CS/scripts/python/tutorial2.py,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- tutorial2.py 19 Oct 2003 20:37:04 -0000 1.2 +++ tutorial2.py 5 Dec 2003 00:19:15 -0000 1.3 @@ -170,7 +170,7 @@ if self.keybd.GetKeyState(CSKEY_DOWN): self.view.GetCamera().Move(CS_VEC_BACKWARD * 4 * speed) # Tell 3D driver we're going to display 3D things. - if not self.g3d.BeginDraw(CSDRAW_3DGRAPHICS): + if not self.g3d.BeginDraw(self.engine.GetBeginDrawFlags() | CSDRAW_3DGRAPHICS): FatalError() self.view.Draw() #print 'SetupFrame done' Index: tutorial3.py =================================================================== RCS file: /cvsroot/crystal/CS/scripts/python/tutorial3.py,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- tutorial3.py 19 Oct 2003 20:37:04 -0000 1.2 +++ tutorial3.py 5 Dec 2003 00:19:15 -0000 1.3 @@ -126,7 +126,7 @@ if self.keybd.GetKeyState(CSKEY_DOWN): self.view.GetCamera().Move(CS_VEC_BACKWARD * 4 * speed) # Tell 3D driver we're going to display 3D things. - if not self.g3d.BeginDraw(CSDRAW_3DGRAPHICS): + if not self.g3d.BeginDraw(self.engine.GetBeginDrawFlags() | CSDRAW_3DGRAPHICS): FatalError() self.view.Draw() #print 'SetupFrame done' |