Commits

German Larrain committed 0d53fb2

demos and tests: updated according to changes in collision.base (7e82277e4821).

Comments (0)

Files changed (2)

demos/IROS/example4_sinusoidal_terrain.py

 from random import random
 
 from ars.lib.pydispatch import dispatcher
-from ars.model.collision.base import Trimesh
+from ars.model.collision.base import HeightfieldTrimesh
 from ars.model.simulator import Simulation, signals
 import ars.utils.mathematical as mut
 
 		tm_x, tm_z = self.TM_X, self.TM_Z
 		vertices = sinusoidal_heightfield(
 			tm_x, tm_z, height_scale=0.7, frequency_x=0.5)
-		faces = Trimesh.get_heightfield_faces(tm_x, tm_z)
+		faces = HeightfieldTrimesh.calc_faces(tm_x, tm_z)
 		#vertices = constant_heightfield(tm_x, tm_z, height=0.0)
 		#vertices = random_heightfield(tm_x, tm_z, 0.5)
 		#shrink_factor = (1.0,1.0)

tests/collision.py

 
 
 def test_get_heightfield_faces():
-	print(sh.Trimesh.get_heightfield_faces(5, 5))
+	print(sh.HeightfieldTrimesh.calc_faces(5, 5))
 
 if __name__ == '__main__':
 	test_get_heightfield_faces()