Commit 1011fa6c authored by Séverin Lemaignan's avatar Séverin Lemaignan
Browse files

Minor adjustments

parent ca79de55
......@@ -7,10 +7,11 @@ from robopilotsim.builder.robots import Van, Vehicle
# add a new ROBOPILOT van robot in the simulation
# the Van type (and sensors & actuators) is defined in src/builder/robots/van.py
van = Van()
arrival_van = Van()
van.translate(-28.0, -48.0, 0.0)
van.rotate(0.0, 0.0, 3.5)
arrival_van.translate(-28.0, -48.0, 0.0)
arrival_van.rotate(0.0, 0.0, 3.5)
### Add other objects in the simulation
......@@ -25,7 +26,7 @@ car1.translate(-58.85, -48.627, 0.0)
car1.rotate(0, 0, -3.1)
car2=Vehicle(type="car", color=(0.,0.4,0.7))
car2.translate(-54.68, -38.574, 0.0)
car2.translate(-54.68, -38.574, 0.11)
car2.rotate(0, 0, -1.38)
## !! Controllers (ie, 'agents') for these vehicles are found in scripts/
......@@ -34,11 +35,10 @@ car2.rotate(0, 0, -1.38)
### Configure the general simulation environment
env = Environment('data/robopilotsim/env/bristol.blend', fastmode = False)
env.set_camera_location([32.7, -38.4, 27.7])
env.set_camera_rotation([1.24, 0, 1.73])
env.set_ambient_color((0.24, 0.25, 0.26))
env.set_camera_location((24.8654, -57.1503, 55.4403))
env.set_camera_rotation((0.9170, 0.0000, 1.0920))
env.set_camera_clip(0.5,600)
env.set_camera_focal_length(20) #mm
env.set_camera_speed(50)
env.set_material_mode("MULTITEXTURE")
env.set_viewport("SOLID")
env.fullscreen()
......@@ -36,6 +36,7 @@ class Van(GroundRobot):
self.camera.rotate(0,0,0)
self.camera.properties(relative=True) # returns the coordinates of seen objects in the camera's frame
self.camera.properties(cam_far=100) # max visibility distance
self.camera.properties(tag='obstacle') # only 'view' objects of type 'obstacle' (for instance, Vehicle instances)
self.append(self.camera)
self.pose = Pose()
......@@ -45,4 +46,4 @@ class Van(GroundRobot):
## For prototyping purposes, use sockets.
# ros, yarp, text-based logging... are also available
van.add_default_interface('socket')
self.add_default_interface('socket')
......@@ -11,6 +11,7 @@ class Vehicle(GroundRobot):
name=name)
self.properties(classpath = "robopilotsim.robots.vehicle.Vehicle")
self.properties(Object=True) # mark these entities as 'Objects', ie, visible entities for the semantic camera
self.properties(Type='obstacle')
self.motion = Waypoint()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment