Revision: 767
http://python-ogre.svn.sourceforge.net/python-ogre/?rev=767&view=rev
Author: andy_miller
Date: 2008-10-20 15:13:26 +0000 (Mon, 20 Oct 2008)
Log Message:
-----------
Couple more tweaks to the demos
Modified Paths:
--------------
trunk/python-ogre/demos/ogrebullet/Demo_OgreCollision01.py
trunk/python-ogre/demos/ogrepcz/Demo_PCZ01.py
Modified: trunk/python-ogre/demos/ogrebullet/Demo_OgreCollision01.py
===================================================================
--- trunk/python-ogre/demos/ogrebullet/Demo_OgreCollision01.py 2008-10-20 15:08:45 UTC (rev 766)
+++ trunk/python-ogre/demos/ogrebullet/Demo_OgreCollision01.py 2008-10-20 15:13:26 UTC (rev 767)
@@ -44,11 +44,11 @@
# create the floor
plane = ogre.Plane()
- plane.normal = ogre.Vector3.UNIT_Y
+ plane.normal = ogre.Vector3().UNIT_Y
plane.d = 200
mm = ogre.MeshManager.getSingleton()
mm.createPlane('FloorPlane', 'General', plane, 200000.0, 200000.0,
- 20, 20, True, 1, 50, 50, ogre.Vector3.UNIT_Z)
+ 20, 20, True, 1, 50, 50, ogre.Vector3().UNIT_Z)
entity = sceneManager.createEntity('floor', 'FloorPlane')
entity.setMaterialName('Examples/RustySteel')
sceneManager.getRootSceneNode().createChildSceneNode().attachObject(entity)
Modified: trunk/python-ogre/demos/ogrepcz/Demo_PCZ01.py
===================================================================
--- trunk/python-ogre/demos/ogrepcz/Demo_PCZ01.py 2008-10-20 15:08:45 UTC (rev 766)
+++ trunk/python-ogre/demos/ogrepcz/Demo_PCZ01.py 2008-10-20 15:13:26 UTC (rev 767)
@@ -73,7 +73,7 @@
# (takes furthest hit)
updateRay = ogre.Ray()
updateRay.setOrigin(self.camera.getParentSceneNode().getPosition())
- updateRay.setDirection(self.camera.getParentSceneNode().getOrientation()*ogre.Vector3.NEGATIVE_UNIT_Z)
+ updateRay.setDirection(self.camera.getParentSceneNode().getOrientation()*ogre.Vector3().NEGATIVE_UNIT_Z)
self.raySceneQuery.setRay(updateRay)
zone = self.camera.getParentNode().getHomeZone()
self.raySceneQuery.setStartZone(zone)
@@ -143,7 +143,7 @@
corners[1] = aabb.getMaximum()
p.setCorner(0, corners[0])
p.setCorner(1, corners[1])
- p.setDirection(ogre.Vector3.NEGATIVE_UNIT_Z) # this indicates an "inward" pointing normal
+ p.setDirection(ogre.Vector3().NEGATIVE_UNIT_Z) # this indicates an "inward" pointing normal
# associate the portal with the terrain's main node
p.setNode(terrainZone.getEnclosureNode())
# IMPORTANT: Update the derived values of the portal
@@ -158,7 +158,7 @@
corners[1] = aabb.getMaximum()
p2.setCorner(0, corners[0])
p2.setCorner(1, corners[1])
- p2.setDirection(ogre.Vector3.UNIT_Z) # this indicates an "outward" pointing normal
+ p2.setDirection(ogre.Vector3().UNIT_Z) # this indicates an "outward" pointing normal
# associate the portal with the terrain's main node
p2.setNode(terrainZone.getEnclosureNode())
# IMPORTANT: Update the derived values of the portal
@@ -272,14 +272,14 @@
self.buildingNode = roomObj.createTestBuilding(self.sceneManager, "1")
self.buildingNode.setPosition(500, 165, 570)
#ogre.Radian r = Radian(3.1416/7.0)
- #self.buildingNode.rotate(ogre.Vector3.UNIT_Y, r)
+ #self.buildingNode.rotate(ogre.Vector3().UNIT_Y, r)
#
# # create another test buildinig
# roomObj2 = RoomObject.RoomObject()
# self.buildingNode = roomObj2.createTestBuilding(self.sceneManager, "2")
# self.buildingNode.setPosition(400, 165, 570)
# #ogre.Radian r = Radian(3.1416/7.0)
-# #self.buildingNode.rotate(ogre.Vector3.UNIT_Y, r)
+# #self.buildingNode.rotate(ogre.Vector3().UNIT_Y, r)
#
# Position camera in the center of the building
self.cameraNode.setPosition(self.buildingNode.getPosition())
@@ -290,7 +290,7 @@
# create the ray scene query
self.raySceneQuery = self.sceneManager.createRayQuery(
- ogre.Ray(self.camera.getParentNode().getPosition(), ogre.Vector3.NEGATIVE_UNIT_Z))
+ ogre.Ray(self.camera.getParentNode().getPosition(), ogre.Vector3().NEGATIVE_UNIT_Z))
self.raySceneQuery.setSortByDistance(True, 5)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|